Solved

server problem or my coding is wrong...   plz help...

Posted on 2004-04-16
5
187 Views
Last Modified: 2010-04-01
i am using linux redhat and installed tomcat.

i tried to test my server, thus i wrote a little simple jsp

<%@ page language = "java" import = "java.util.*, java.lang.*"%>
<%
out.println("test");
%>

however, it does not work...
u can see the result at
http://207.218.249.233:8080/vcclient/test.jsp

however, when i input a wrong url, tomcat logo actually shows up
http://207.218.249.233:8080/vcclient/test/

thus, i am not sure if my code is wrong or i did not install the tomcat, right??


Please Help
0
Comment
Question by:bionicblakey
5 Comments
 
LVL 92

Expert Comment

by:objects
Comment Utility
what is it u see?
0
 
LVL 13

Expert Comment

by:copyPasteGhost
Comment Utility
your folder must be contain a folder called web-inf and then be deployed in tomcat..did you do that?
Ghost
0
 

Author Comment

by:bionicblakey
Comment Utility
i move the jsp into web-inf, but it still did not work...

it just print out my jsp code...

0
 
LVL 1

Expert Comment

by:KartikShah
Comment Utility
Try to split the following line:

-----
<%@ page language = "java" import = "java.util.*, java.lang.*"%>
-----

<%@page language = "java"%>
<%@import = "java.util.*, java.lang.*"%>

and try .. and also .. the JSP file needs to be outside the WEB-INF dir ... i.e. at the same level as that of WEB-INF or in a directory structure .. that is at the same level as that of WEB-INF
0
 
LVL 13

Accepted Solution

by:
copyPasteGhost earned 500 total points
Comment Utility
>bionicblakey

there is no need to split this line.
<%@ page language = "java" import = "java.util.*, java.lang.*"%>

your  jsp page must not be in the web-inf folder
it must be at the same level
if you have class files that you wish to import or have some jar files that you want to include in your project then you place those files in the web-inf folder
it's like this, I'll try to draw you a directory sturcture of what I mean..

--jsp Files
--WEB-INF
      --classes
           --your .class java files that you wish to import (note these must be in package as of tomcat 5.x)
      --lib
           --your .jar files that you wish to include into your project
      --tlib
           --your custom tags that you want to have in your project

I hope that's clear,
if you don't understand what I mean let me know
Cheers,
Ghost
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

Suggested Solutions

This article will show you how to create an ISO CD-ROM/DVD-ROM image (*.iso), and MD5 checksum signature, for use with VMware vSphere Hypervisor 6.5 (ESXi 6.5). It's a good idea to compare checksums, because many installations fail because of a corr…
Veeam Backup & Replication has added a new integration – Veeam Backup for Microsoft Office 365.  In this blog, we will discuss how you can benefit from Office 365 email backup with the Veeam’s new product and try to shed some light on the needs and …
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now