CURL Xbasic Overview
CURL is a popular utility that can be used for many tasks, such as making REST API calls.
CURL is now exposed as a top level Xbasic object, allowing you to execute CURL commands from your Xbasic code. Many APIs are documented using CURL examples. You can use a built-in genie to convert a CURL command into an Xbasic script. To get to the CURL genie, right click on white space in the Xbasic code editor and select the 'Genies...' command. The select the 'CURL command to Xbasic....' command.
This opens the CURL to Xbasic Genie where you can type in a CURL command then then click the 'Generate Xbasic' button to generate the Xbasic code to execute the specified CURL command.
For more information on the Xbasic CURL object, click here.
When you publish your web application to an ISP, your publishing profile will typically specify that the method for publishing the files is FTP. You then have the option of using either the built-in FTP features in Alpha Anywhere, or using an external FTP client. If you choose to use the built-in FTP features in Alpha Anywhere, you now have a new option of using CURL FTP. Unlike the standard FTP feature in Alpha Anywhere (which uses Active mode), the CURL FTP option supports passive mode. Passive move is more reliable as is has enhanced error checking and error messages.
To select the CURL option, check the 'FTP Publish with CURL' property in the Profile Editor dialog.
Passive mode FTP is slower than active mode FTP, especially when uploading a lot of files, rather than one large zipped file. Therefore it is recommended that you only use the CURL FTP option when using the 'InternalOptimized' option (which zips all of the files to be published into a single zip file).