davidf85 Posted September 12, 2011 Share Posted September 12, 2011 $page = (isset($_GET["page"]))?$_GET["page"] : 1 ; This is from a pagination script, and I am wondering what the ? means here, and what the : does. Link to comment https://forums.phpfreaks.com/topic/246976-code-explaination/ Share on other sites More sharing options...
AbraCadaver Posted September 12, 2011 Share Posted September 12, 2011 Ternary operator, simplified IF / ELSE: http://php.net/manual/en/language.operators.comparison.php Link to comment https://forums.phpfreaks.com/topic/246976-code-explaination/#findComment-1268394 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.