yeahz Posted November 2, 2010 Report Share Posted November 2, 2010 function is_empty($value) { $value = preg_replace('/^[ \t]+/', '', $value); return empty($value); } kas ir jāieraksta " '/^[ \t]+/' " vietā, lai arī ierakstot tikai enteru neietu cauri? tagad strādā, ka ja ir saspiesti space tad nelaiž cauri. Quote Link to comment Share on other sites More sharing options...
xPtv45z Posted November 2, 2010 Report Share Posted November 2, 2010 \n Laikam, var būt arī \r\n Quote Link to comment Share on other sites More sharing options...
indoom Posted November 2, 2010 Report Share Posted November 2, 2010 function is_empty($value) { $value = trim($value); return empty($value); } 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.