php - special characters send with url -


how special characters form submit. example: form got name="customer[firstname]".

the url customer%5bfirstname%5d=test.

i've tried:

$firstname = $_get['customer[firstname]']; 

also same urldecode, rawurldecode.

using [...] in name attributes creating array can access on server as:

$firstname = $_get['customer']['firstname']; 

and if omit value in brackets, numerical array:

name="customer[]" 

would become on server:

// example, should loop on `$_get['customer']` instead... $firstname = $_get['customer'][0];  

Comments

Popular posts from this blog

angularjs - ADAL JS Angular- WebAPI add a new role claim to the token -

php - CakePHP HttpSockets send array of paramms -

node.js - Using Node without global install -