Received: from fslc.ser.usu.edu (fslc.ser.usu.edu [129.123.28.122]) by postgresql.org (8.11.3/8.11.1) with ESMTP id f3NG4s378094 for ; Mon, 23 Apr 2001 12:04:56 -0400 (EDT) (envelope-from rmello@fslc.usu.edu) Received: (from rmello@localhost) by fslc.ser.usu.edu (8.12.0.Beta5/8.12.0.Beta5/Debian 8.12.0-1) id f3NG4n5O015422; Mon, 23 Apr 2001 10:04:49 -0600 Date: Mon, 23 Apr 2001 10:04:49 -0600 From: Roberto Mello To: Christian Marschalek Cc: "[PHP] PostgreSQL" Subject: Re: Splitting strings Message-ID: <20010423100449.A15308@cc.usu.edu> References: <000001c0cc0d$7dfabf40$0200a8c0@server> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.3.17i In-Reply-To: <000001c0cc0d$7dfabf40$0200a8c0@server>; from cm@chello.at on Mon, Apr 23, 2001 at 05:53:08PM +0200 X-Archive-Number: 200104/28 X-Sequence-Number: 281 On Mon, Apr 23, 2001 at 05:53:08PM +0200, Christian Marschalek wrote: > How would you split a string which is seperated by * with PHP? > > Like "abc*def*ghi" into "abc","def","ghi"? $origString = "abc*def*ghi"; $tokens = explode("*",$origString); $token[0] ---> abc $token[1] ---> def ... -Roberto -- +----| http://fslc.usu.edu USU Free Software & GNU/Linux Club |------+ Roberto Mello - Computer Science, USU - http://www.brasileiro.net http://www.sdl.usu.edu - Space Dynamics Lab, Developer Sir -- My first job was programming binary load lifter.