On Sun, 15 Aug 2004 01:17:43 -0500, "Christopher Finke"
<chris@efinke.com> wrote:
[color=blue]
>"D. Alvarado" <laredotornado@zipmail.com> wrote in message
>news:9fe1f2ad.0408141900.21ebda81@posting.google. com...[color=green]
>> Can regular expressions help me here? I want to extract a number
>> from a string which will always be of the form "parameter###" where
>> "###" is an arbitrary number of numeric digits. So if my string
>> contained
>>
>> parameter24
>> parameter8
>> parameter90210
>>
>> I would want to extract "24", "8", and "90210" respectively.[/color]
>
>I can't believe no one has mentioned this:
>
>$string = "parameter1234";
>$number = str_replace("parameter","",$string);[/color]
If I would have seen his post before yours, I would have. :)
Wonder why his isn't in the spool. Hmmmmm...... Better go look.
--
gburnore@databasix dot com
---------------------------------------------------------------------------
How you look depends on where you go.
---------------------------------------------------------------------------
Gary L. Burnore | ÝÛ³ºÝ³Þ³ºÝ³³Ýۺݳ޳ºÝ³Ý³Þ³ºÝ³ÝÝÛ³
| ÝÛ³ºÝ³Þ³ºÝ³³Ýۺݳ޳ºÝ³Ý³Þ³ºÝ³ÝÝÛ³
DataBasix | ÝÛ³ºÝ³Þ³ºÝ³³Ýۺݳ޳ºÝ³Ý³Þ³ºÝ³ÝÝÛ³
| ÝÛ³ 3 4 1 4 2 ݳ޳ 6 9 0 6 9 ÝÛ³
Black Helicopter Repair Svcs Division | Official Proof of Purchase
================================================== =========================
Want one? GET one!
http://signup.databasix.com
================================================== =========================