www.webdeveloper.com
+ Reply to Thread
Results 1 to 2 of 2
  1. #1
    Join Date
    Jan 2005
    Posts
    590

    resolved [RESOLVED] again an preg_match question

    I know we had questions like this 1000s of times but I hope someone can help me to figure this one out.

    i found this code
    PHP Code:
    preg_match_all(
                
    "/<A[ \r\n\t]{1}[^>]*HREF[^=]*=[ '\"\n\r\t]*([^ \"'>\r\n\t#]+)[ \"'>\r\n\t#>][^>]*>/isU",
                
    $html,
                
    $matches); 
    This will basically extract all the links from a html page. The problem is that it returns the entire a tag but I wish to have only the actual link within the href attribute

    can someone help me with this?
    http://www.sheersoftware.com - programmers meet here

  2. #2
    Join Date
    Jan 2005
    Posts
    590
    I am stupid. just ignore the above post. it is working
    http://www.sheersoftware.com - programmers meet here

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center



Recent Articles