Sure- $test = "text1";
if(substr($test, -1) == 1){ print "do something"; } else{ print "didn't equal 1 "; At 08:00 AM 5/17/2002 -0400, Natividad Castro wrote: >Hi to all, >how can I evaluate a variable? >For example >$test = "test1"; >then I want to evaluate if $test contains 1 at the end. >Is there any way to evaluate that variable to see if the number 1 is at the >end? >Thanks >Nato > > >-- >PHP Database Mailing List (http://www.php.net/) >To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php