Passing Variables in a non-CGI LC Server?

Matthias Rebbe matthias_livecode_150811 at m-r-d.de
Fri Apr 7 12:58:56 EDT 2017



> Am 07.04.2017 um 18:21 schrieb Rick Harrison via use-livecode <use-livecode at lists.runrev.com <mailto:use-livecode at lists.runrev.com>>:
> 
> Hi Matthias,
> 
> Yes, I want to output some information to the user, and other
> information remains hidden - where some data is adjusted,
> modified, on the third webpage.
> 
> No, I’m not looking to redirect to another webpage, although
> I have used that technique in the past on other types of
> webservers.
> 

So then you could post the parameters from 2nd script/webpage  to the 3rd webpage/script (post myData to URL destinationURL) and  then output the result or what ever the 3rd script/webpage returns.

This way you do not need to pass the parameters to the url.

> I’d rather not have the parameters put into the URL where
> the user can see it if possible for security reasons, but
> if that’s the only way I suppose I could encrypt it before
> passing it through that way.

> 
> Thank you for your input!
> 
> Rick
> 
> 
>> On Apr 7, 2017, at 2:03 AM, Matthias Rebbe via use-livecode <use-livecode at lists.runrev.com <mailto:use-livecode at lists.runrev.com>> wrote:
>> 
>> is the third website just for further processing w/o an output to the user or do you also want to output some information to the user?
>> 
>> case 1
>> You could use the http post or get method to pass the parametesr to the 3rd script/website from the 2nd script and return the result then to  the 2nd script.
>> Be aware that your 2nd scrip or better said every lc script, needs to do an output, even if it´s just a blank. Otherwise the server returns an error 500
>> 
>> case 2
>> If i remember right, put header allows you to redirect. So in your 2nd script/website after you´ve done whatever you could use put header to redirect using put header:
>> 
>> something like this
>> put "http://yoursite.com?param1&param2&parame <http://yoursite.com/?param1&param2&parame> <http://yoursite.com/?param1&param2&parame <http://yoursite.com/?param1&param2&parame>>" into tURL
>> put  header "Status: 301”
>> put header "Location:" && tURL
>> put “redirecting…”   — i am not sure if this last line is still needed, but in older versions of lcServer it was.
>> 
>> 
>> Matthias
>> 
> 
> 
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com <mailto:use-livecode at lists.runrev.com>
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode




More information about the use-livecode mailing list