MeTitus Posted January 3, 2008 Share Posted January 3, 2008 Hi guys, How can I get th number of arguments in the querystring? eg: localhost?a=1&b=2 --> arguments count = 2; Also if the argument a didn't exist I would get "" with $_GET["a"], how do I actually find whether it exists? Many thanks, MeTitus Quote Link to comment https://forums.phpfreaks.com/topic/84287-solved-querystring-args-count/ Share on other sites More sharing options...
rajivgonsalves Posted January 3, 2008 Share Posted January 3, 2008 you can get the count with $count = count($_GET); you check for array_key_exists("a",$_GET); hope its helpful Quote Link to comment https://forums.phpfreaks.com/topic/84287-solved-querystring-args-count/#findComment-429242 Share on other sites More sharing options...
MeTitus Posted January 3, 2008 Author Share Posted January 3, 2008 Thank you very much my friend Quote Link to comment https://forums.phpfreaks.com/topic/84287-solved-querystring-args-count/#findComment-429244 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.