JSI Tip 1399. How can I display the source of a web page?

Using absolute links:

Click here to view the source of this page.

The above statement is:

<a href="view-source:http://www.jsiinc.com/tip1300/rh1399.htm">Click here to view the source of this page</a>.

To use the FILE protocol, you must use a fully qualified URL:

<a HREF="view-source:file://c:\temp\filename.htm">a filename.htm</a>

Hide comments


  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.