My blog has moved!

You should be automatically redirected in 6 seconds. If not, visit
http://www.mattdturner.com/wordpress
and update your bookmarks.

AdSense

Pages

Showing posts with label iPhone. Show all posts
Showing posts with label iPhone. Show all posts

Monday, April 25, 2011

Finding Text on Any Website on the iPad, iPhone, and iPod

One rather frustrating thing that I have noticed with the iPad (and iPhone) is the inability to search for text within Safari.  Well as it turns out, a simple javascript bookmark is all you need to add this functionality to any iOS device (just like my post on viewing source code).

To enable finding text within any website, follow the below instructions:

  1. Open Safari (pretty self explanatory).
  2. Create a new bookmark.
  3. In the Title window, write whatever you want your bookmark to be named (I chose "Find on Page")
  4. In the address bar add the following javascript code:  
    javascript:void(s=prompt('Find text:',''));s='('+s+')';x=new RegExp(s,'gi');rn=Math.floor(Math.random()*100);rid='z' + rn;b = document.body.innerHTML;b=b.replace(x,'$1');void(document.body.innerHTML=b);alert('Found ' + document.getElementsByName(rid).length + ' matches.');window.scrollTo(0,document.getElementsByName(rid)[0].offsetTop);

NOTE: As with the post on viewing source code, I did not develop this javascript bookmark. All credit goes to Matthew Panzarino.

Friday, April 22, 2011

How to View HTML Source Code on iOS | iPad, iPhone, iPod

Occasionally, when browsing the web I have a need to view the source code for a certain page.  However, there is no intrinsic way to do so on the iOS version of safari.  Well, using some simple javascript bookmark you can view the source code for any webpage.

To view the source code, follow the below instructions:

  1. Open Safari (duh!)
  2. Click the "Add Bookmark" button in Safari.
  3. Give the bookmark whatever name you wish; I chose the title "View Source".
  4. In the address bar of your new bookmark, paste the following code: 
    javascript:var%20sourceWindow%20%3D%20window.open%28%27about%3Ablank%27%29%3B%20%0Avar%20newDoc%20%3D%20sourceWindow.document%3B%20%0AnewDoc.open%28%29%3B%20%0AnewDoc.write%28%27%3Chtml%3E%3Chead%3E%3Ctitle%3ESource%20of%20%27%20%2B%20document.location.href%20%2B%20%27%3C/title%3E%3C/head%3E%3Cbody%3E%3C/body%3E%3C/html%3E%27%29%3B%20%0AnewDoc.close%28%29%3B%20%0Avar%20pre%20%3D%20newDoc.body.appendChild%28newDoc.createElement%28%22pre%22%29%29%3B%20%0Apre.appendChild%28newDoc.createTextNode%28document.documentElement.innerHTML%29%29%3B
  5. Now just navigate to whichever page you wish to view the source of, click the bookmarks button, and select your new View Source bookmark.
NOTE: I did not create this javascript bookmark.  I only discovered it while browsing the internet.  For the source of the javascript bookmark, please see Rob's Blog.

Thursday, April 21, 2011

My Top 10 iPhone Jailbreak Apps | April 2011

About once a month or so, I search around online for the best iPhone jailbreak apps.  I don't usually have the time to search through all of the new released in Cydia, so I tend to rely on other people's posts.

In an effort to provide some app ideas to new jailbreakers, below is a list of my 10 favorite jailbreak apps for the iPhone (in no particular order).


1. LockInfo

To me, this is an absolute must have app for the iPhone.  What this app does is puts many iPhone notifications together into a single user-friendly UI.  There are many different plugins for LockInfo, such as a plugin that displays RSS Feeds, a plugin that displays tasks from the AppStore 2do app, etc.

For a list of all native plugins, please see Plugins.