name="[a-zA-Z_]+[0-9]+.gif"
name="([a-zA-Z_]+)([0-9]+).gif"

I like the parentheses because I like to retrieve data I'm replacing.
But that may not matter

They did say "the # can be any length".

This has all been tested on the examples:

<img name="regressed8.gif">
<img name="regressed.gif">
<img name="8p.gif">
<img name="9.gif">
<img name="g3.gif">
<img name="regressed.gif">
<img name="regressed_923.gif">

And it finds 1, 5 and 7 as it should, I think.

On 4/22/05, Ben Doom <[EMAIL PROTECTED]> wrote:
> If you drop the parens, you'll get better performance.  Also, if there's
> only one digit before the dot, you can drop the + after the [0-9].
> 
> Also, this won't match bob_jones7.gif.  I don't know if that's important
> or not.
> 
> --Ben
> 
> Tony Hicks wrote:
> > This seems to work fine:
> >
> > name="([a-zA-Z]+)([0-9]+).gif"
> >
> >
> 
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Discover CFTicket - The leading ColdFusion Help Desk and Trouble 
Ticket application

http://www.houseoffusion.com/banners/view.cfm?bannerid=48

Message: http://www.houseoffusion.com/lists.cfm/link=i:21:871
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/21
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:21
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.21
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to