New To Mac-Forums?

Welcome to our community! Join the discussion today by registering your FREE account. If you have any problems with the registration process, please contact us!

Get your questions answered by community gurus Advice and insight from world-class Apple enthusiasts Exclusive access to members-only contests, giveaways and deals

Join today!

 
Start a Discussion
 

Mac-Forums Brief

Subscribe to Mac-Forums Brief to receive special offers from Mac-Forums partners and sponsors

Join the conversation RSS
OS X - Operating System General OS operation information and support

Debugging JavaScript in Safari


Post Reply New Thread Subscribe

 
Thread Tools
ewgoforth

 
Member Since: Jul 31, 2013
Posts: 2
ewgoforth is on a distinguished road

ewgoforth is offline
Hello,

I'm trying to troubleshoot some problems my website has with Safari. I have Safari 6.0.2 running on a Mac that I'm remoted into via iRAPP. I'm not sure what version of the OS this Mac is using.

From the research I've done, I should be able to step through my JavaScript by going to the Menu and choosing Develop->Start Debugging JavaScript. I've added the Develop menu to my Safari, but I don't see that option, just Start Profiling JavaScript and Start Timeline Recording.

I've added a debugger statement to my JavaScript, but Safari acts as if it isn't there. I've debugged in Chrome, Dragonfly (pre-webkit Opera), FireBug, Venkman, and IE Developer Tools (IE6-10); this is my first time in Safari.

-Eric
QUOTE Thanks
vansmith

 
vansmith's Avatar
 
Member Since: Oct 19, 2008
Location: Toronto
Posts: 18,014
vansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond reputevansmith has a reputation beyond repute
Mac Specs: 2012 13" MBP (2.5 i5, 8GB)

vansmith is offline
Take a look at this document.

Important Links: Community Guidelines : Use the reputation system if you've been helped.
M-F Blog :: Write for the blog
Writing a Quality Post
QUOTE Thanks
ewgoforth

 
Member Since: Jul 31, 2013
Posts: 2
ewgoforth is on a distinguished road

ewgoforth is offline
Quote:
Originally Posted by vansmith View Post
Take a look at this document.
Thanks, that had some useful information, but the only method I saw for stepping into your JavaScript (Putting a breakpoint next to the line of code), didn't really make sense in the context I'm in. I don't have a big block of JavaScript, like a standalone .js file, but instead have a block that's onclick attribute of an anchor tag.

I did figure out how to get it to break though. I found in the little icon bar at the top of the Web Inspector, to the right of "Issue" (Exclamation Point) icon, I found a debug icon. The icon looks kind of like two horizontal parallel lines with a dashed line in the middle. I clicked on that and the next time I clicked on my anchor, it "saw" the debugger statement and stopped there.

-Eric
QUOTE Thanks

Post Reply New Thread Subscribe


« Updating O/S | transfer videos to face book »
Thread Tools

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread
Thread Starter
Forum
Replies
Last Post
iOS 6 bug reenables JavaScript in Safari without user consent OneMoreThing... Apple Rumors and Reports 0 12-21-2012 04:10 PM
Safari and Skype stopped working simultaneously. Help! chiyo OS X - Operating System 5 03-30-2011 03:04 PM
Javascript Show/Hide in Safari Kush Web Design and Hosting 2 02-10-2006 03:02 PM
Safari is the browser to use on OS X!! Computer.Geek OS X - Apps and Games 14 04-29-2005 03:01 PM
Javascript and Frames problem in Safari HarrySpier Web Design and Hosting 3 11-09-2004 04:47 PM

All times are GMT -4. The time now is 11:37 PM.

Powered by vBulletin
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
X

Welcome to Mac-Forums.com

Create your username to jump into the discussion!

New members like you have made this community the ultimate source for your Mac since 2003!


(4 digit year)

Already a member?