Strings Php

$membership = "asdfadsf";
if ( strlen( $membership ) == 4 )
    print "Thank you!";
else
    print "Your membership number must have 4 digits

";
?>