Jump to content

Query Strings


JrMasterModelBuilder
 Share

Recommended Posts

JrMasterModelBuilder

I know query strings are usually used to convey data between dynamic webpages, but are there any other files besides dynamic webpages that can use them? I am particularly interested to hear if .BAT, .EXE, or any other Windows executable files are able to read them.

Link to comment
Share on other sites

Query strings? At first "hearing" it sounds to me like a database query.

Please to open in notepad and paste contents :P

Link to comment
Share on other sites

JrMasterModelBuilder

Query strings? At first "hearing" it sounds to me like a database query.

Please to open in notepad and paste contents :P

I didn't really underatand what you said, but a query string is the "?/topic/1112-query-strings/" in the following URL:

http://www.rockraidersunited.org/index.php?/topic/1112-query-strings/

Link to comment
Share on other sites

OH, xD. Thats just how the website is built to organize its contents. /topic/ means its a forum topic, 1112 is probably the number of that topic, and query-strings/ in the name of the topic. The question mark is a php thing i'm guessing.

Wait... I kinda see what you're saying, but you're not wording it clearly. You want to know if executable files are able to read urls?

Link to comment
Share on other sites

JrMasterModelBuilder

OH, xD. Thats just how the website is built to organize its contents. /topic/ means its a forum topic, 1112 is probably the number of that topic, and query-strings/ in the name of the topic. The question mark is a php thing i'm guessing.

Wait... I kinda see what you're saying, but you're not wording it clearly. You want to know if executable files are able to read urls?

I was wondering if there are any Windows executable files (.exe, .bat, etc.) that could read variables from a query string (example: ?health=98&money=50) into itself (like PHP does so well) so that they could be written to a file.

Link to comment
Share on other sites

OOOOHH. They can have arguments, such as for LRR "-debug". These arguments can take any for really, not just -xyz.

Most programs that are run from the command line (on linux at least) have options like this:

cat file.txt # writes contents of file.txt to standard output

g++ program.cpp # uses GCC's C++ compiler to compile program.cpp with the default name (a.out for me)

g++ program.cpp -o program # uses GCC's C++ compiler to compile program.cpp to the executable "program"

If your question was how to implement this, post again specifying which language :P

Link to comment
Share on other sites

JrMasterModelBuilder

OOOOHH. They can have arguments, such as for LRR "-debug". These arguments can take any for really, not just -xyz.

Most programs that are run from the command line (on linux at least) have options like this:

cat file.txt # writes contents of file.txt to standard output

g++ program.cpp # uses GCC's C++ compiler to compile program.cpp with the default name (a.out for me)

g++ program.cpp -o program # uses GCC's C++ compiler to compile program.cpp to the executable "program"

If your question was how to implement this, post again specifying which language :P

It was more of a theoretical question, but if it's possible with .bat I would like to hear that. If not, I would like to hear how to put it in Java.

Link to comment
Share on other sites

 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.