source
source
Display JavaScript Source Programatically
Mon, 03/23/2009 - 11:20 | by philipnorton42If you are running a JavaScript example page you can use the following function that will take the last script element on the page and print it out in a code tag. It uses JQuery to do the work, so you will need to include that library before using this function.
Using The view-source Protocol
Thu, 08/28/2008 - 09:43 | by philipnorton42If you are running FireFox (or Chrome) then there is a handy little short cut you can use to view the source of a page you are looking at. If you add the text view-source on any web address then you will see the equivalent of viewing the source of a page (perhaps by pressing Ctrl+u). Although not entirely useful, it does have a couple of benefits, such as being able to view your code in another tab, rather than another window.