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 Quote Link to comment 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 } Quote Link to comment 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; } Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.