{"id":708,"date":"2012-01-19T11:35:42","date_gmt":"2012-01-19T21:35:42","guid":{"rendered":"http:\/\/mymonkeydo.com\/?p=708"},"modified":"2020-05-03T16:30:16","modified_gmt":"2020-05-04T02:30:16","slug":"debugging-websites-for-iphone","status":"publish","type":"post","link":"https:\/\/mymonkeydo.com\/debugging-websites-for-iphone\/","title":{"rendered":"Debugging Websites for iPhone"},"content":{"rendered":"
I created a website that looked great in IE7+, FF, Chrome, and Safari, but on the iPhone a few things looked off. \u00a0Problems could be from the viewport being 480px wide but the website is 1000px wide so using percentages can mess it up… that’s another post sorry. \u00a0The problem is, how do I use something like firebug to debug the css and html in the iPhone mobile Safari browser?<\/p>\n
<\/p>\n
<\/strong> One thing annoying is that you can’t add CSS attributes to existing CSS classes. \u00a0A way around this is to add attributes to the element.style section for the element you want to alter. \u00a0Another thing I noticed is that the Simulator freezes from time to time. \u00a0To “unfreeze” it I had to quit both the simulator and iWebInspector and start over. \u00a0Other that it’s great!<\/p>\n <\/p>\n I prefer the first solution over this one because obviously, Firebug is very small on the iPhone.<\/p>\n <\/p>\n keywords:\u00a0iphone safari on desktop, iphone firebug
\nThe best solution is if you have a Mac OS X and the iOS 5 SDK. \u00a0If you don’t have a Mac or \u00a0you don’t have iOS5 SDK and don’t want to download it from the Mac App Store, move on to the next solution. \u00a0This solution involves a great FREE tool to debug, profile, and inspect \u00a0web applications running in the iPhone simulator is iWebInspector <\/a>by Max Firtman. \u00a0 This tool, as it says in the tool, enables a private API available on the iOS 5 framework. \u00a0It lets you inspect the web page or webapp \u00a0similar to firefox. \u00a0To use it:<\/p>\n\n
\nA second option to debug a website in the iPhone is by using Firebug Lite<\/a>. \u00a0Here’s what you do:<\/p>\n\n
javascript:(function(F,i,r,e,b,u,g,L,I,T,E){if(F.getElementById(b))return;E=F[i+'NS']&&F.documentElement.namespaceURI;E=E?F[i+'NS'](E,'script'):F[i]('script');E[r]('id',b);E[r]('src',I+g+T);E[r](b,u);(F[e]('head')[0]||F[e]('body')[0]).appendChild(E);E=new%20Image;E[r]('src',I+L);})(document,'createElement','setAttribute','getElementsByTagName','FirebugLite','4','firebug-lite.js','releases\/lite\/latest\/skin\/xp\/sprite.png','https:\/\/getfirebug.com\/','#startOpened');<\/pre>\n<\/li>\n
\nsources:
\nhttp:\/\/www.iwebinspector.com\/<\/a>
\nhttp:\/\/martinkool.com\/post\/13629963755\/firebug-on-ipad-and-iphone<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_genesis_hide_title":false,"_genesis_hide_breadcrumbs":false,"_genesis_hide_singular_image":false,"_genesis_hide_footer_widgets":false,"_genesis_custom_body_class":"","_genesis_custom_post_class":"","_genesis_layout":"","footnotes":""},"categories":[2],"tags":[17,21,38],"yoast_head":"\n