aentice
asked on
a href link in JSP
I'm just learning JSP and I have a simple problem, how can I create a link.
This is part of a left menu that is suppose to link to a different page.
<A HREF="<%= PMPage.jsp %>" style="text-decoration:non e" class="A">PARK</a>
This is part of a left menu that is suppose to link to a different page.
<A HREF="<%= PMPage.jsp %>" style="text-decoration:non
ASKER
I had it initially that way, but doesn't work. If I try Park/PMPage.jsp
Here's how my folder looks like:
TESTWEB
WebContent
images
Park
PMpage.jsp
Web-INF
LeftMenu.jsp
main.jsp
Here's how my folder looks like:
TESTWEB
WebContent
images
Park
PMpage.jsp
Web-INF
LeftMenu.jsp
main.jsp
Then it looks as if your URL is wrong.
where does your Web app start? If it's the WebContent directory, then your url should be
/Park/PMpage.jsp -- notice that you're spelling it wrong, too, if the latest post is correct. If the file is PMpage.jsp, then PMPage.jsp will not exist.
where does your Web app start? If it's the WebContent directory, then your url should be
/Park/PMpage.jsp -- notice that you're spelling it wrong, too, if the latest post is correct. If the file is PMpage.jsp, then PMPage.jsp will not exist.
ASKER
I tried that too. When I add /Park/PMpage.jsp the link becomes Park/Park/PMPage.jsp instead to just one Park it becomes 2.
ASKER
I tried one that worked, but it should not be done this way. I moved the page under WEB-INF and mixed it together with the other pages, it seems like it cannot find the Park folder and I'm not sure how the structure works.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
check you context root in ear.
add context root to jsp path
add context root to jsp path
<A HREF="PMPage.jsp" style="text-decoration:non