Get the raw post on server

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
hrcap
Posts: 131
Joined: Mon Jan 14, 2019 5:20 pm

Get the raw post on server

Post by hrcap » Thu Mar 23, 2023 4:09 pm

Hi All

I hope that everyone is well.

When using the post command to post data to a server you would post something like:

Code: Select all


libURLFormData("code", "test", "state", "123")

post it to url https://www.testserver.com/script


the server would then receive the script and pick out the parameters like:

Code: Select all

put $_POST["code"] into t_code
put $_POST["STATE"] into t_state



My question is how do I return all of the raw raw data that was sent to the server rather than picking on individual parameters... for my example above my desired return would be something like:

https://www.testserver.com/script/?code=test&state=123

or

?code=test&state=123


(basically the whole of the posted data in its raw format)


I hope I am making sense



Basically I am trying to receive data from a third party server and I can't at the moment isolate the individual parameters so I want to check what exactly is being received from the third party server.



Many Thanks

Klaus
Posts: 13824
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: Get the raw post on server

Post by Klaus » Thu Mar 23, 2023 4:30 pm

Does -> $_GET_RAW do what you need?

hrcap
Posts: 131
Joined: Mon Jan 14, 2019 5:20 pm

Re: Get the raw post on server

Post by hrcap » Thu Mar 23, 2023 4:37 pm

Thank you very much Klaus

That is exactly what I was after, problem solved.

Many Thanks

Klaus
Posts: 13824
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: Get the raw post on server

Post by Klaus » Thu Mar 23, 2023 4:42 pm

Hint:
The dictionary is way better than its reputation. 8)

Post Reply

Return to “Getting Started with LiveCode - Experienced Developers”