Results 1 to 2 of 2

Thread: [Answers] NetworkRequest

  1. #1
    Lianja MVP
    Join Date
    Dec 2012
    Location
    Croatia, Zagreb
    Posts
    1,135

    [Answers] NetworkRequest

    Q:
    Code:
    oRequest.putFile("ftp://www.timelinecontinuum.com/9-11.xml?username='myUserName'&password='myPassword' ",xmlName)
    A:
    You can however only use http:// or https:// not ftp:// with "NetworkRequest"
    If you want to upload using sftp i would recommend that you look at using the chilkat components for Lianja from http://www.chilkatsoft.com/lianja.asp



    Q:
    I would like to have the targetFile and source file both coming from variables.
    It works Ok with source file as xmlName where xmlName contains something like "C:\Lianja\Data\timeline\9-11.XML".
    But targetFile resists my attempts to use a variable. I would like to pass through a file name and a subdirectory on my Host.
    So TargetFile would be something like "/DataXML/filename.xml".
    A:
    You can substitute variables into strings using &varname. which would let you use variables. Otherwise you can just create the character variable and use that as an argument to the method call.
    Try omitting the / from the start of the target file. Does that directory already exist and if so does it have the correct permissions.
    it may be that the target can only be a filename.
    One solution would be to have a username that when logged in uses a different directory on the ftp server but that would require some configuration and is Server dependent.



    ​All topics in [Answers] alphabetically:http://www.lianja.com/community/show...ll=1#post12352

  2. #2
    Lianja MVP
    Join Date
    Dec 2012
    Location
    Croatia, Zagreb
    Posts
    1,135
    Q:
    what's the best way to send a file with FTP?

    A:
    If you are in production you should be using ftps or sftp, in which case the Chilkat Extensions (FTP, which includes FTPS, and SFTP) are what we use.
    Unprotected FTP servers will be probed within 30 seconds of being put up, from what I've seen on our servers.
    If you need a protected FTP Server, you can monkey around with IIS and waste many hours, or you can get Cerberus, which is easy to use and just keeps working.
    the Chilkat Extensions are from chilkatsoft.com, by subscription. They are available (for one price) for just about every platform. In addition to the FTP/S and SFTP controls, we use their email, zip, and http and Crypt controls. The http control is used from our VFP-based app to hit a Lianja web service, for example.
    You can find "free" versions of controls that do most of the same stuff. The difference is in having control of all the features you need to match what your customers are using, and in the fantastic support (as good as Barry's, almost as fast <s>). Also, many of the common usages have been "conceptualized" into an easy-to-use command that makes complex tasks easy. I've saved a couple of projects and hundreds of hours since I started using them for, I think, the past 10 years or so.
    In one case we needed FTPS before it was common (we were working with a casino, with enhanced security needs). I wrote Matt at Chlkat explaining our need. He said if I'd set up a server he'd write it. We did, and he did, just like that.




    All topics in [Answers] alphabetically: http://www.lianja.com/community/show...ll=1#post12352

    These answers are also systematized on the site "Lianja developer": https://lianjadeveloper.wordpress.com/category/networkrequest/
    Last edited by josipradnik; 2017-12-19 at 03:26.

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Journey into the Cloud
Join us