Jump to content

[SOLVED] advanced $_GET[] question


Derleek

Recommended Posts

hello php freaks!

 

Not sure what else to title this topic so... that one will do

 

I am creating an ajax application and i'm wondering the best way to loop through every variable passed via the $_GET[] method.

 

Lets say I have 4 var's that I'm passing in the URL www.example.com/index.php?var1=blah&var2=asdfasdf&pumpkin=true.

 

Is there a built in function to loop through every var passed this way?

 

The only solution I have thought of off the top of my head is to have a variable that contains each of the names that also has a parsing character

 

EX: www.example.com/index.php?varsPassed=var1/var2/pumpkin&var1=blah...etc

 

I haven't tested this method so I am not sure even if the '/' character can be passed as a parsing character.

 

This is my first in-depth ajax application so I'm kinda experimenting with it.  Not too sure if even using the 'GET' method is the best option (or even if there are other viable options... haha).

 

I'll be tooling around with this for the next hour or so and i'll post any new angles I dig up on the net.

 

Any and all help is welcome and greatly appreciated.

 

-thanks

Link to comment
https://forums.phpfreaks.com/topic/165377-solved-advanced-_get-question/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.