manalnor Posted March 18, 2010 Share Posted March 18, 2010 Hello Friends if we have $manal = "1"; // 1 digits and $shams = "over"; then i'd like to say if $manal less than 6 digits then $final = $shams does php have abilities to descibe such case. thanks in advance Link to comment https://forums.phpfreaks.com/topic/195716-less-than/ Share on other sites More sharing options...
herghost Posted March 18, 2010 Share Posted March 18, 2010 there is probably a better way but if ($manal < '99999') { $final = $shams } Link to comment https://forums.phpfreaks.com/topic/195716-less-than/#findComment-1028224 Share on other sites More sharing options...
strangesoul Posted March 18, 2010 Share Posted March 18, 2010 hello, i think this must work for you: $manal = '1'; $shams = "over"; $temp = "temp"; if(strlen($manal)<6) { $final = $shams; } else { $final = $temp; } Link to comment https://forums.phpfreaks.com/topic/195716-less-than/#findComment-1028260 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.