Tue Aug 27 04:49:46 EDT 2019
The altURL command posts form data and gets query data to / from a web
server using the POST and GET action of HTTP. It sends the completedMessage
when finished. The HTTP response can be accessed from the custom property
altURLResponse which can be checked in the completedMessage handler. This is
valuable in processing redirects as well as callbacks. There are two ways to
call this command. One is by passing separate values for all parameters, the
other is by merging all parameters into one URL?QueryString.
altURL ReqType, Host, Page, formList [,completedMessage]
altURLget URL?QueryString [,completedMessage]
altURLpost URL?QueryString [,completedMessage]
The Host is a valid URL to a web server.
The Page is an valid Page request (typically an .asp,.jsp or cgi page).
The formList is a list of Form or QueryString Variables and their respective
contents. Each line of the list will have a name value pair. If you wish to
use spaces or special characters, be sure to URLencode them first.
ex. This list variable sends two name value pairs:
The completedMessage is an optional message sent to the stack upon
completion of the command.
The URL?Querystring is a valid URL with appended QueryString. Even though
this is typical in 'get' and not 'post' commands, here it generates both.
Note the http:// is required.
customProperties of altURL Lib:
altURLHeader - the header text being sent minus the Host and Page and
altURLTimeOutSecs - the time in seconds for altPostSAFileUp to quit.
altURLresponse - the HTTP response sent from the server or empty if no
response. Use with the completedmessage parameter to get the HTTP response.
Copy the button altURL Lib into your stack. Then insert into the open stack
or startup handler of your stack:
insert the script of btn altURL Lib into back
Then you can call the altURL command from anywhere in your stack.
For more info contact Chipp Walters
Portions of this script used with permission of Jerry Daniels. Muchos
More information about the use-livecode