Re: seperate streetname from number

From: Date: Tue, 11 Mar 2003 19:40:50 +0000
Subject: Re: seperate streetname from number
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-139169@lists.php.net to get a copy of this message
On Tue, 11 Mar 2003 17:17:52 +0100, André Sannerholt <sannerholt@freenet.de> wrote:
Hi everyone! I wondered how to sepearate string variables that contain streetnames and numbers: If for example $variable="Hauptstraße 15"; $variable_string[0] should be "Hauptstraße" $variable_string[1] should be "15" So I need a function that recognizes a number and explodes the variable at that very position. It's important that the thing also works when $variable="Hauptstraße15"; without any space. Else it would have been easy to do with the explode function... Regards André
Try preg_split. -- Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/

« previous php.general (#139169) next »