As Firefox begins to crush my soul on a regular basis, I find myself in Safari more often (which isn’t too often, but enough) and so I’m learning more about this strange beast these days. It still offers no replacement for web developer and tamper data but I recently discovered the “Inspect Element” feature that’s pretty sweet. I found it as an aside in this post about more Safari debugging tools.

First you need to follow the directions from that post - in a terminal window bust out this commandline:

defaults write com.apple.Safari IncludeDebugMenu 1

Start a fresh Safari (quit first if you need to!). Then when you restart first you’ll see a new “Debug” menu item - this has all kinds of stuff that seem quite low level and filled with things I could not decipher in the few minutes I spent perusing them (accept for the User Agent setter, that’s pretty nice). The key bit shows up when you right click on a given web page, you’ll see a new element in the contextual menu that pops up “Inspect Element”.

This gives you a window that shows you all the html, css, images, scripts and other bits that are to be found on the page. In Firefox lingo, it’s like a “view page info” on ‘roids (although it doesn’t provide you the kick ass form information that page info shows you). The key awesomeness is in the Documents drop down - click on your main html and you’ll get a view of the source. Then above that middle pane click on the tabby section (as opposed to the straight lines) you’ll get a better break down (DOM style) of the elements. There you can navigate to the precise html you are looking for and Safari will highlight each part that you click on.

In the right pane it will show you the css styles associated with whatever you are looking for. Very nicely it takes an XRAY like block that shows you how it interprets the block model of the element you’ve viewing (in the metrics drop down).

It is no replacement for Firefox’s development and page inspection tools, but it does offer a nice supplement to them as well as serving in a pinch sometimes if I find myself in Safari. Is there anything else I’m missing in Safari that will improve my quality of life?

← newer Breakfast Links: Foodiebytes, Christians + Athiests & Dark Knight  ↑  Final Relaxation. Ommm….. older →

TwitterCounter for @nybble73