Phaelon Posted May 11, 2014 Share Posted May 11, 2014 Does anyone know how I can escape a decimal in a URL variable? I.E: example.com/?value=100.00 echo $_GET['value']; returns '', when I am wanting it to return '100.00'. I tried using quotes around 100.00 in the URL, but it didn't work. Link to comment https://forums.phpfreaks.com/topic/288406-escaping-decimals-in-a-url-variable/ Share on other sites More sharing options...
Ch0cu3r Posted May 11, 2014 Share Posted May 11, 2014 You dont need to escape it. $_GET['value'] should be returning 100.00 You may need to post your code. Link to comment https://forums.phpfreaks.com/topic/288406-escaping-decimals-in-a-url-variable/#findComment-1479067 Share on other sites More sharing options...
Cornelius Posted May 11, 2014 Share Posted May 11, 2014 Does it work correctly when program it to send letters instead of number? I.E: example.com/?value=hundred Link to comment https://forums.phpfreaks.com/topic/288406-escaping-decimals-in-a-url-variable/#findComment-1479085 Share on other sites More sharing options...
Barand Posted May 11, 2014 Share Posted May 11, 2014 Why not just try it and see? echo $_GET['value']; Link to comment https://forums.phpfreaks.com/topic/288406-escaping-decimals-in-a-url-variable/#findComment-1479090 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.