Ads 468x60px

Monday, July 11, 2011

iPhone display the HTML source code of web pages

For business or simple curiosity can be useful to view the HTML source code of a website. Today we see how to do this directly on the iPhone and iPod Touch.

Here are the steps to follow:

1. Follow this guide directly from the iPhone

2. Select and copy the following code:

javascript: var%% 20% 3D% 20sourceWindow 20window.open 27about% 28% 27% 29% 3Ablank%%% 20% 3B% 0Avar 20newDoc 
% 20% 3D% 20sourceWindow.document% 3B% 20% 28% 29% 0AnewDoc.open% 3B% 20% 0AnewDoc. 
write% 28% 27% 3E% 3Chead 3Chtml% 3E%%% 3Ctitle 3ESource% 20of% 20% 27% 20% 2B% 20document.location.href 
% 20% 2B% 20% 27% 3E% 3C/title% 3E% 3Cbody 3C/head%%% 3E% 3E% 3C/body 3C/html% 3E% 27% 29% 3B% 20%% 0AnewDoc.close 
28% 29% 3B% 20% 20% 0Avar 20pre%%% 3D% 20newDoc.body.appendChild 28newDoc.createElement 22pre% 28% 29% 29% 22% 
% 3B% 20% 0Apre.appendChild 28newDoc.createTextNode%%% 29% 29% 28document.documentElement.innerHTML 3B

3. Safari create a new bookmark and name it "Source Code"

4. Save

5. Now go back to the Favorites menu, click Change and select the bookmark you just created

6. Paste into the address field of the code that you copied in step "2".

Done. Now whenever you open a web page and select the preferred "Corice Source", Safari will display the HTML on the site.



Post from my iPad 2

0 comments:

Post a Comment