Welcome Guest, Not a member yet? Register   Sign In
pass variable through segments with security
#8

[eluser]coolgeek[/eluser]
[quote author="n0xie" date="1241713512"]If they're ID's I assume they are integers?

If so you could easily check if the id's passed to the method are integers. If so, then your data is secure.[/quote]

Is adding zero to the segment sufficient for ensuring that it is an integer? i.e.

Code:
$var = $this->uri->segment(3) + 0;

or casting it to an int?

Code:
$var = (int)$this->uri->segment(3);


Messages In This Thread
pass variable through segments with security - by El Forum - 05-07-2009, 12:05 AM
pass variable through segments with security - by El Forum - 05-07-2009, 12:49 AM
pass variable through segments with security - by El Forum - 05-07-2009, 03:17 AM
pass variable through segments with security - by El Forum - 05-07-2009, 05:25 AM
pass variable through segments with security - by El Forum - 05-07-2009, 06:24 AM
pass variable through segments with security - by El Forum - 06-13-2010, 08:50 AM
pass variable through segments with security - by El Forum - 06-13-2010, 09:42 AM
pass variable through segments with security - by El Forum - 06-14-2010, 06:01 PM
pass variable through segments with security - by El Forum - 06-20-2010, 04:58 AM



Theme © iAndrew 2016 - Forum software by © MyBB