Add link around img tags with regexp
Posted
by rdanee
on Stack Overflow
See other posts from Stack Overflow
or by rdanee
Published on 2010-06-06T18:01:44Z
Indexed on
2010/06/06
18:12 UTC
Read the original article
Hit count: 254
I would like to add links around image tags with preg_replace().
Before:
<img href="" src="" alt="" />
After:
<a href="" ..><img href="" src="" alt="" /></a>
I would greatly appreciate any help. Thank you very much.
© Stack Overflow or respective owner