Question : How can I find the position of the first occurance of a numeric charater in a string with PHP?

I have a string that holds the company name and the address. I need to break out the address. While not perfect, I believe that finding the position of the first numeric character in the string will let me break out the address using strstr($address,$position_of_first_number)

Is there any elegant way to find the position of the first numeric character in a string using PHP?

Answer : How can I find the position of the first occurance of a numeric charater in a string with PHP?

If your address is just a simple string (no '\n's in it) then this regex will work
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
<?php


     $test = "dasdas, asdasd, 10 the high st, as dsad, asd as, asd asd,sdsad";
     
     $pattern = '/^[^0-9]+([0-9]{1}).+$/';

     preg_match( $pattern, $test, $matches, PREG_OFFSET_CAPTURE );

     echo "First digit at position " . $matches[1][1];
?>

Outputs 

First digit at position 16
Random Solutions  
 
programming4us programming4us