MyEclipse Forums
This thread has been locked & this forum has been archived.
Please post new topics to General Development
View previous topic Printable version Log in to check your private messages View next topic
Author Message
kulkarni_ash
Post subject: Debug Javascript in jsp  PostPosted: Apr 14, 2006 - 05:30 PM
Veteran Member
Veteran Member


Joined: Mar 18, 2004
Posts: 75

Hi
I have a lot of javascript in JSP head section
can i debug it in myeclipseide??
if yes how, if no are you planning in adding this support?

Also javascript in head section of my jsp is not formatted, when i do
document - format - document

but it works in js file, is this a bug??

Ashish
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
support-rkalla
Post subject:   PostPosted: Apr 16, 2006 - 08:47 PM
Registered Member
Registered Member


Joined: Jan 06, 2004
Posts: 23818

Ashish,
Try and debug your JS in the head of your file, I believe it works for most cases. If it doesn't work, you can just break that code out into it's own separate .js file.

As far as the formatting goes, it should improve moving forward, but may not be available right now due to the complexity of the JSP formatter already.

_________________
Riyad
MyEclipse Support
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
support-rkalla
Post subject:   PostPosted: Apr 17, 2006 - 06:04 PM
Registered Member
Registered Member


Joined: Jan 06, 2004
Posts: 23818

Ashish,
I just got clarification from the dev team that debugging of JS inside of JSP files is not supported, you will need to break it out into a separate JS file for now. We should be addressing this soon.

_________________
Riyad
MyEclipse Support
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
daolwin
Post subject:   PostPosted: Apr 26, 2006 - 09:46 AM
Registered Member
Registered Member


Joined: Mar 02, 2006
Posts: 4

But even by putting them in a separate JS file (as it's the case for me at the moment), it's still not possible to debug them from the JSP file.

D.
 
 View user's profile Send private message  
Reply with quote Back to top
support-rkalla
Post subject:   PostPosted: Apr 26, 2006 - 06:10 PM
Registered Member
Registered Member


Joined: Jan 06, 2004
Posts: 23818

Are you using a standard or professional subscription? Javascript debugging is only in the Pro version (or trial if it's still below the 30 days)

_________________
Riyad
MyEclipse Support
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
smithapendyal
Post subject:   PostPosted: May 05, 2006 - 07:25 PM



Joined: May 05, 2006
Posts: 7

I have Professional subscription of Myeclipse 4.1 and am not able to debug Javascript even if the javascript is in a separate file.

I have Myeclipse set up for remote debugging and am not able to debug Javascript when I run my app.

Smitha
 
 View user's profile Send private message  
Reply with quote Back to top
support-rkalla
Post subject:   PostPosted: May 05, 2006 - 07:32 PM
Registered Member
Registered Member


Joined: Jan 06, 2004
Posts: 23818

Smitha,
Are you sure you are following the very specific steps to debug your JavaScript:
http://www.myeclipseide.com/images/tutorials/quickstarts/javascript/

It's not like JSP debugging, you can't just run the page in your browser, you have to use our special Web 2.0 Browser that is part of MyEclipse now, all the details are in the link above.

_________________
Riyad
MyEclipse Support
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
smithapendyal
Post subject:   PostPosted: May 09, 2006 - 12:29 AM



Joined: May 05, 2006
Posts: 7

I am following the specific steps that are specified in the quickstart.

I have a login.jsp and loginCheck.js files in my struts app.
I have added some breakpoints in my.js file and when I debug the app using Web2.0 browser, I dont see the app stopping at the breakpoints and so am not able to step through.

Am I missing something.

I tried to debug a simple struts app, I am able to do it, but with my app, it doesnt work. Are there any restrictions?

Smitha
 
 View user's profile Send private message  
Reply with quote Back to top
support-rkalla
Post subject:   PostPosted: May 09, 2006 - 12:42 AM
Registered Member
Registered Member


Joined: Jan 06, 2004
Posts: 23818

Smitha,
That sounds right. Setting the breakpoint in the JS file, then right click on the JS and select "Debug As > JavaScript APplication" and enter in a Launch URL pointing at the login.jsp page, then click or do something to cause the JS to get executed.

Is this a project you can send to me and tell me what you are trying to specifically debug? If so, please email it to support@myeclipseide.com ATTN Riyad with a link to this thread so I know why I'm getting the file. (You can use File > Export > To Archive to export the project to a ZIP)

_________________
Riyad
MyEclipse Support
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
support-rkalla
Post subject:   PostPosted: May 09, 2006 - 05:25 AM
Registered Member
Registered Member


Joined: Jan 06, 2004
Posts: 23818

I owe you an appologize, I had a massive crossing of my wires. JS debugging in JSP files is not supported yet, but we have plans to have it in 5.0. I was in such a 5.0 mindset that I hadn't realized the discrepency here. I'm sorry for the inconvenience, we realize this is really a show stopper for a lot of people and hope to address it soon.

_________________
Riyad
MyEclipse Support
 
 View user's profile Send private message Visit poster's website  
Reply with quote Back to top
smithapendyal
Post subject:   PostPosted: May 09, 2006 - 06:29 PM



Joined: May 05, 2006
Posts: 7

I have tried to debugJavascript with a sample struts app that I found in one of the forums and I was able to get it working.But when I apply the same to my app, it doesnt work.

The javascript debugging also works for simple html files.

Is it supported only for simple apps.

I got the sample struts app from the following link and when I debug it, I was able to get it working.

http://www.myeclipseide.com/PNphpBB2+file-viewtopic-t-10801.html

Smitha
 
 View user's profile Send private message  
Reply with quote Back to top
John-N
Post subject:   PostPosted: Aug 27, 2007 - 11:05 PM



Joined: Jul 21, 2005
Posts: 11

Riyad,

I'm having a similar problem with 6.0 M1. I'm trying to debug a separate .js file that is being included into a JSP page in a J2EE application.

The javascript editor allows me to set a breakpoint, but when I get there the debugger does not stop.

I tried both with an external browser, and the Web Browser view in MyEclipse.

Does this have something to do with keeping the JSP source around?

Thanks
 
 View user's profile Send private message  
Reply with quote Back to top
Display posts from previous:     
Jump to:  
All times are GMT - 6 Hours
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.
View previous topic Printable version Log in to check your private messages View next topic
Powered by PNphpBB2 © 2003-2004 The PNphpBB Group
Credits