I have this regex:
/^[0-9]+$/i
Used in this code:
preg_match('/^[0-9]+$/i', $var);
I want the following to be true: $var = 1; $var = 50; $var = 333;
And the following to be false: $var = 0; $var = 01; $var = 'abc';
I think what I have works so far except for the "0" part..?
I went through this guide (http://www.phpf1.com/tutorial/php-regular-expression.html) but was unable to come up with a complete answer.
Any help would be appreciated, thanks!
imodifier, if you aren't using any letters ;)