Re: str 2 int

From: Date: Thu, 17 Aug 2000 18:32:31 +0000
Subject: Re: str 2 int
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-12318@lists.php.net to get a copy of this message
On Thu, 17 Aug 2000 venome@gmx.net wrote: > can somebody tell me how to convert a string like "0123" to a number, 123? > > i need to access an array as follows: > > $a = array("yxsc","asdasd",...); > $bla = "2937123721973912732189973"; > print $a[substr($bla,$x,$y)]; > Try casting the variable. $number_variable = (integer) $string_variable; Regards, Joao -- Joao Prado Maia Web Developer Kefta.com, Inc

« previous php.general (#12318) next »