开发者

Can't edit *.jsp file

I wanted to understand what a *.jsp file is doing from a website. So I downloaded that file. Also, in order to edit it, I downloaded "lomboz" with eclipse to open this. But when I opened the file, it displayed junk characters! (But I'm sure it worked fine with browser, I just wanted to see the code behind it.)

Is this because the developer had encoded the *.jsp file in some way (for secur开发者_Go百科ity reasons)? Or it just because I am doing something wrong?

This is what I got

Can't edit *.jsp file


From the first line:

ÿØÿà  JFIF

That's not a JSP file. That's a JPEG file. Rename it to .jpg and open it with an image viewer. Perhaps you were just taking a screenshot of the JSP result in the webbrowser.

Note that there is no way to get/download JSP source code by just viewing the page in some webbrowser. JSP runs on webserver, produces some bunch of HTML upon a HTTP request, webserver sends that HTML to webbrowser and webbrowser displays that HTML. The JSP source code has to be obtained from the local disk file system in the webserver which usually takes place by FTP or SCP.


Unrelated to the concrete problem, I recommend using just "Eclipse for Java EE" instead of "Lomboz" to develop with Java EE web applications (including JSP/Servlet). To get started with JSP/Servlet, I recommend to get yourself through our tag wiki pages:

  • JSP tag wiki page
  • Servlets tag wiki page

They in turn contain several tutorial links at the bottom.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜