Re: ereg help
| From: | Jim | Date: | Mon, 03 Dec 2001 16:48:26 +0000 |
| Subject: | Re: ereg help | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-76392@lists.php.net to get a copy of this message | ||
This is a good starter about PHP and regular expressions.
http://www.phpbuilder.com/columns/dario19990616.php3
----- Original Message ----- From: "Valentin V. Petruchek" <petruchek@zsu.zp.ua> To: <php-genral@lists.php.net> Sent: Monday, December 03, 2001 6:35 PM Subject: [PHP] ereg help-- Jim Musil --------- Multimedia Programmer Nettmedia ------------- 212-629-0004 jim@nettmedia.comI'm not new for php, but have no experience working with ereg functions.Myproblem is the following: i have string.. for examplestudying$s="id {name,title,nick} [http://www.php.net]";i want to break it in several parts: $p[0]="id"; $p[1][0] ="name"; $p[1][1] ="title"; $p[1][2] ="nick"; $p[2]="http://www.php.net"; The part in [] is not neccessary, count of {} elements is not less than 1 I can do it with string fucntions, but it seemes to me it's better to use regular functions. Could anybody help me to solve this problem and advise resource forregular expresions? Zliy Pes, http://zliypes.com.ua-- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net