I recently started coding online and i have the weirdest response, my code is: 

<?php

include 'function.inc';

echo "$id<br>";

print (gettype($id));

if ($id = "add" )

{

echo "is add";

exit;

}


if ($id = "own" )

{


echo "id is own";

exit;

}

if ($id = "all" )

{


echo "id is all";

exit;

}

?>

$id in this case  = "own", but it totally ignores this value and uses the first if 
statement and treats $id as if it has a value of "add". I am very frustrated and i 
really hope someone can help me. The server is linux, and php version 4.1.2

Thanks

Reply via email to