http://qs1969.pair.com?node_id=725071


in reply to RE: Extract and modify IMG SRC tags in an HTML document.
in thread Extract and modify IMG SRC tags in an HTML document.

This is a very old thread but its really important for me... I need to modify the hrefs and the src tags for proxy. but the problem is some hrefs are like href="/page.html" href="../page.html" href="http://url" href=url ... src="/abc.jpg".... What I am doing is downloading the page source using Lynx. ThenI have to modify all the links like www.yahoo.com example www.abc.com/cgi-bin/proxy.pl?http://www.yahoo.com then clicking on any link on that page will download the other page source and proceeds the same way.

Replies are listed 'Best First'.
Re^3: Extract and modify IMG SRC tags in an HTML document.
by nel (Initiate) on Feb 24, 2013 at 20:33 UTC
    I tried this code snippet however its not working in my case. Any help i could get inorder to change src and add an onclick event in an image tag?