Solved

jsp run on server option not coming

Posted on 2013-01-29
10
444 Views
Last Modified: 2013-02-10
I am trying to run my jsp by right clicking on the file---> run as---->Run on server.

But it is not showing 'Run on server'


It only shows 'Run Configuration'


How do I see option 'Run on server'

As a work around i am setting welcome file in web.xml with this jsp to run.


Please advise. Any ideas, sample code, resources highly appreciated. Thanks

in advance.
jsp.jpg
jsp2.jpg
0
Comment
Question by:gudii9
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 3
10 Comments
 
LVL 20

Expert Comment

by:chaitu chaitu
ID: 38834003
does JSPProject is a web project or java project?
0
 
LVL 20

Expert Comment

by:Sathish David Kumar N
ID: 38834596
your does not code contain <form> tag its important ML(Jsp) page.

if your page contain <form> tag then only your reganice that its web page then only it will come run on server
0
 
LVL 7

Author Comment

by:gudii9
ID: 38835268
It is web project.

let me try with form tag and see.
0
Increase Agility with Enabled Toolchains

Connect your existing build, deployment, management, monitoring, and collaboration platforms. From Puppet to Chef, HipChat to Slack, ServiceNow to JIRA, Splunk to New Relic and beyond, hand off data between systems to engage the right people.

Connect with xMatters.

 
LVL 7

Author Comment

by:gudii9
ID: 38835605
form tag is usually on html page right. Does jsp pages consist of form tag. i want to run jsp pages without form tag. how to do it.Please advise.
0
 
LVL 20

Expert Comment

by:Sathish David Kumar N
ID: 38838536
its main for jsp also .

because that form tag only knows where to go next ! (normaly you mention action ="some java class or jsp  " like that . )

You cant run the jsp page without form tag . because jsp is convert into servlet while compile. that servlet class only your IDE ref . if form tag is there then its web so its enable run on server .
0
 
LVL 7

Author Comment

by:gudii9
ID: 38840305
If you see the Loin.jsp file do have the form ta. Still it is not showin 'Run as Server' option' as in the attachment. Not sure why. Please advise

<%@ page language="java" import="java.util.*" pageEncoding="ISO-8859-1"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
   
    <title>Login page</title>
   
      <meta http-equiv="pragma" content="no-cache">
      <meta http-equiv="cache-control" content="no-cache">
      <meta http-equiv="expires" content="0">    
      <meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
      <meta http-equiv="description" content="This is my page">
      <!--
      <link rel="stylesheet" type="text/css" href="styles.css">
      -->

  </head>
 
  <body>

 <form method="post" action="loginservletpath">
 <br>User Id:<input type="text" name="userId">
 <br>Password:<input type="password" name="password"/>
<br> <input type="submit">
 </form>
  </body>
</html>
loinJsp.jpg
0
 
LVL 7

Author Comment

by:gudii9
ID: 38856165
Does MyEclipse Show 'Run on server' option at all. please advise
0
 
LVL 7

Author Comment

by:gudii9
ID: 38856170
any links to learn how to run servlets, jsps on myeclipse. please advise
0
 
LVL 20

Accepted Solution

by:
Sathish David  Kumar N earned 500 total points
ID: 38858360
change the prespective to j2ee mode i think its in java mode .

in your MyEclispe right corner you can see the prespetive
0
 
LVL 7

Author Comment

by:gudii9
ID: 38872996
oh really, my OS crashed. I will try by reinstalling later
0

Featured Post

Turn Insights into Action

Communication across every corner of your business is essential to increase the velocity of your application delivery and support pipeline. Automate, standardize, and contextualize your communication processes with xMatters.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I had a project requirement for a displaying a user workbench .This workbench would consist multiple data grids .In each grid the user will be able to see a large number of data. These data grids should allow the user to 1. Sort 2. Export the …
Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
Viewers will learn about arithmetic and Boolean expressions in Java and the logical operators used to create Boolean expressions. We will cover the symbols used for arithmetic expressions and define each logical operator and how to use them in Boole…
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …

696 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