Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re^2: regular expression (blah blah blah)

by ansh batra (Friar)
on Jan 07, 2013 at 09:34 UTC ( [id://1011991]=note: print w/replies, xml ) Need Help??


in reply to Re: regular expression (blah blah blah)
in thread regular expression

it is fetching the whole img tag
i need only value of src attribute

  • Comment on Re^2: regular expression (blah blah blah)

Replies are listed 'Best First'.
Re^3: regular expression (blah blah blah)
by Corion (Patriarch) on Jan 07, 2013 at 09:36 UTC

    Most likely what Anonymous Monk showed you was not supposed to be the complete regular expression but intended to be used for matching the src attribute only. You will have to apply that hint appropriately.

Re^3: regular expression (blah blah blah)
by Anonymous Monk on Jan 07, 2013 at 09:36 UTC
    Did you try to understand my regex pattern? YAPE::Regex::Explain? Put it in your regex, match up the quotes, delete your stuff, use my stuff
      Although your suggestion makes the REGEX better, the primary problem is that $& contains the entire match, not the first subpattern ($1).

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1011991]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others meditating upon the Monastery: (5)
As of 2024-04-19 12:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found