I need a code for check if a string is number using php regular expression.
Why using regex for that ? Try is_numeric() ... http://www.php.net/manual/en/function.is-numeric.php At the bottom of the page, you will find a PHP3 regex that does what you want, if you really have to use regex.