When you are passing parameters in the url, remember to pass the parameters by their id, not value. It would be better.
For ex, if you have to pass the "city" parameter to a file called index.php, do pass it as: index.php?city=2, not like index.php?city=bangalore
It would be readable and also easy to use the values in our queries, with out much validations. (probably only integer validation is needed!)
Especially when we are using ajax calls, this is useful.
For ex, if you have to pass the "city" parameter to a file called index.php, do pass it as: index.php?city=2, not like index.php?city=bangalore
It would be readable and also easy to use the values in our queries, with out much validations. (probably only integer validation is needed!)
Especially when we are using ajax calls, this is useful.
Comments
Post a Comment