RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Expressions by User

   Displaying page 1 of 1 pages; Items 1 to 1
Title Test Details Pattern Title
Expression
<\s*a\s[^>]*\bhref\s*=\s* ('(?<url>[^']*)'|""(?<url>[^""]*)""|(?<url>\S*))[^>]*> (?<body>(.|\s)*?)<\s*/a\s*>
Description
Suitable for extraction of all hyperlinks in the format: <a ... href="..." ...> some text </a> from a text document. Separates in groups the components of the links (url and body).
Matches
<a href="javascript:'window.close()'">close the window</a> | <a target=&quo
Non-Matches
<aa href="test.htm">test</a> | < a href hr = 'http://www.nakov.com'>...&
Author Rating: The rating for this expression. Svetlin Nakov
   Displaying page 1 of 1 pages; Items 1 to 1

Copyright © 2001-2024, RegexAdvice.com | ASP.NET Tutorials