I have some functions that returns nothing or some value (obvious), and also having a little trouble with the if and closing, is there a good way to do this? I want to return the value after checking if any of the strings are not empty.
Actually it is a search results page. I can have result by links that follow this structure:
search_url(array("xxx" => "name");
and in the array for xxx's is either:
"sPattern"=> "name"
"sRegion"=> "name"
"sCity"=> "name"
so how to do this?
<?php if( sPattern > '') { ?>
echo result
else
<?php if( sRegion > '') { ?>
echo result
else
<?php if( sCity > '') { ?>
echo result
if nothing match do this