Packaging jsp's in diffrent jar's!

Hello
I'm new to JSF and would like to start a project based on JSF 1.2. As my application invoves lots of business modules, need to package each module separately.Means backing bean,resourcebundle and jsp's will be packaged separately for each module.
Unfortunately system fails to load jsp if I put it in jar file (this jar is available in web-inf/lib) instead of web application war file directly.
Can anybody suggest me any solution on the same.
Thanks
Jobinesh

Thank you very much RaymondDeCampo for your quick response.
But I happened to see Tapestry supports this kind of requirement. There we can keep jsp's separately under different projects and war file would contain different artefacts(jars) cotaining jsps.
So I assume that somebody might have already faced this situation.
One work around would be to copy th jsp's to web app target folder as part of build process(ant/maven). But looking for more elegant solution.
Can anybody share their knowledge on the same
Thanks
Jobinesh

Similar Messages

  • Possible to check in Java, if if a package is already in the jar-Cache?

    I have an applet, that has only one main.jar in the Cache-Archive parameter.
    Because I wanted to reduce the preload-Time, since 1.4.0 I use an index.list file, listing
    the rest of jar-Files needed for my applet. So the jar-Files will be only
    downloaded to the time, they are needed, if they aren't already in the jar-cache.
    The Problem: If the applet needs a new jar-File, that isn't in the jar-Cache, it needs
    time to download the package. But the user doesn't see that something happens.
    Is it possible to check with JAVA in the applet, if a package is already in the jar-Cache?
    If i know this, I'll be able to show the user that the applet is currently downloading a package.

    do u mean a file in the JAR?
    if yes, yes u can check that.
    check this,
        public ImageIcon loadImage(String location)
    java.net.URL url =  null;
    url = getClass().getResource(location);
    if (url == null) then ...
        } 

  • Urgent: Does dbms_java package is required  to load jar file into database?

    Hi, It's a urgent request. I am trying to install jar file that was created by JDeveloper into database using loadjava. But it is giving so many errors.
    Do we need to install dbms_java package in order to load jar files into the database? Thanks.

    Thanks for your reply Kamal.
    I am trying to load these jar files into Oracle 9.2.0.3.20 database.
    Could you please give me the list of the steps to enable java within the database? Thanks.

  • JSP import fails unless Jars are included in the PAR

    Hello,
    We have a simple EP6 iView for displaying the Universal Worklist entries (UWL) using a JSPDynPage.
    We import the UWL library symbols and compile/use them in the Java code without problems (e.g. import com.sap.netweaver.bc.uwl.Item; )
    The following entry is made in the portalapp.xml file to make sure the UWL symbols are found at runtime:
         <property name="ServicesReference" value="SAPJ2EE::library:tckmcbc.uwl~api"/>     
    The problem occurs when we try to import the UWL symbols into our JSP with this code:
         <%@ page import="com.sap.netweaver.bc.uwl.Item" %>
    The UWL symbols are just not found.  Here are the exception headers:
    #1#com.sapportals.portal.prt.component.PortalComponentException: Error in service call of Resource
    Component : pcd:portal_content/MikesFolder/com.lds.mlp.MikesTest1
    #1#com.sapportals.portal.prt.servlets_jsp.server.compiler.CompilingException: Error occurs during the rendering of jsp component
    Caused by: com.sapportals.portal.prt.servlets_jsp.server.compiler.CompilingException: D:/usr/sap/EP1/JC00/j2ee/cluster/server0/apps/sap.com/irj/servlet_jsp/irj/root/web-inf/portal/portalapps/mikestest1/work/pagelet/_sapportalsjsp_helloiviewpage.java:22: package com.sap.netweaver.bc.uwl does not exist
    import com.sap.netweaver.bc.uwl.Item;
                                    ^
    1 error
    Now if I add the bc.uwl.service.api_api.jar into PORTAL-INFlib everything is fine.  However this seems like such a 'hack'.  We really shouldn't be distributing a system file in our PAR.
    This person seems to have had the same problem with the system mail jars ( JSP MAIL ERROR ).
    Can anyone please shed some light on this problem?  Do we really have to distribute the system jars to make this JSP import work properly?
    Thanks & Cheers,
    Mike Pastor
    "always generous with points"

    Hi,
    This is exactly the portalapp.xml of the sap application com.sap.netweaver.bc.uwl.par
    check out the difference between this and yours?
    Dont miss out on anything important here. I think it should work.
    If you are still facing problem only while using in jsp I have a cure.
    Write a clean java class in your app which queries the apis in this jar.
    Also add sharing reference to this application in your portalapp.xml. Query your class in your jsp rather than the "standard jar"
    <?xml version="1.0" encoding="utf-8"?>
    <application>
      <registry>
        <entry path="/runtime/hooks/deployment/UniversalWorklistDeploymentHook" name="UniversalWorklistDeploymentHook" type="service"/>
      </registry>
      <application-config>
        <property name="startup" value="true"/>
        <property name="releasable" value="true"/>
        <property name="ServicesReference" value="SAPJ2EE::library:tckmcbc.uwl~api,SAPJ2EE::service:webdynpro,com.sap.portal.runtime.system.inqmy, com.sap.portal.ivs.connectorservice,com.sap.portal.ivs.systemlandscapeservice, urlgenerator, com.sap.portal.usermapping, usermanagement, com.sap.portal.runtime.application.rfcengine,com.sap.portal.runtime.config,knowledgemanagement"/>
        <property name="PreservedConfigPaths" value=""/>
        <property name="Vendor" value="sap.com"/>
        <property name="SecurityArea" value="NetWeaver.KMC"/>
      </application-config>
      <components/>
      <services>
        <service name="com.sap.netweaver.bc.uwl" alias="UniversalWorklistService">
          <service-config>
            <property name="className" value="com.sap.netweaver.bc.uwl.core.portal.UWLPortalService"/>
            <property name="classNameFactory" value=""/>
            <property name="classNameManager" value=""/>
            <property name="poolFactory" value="0"/>
            <property name="startup" value="true"/>
            <property name="SafetyLevel" value="low_safety"/>
          </service-config>
        </service>
        <service name="UniversalWorklistDeploymentHook">
          <service-config>
            <property name="className" value="com.sap.netweaver.bc.uwl.core.portal.UWLDeploymentHook"/>
            <property name="classNameFactory" value=""/>
            <property name="classNameManager" value=""/>
            <property name="poolFactory" value="0"/>
            <property name="startup" value="true"/>
            <property name="SafetyLevel" value="low_safety"/>
          </service-config>
        </service>
      </services>
    </application>

  • Packaging of EAR / WAR / EJB-JAR

    Hello,
    I have a big application to do.
    So, one solution should be to use an EAR for one module, containing the WAR for the web-tier and the EJB-JAR for the business-tier.
    It would be better doing like this than creating a big WAR, in order to avoid to deploy a big WAR when a modification is done in one module.
    What about the problem of the session ?
    In fact, I have to declare a context-root for one EAR.
    And at each context-root is created an object HttpSession on the server.
    So, I have some questions about this :
    - How can I configure my WARs in order to use only one HttpSession object for every WARs ?
    - Can I put multiple WARs in one EAR ? If yes, what about the context-root ? This solution would resolve the session problem.
    Thanks in advance.
    bgOnline

    Hello,
    I have a big application to do.
    So, one solution should be to use an EAR for one
    module, containing the WAR for the web-tier and the
    EJB-JAR for the business-tier.
    It would be better doing like this than creating a
    big WAR, in order to avoid to deploy a big WAR when a
    modification is done in one module.Are you using local EJBs or remote EJBs? The only way for a war to talk to a local EJB is to package the war along with the ejb-jar in an EAR file because they need to be collocated. You can not simply bundle EJB classes in a war file.
    If you are using remte EJBs, then you can package the EJB client view classes along with the servlets and JSPs in the war file and deploy the war separately. But again your war will be one big war.
    If your EJBs are just entity beans, then Java EE 5 (see http://weblogs.java.net/blog/ss141213/archive/2005/12/using_java_pers.html) allows you some nice options.
    >
    What about the problem of the session ?
    In fact, I have to declare a context-root for one
    EAR.
    And at each context-root is created an object
    HttpSession on the server.
    So, I have some questions about this :
    - How can I configure my WARs in order to use only
    one HttpSession object for every WARs ?
    There is no standard way to do this. Relying on any application server specific feature can only make your app non-portable. So I strongly recommend you not to do this.
    - Can I put multiple WARs in one EAR ?Of course you can.
    If yes, what about the context-root ? This solution would resolve
    the session problem.Can't be solved using any standard way. So I suggest you stick to one big war, if that's what your business requirement is.To speed up development-deployment-test cycle, any appserver allows a rapid deployment option where in you can deploy incremental changes to server. Use this facility during development. DON'T sacrifice portability of your app by using any product specific configuration that you may not find any where else.
    Thanks,
    Sahoo

  • JSP Exception after making JAR

    Hi,
    I'm getting this exception while I package my java class files and properties files as a jar and put it in library. I'm using struts framework which extensively uses tiles. After packaging I dont have any files in the classes directory but all the files are in the library.
    while I debug it goes to Action classes and it executes JSPs so it was able to refer classes properly. But failes in some taglibs.
    Any help would apprieciated.
    ServletException in:/layout/channelpage_enhanced.jsp] null' javax.servlet.ServletException at org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:843) at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:776) at org.apache.jsp.layout.channelpage_005fenhanced_jsp._jspService(channelpage_005fenhanced_jsp.java:1373) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:672) at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:574) at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:499) at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:966) at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:602) at org.apache.struts.tiles.TilesUtilImpl.doInclude(TilesUtilImpl.java:137) at org.apache.struts.tiles.TilesUtil.doInclude(TilesUtil.java:177) at org.apache.struts.taglib.tiles.InsertTag.doInclude(InsertTag.java:756) at org.apache.struts.taglib.tiles.InsertTag$InsertHandler.doEndTag(InsertTag.java:881) at org.apache.struts.taglib.tiles.InsertTag.doEndTag(InsertTag.java:473) at org.apache.jsp.layout.standard_005ftemplate_jsp._jspService(standard_005ftemplate_jsp.java:867) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:672) at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:463) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:398) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301) at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069) at org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:274) at

    Instead of building your class files into a jar you might want to consider building the entire web application into a war file for deployment. I do this even for deployment to my local test server just to keep things more similar between my local server and the deployment server.
    This is an excerpt from my ant build
        <target name="build.war">
            <echo message="Building the war file for the web application"/>
            <war
                 destfile="${p.app.jar.dir}/appname/WarFile.war"
                 webxml="${web.module.web-inf.dir}/web.xml">
                <fileset dir="${web.module.resource.dir}">
                    <include name="*.*"/>
                </fileset>
                <classes dir="${web.module.classes.dir}"/>
                <fileset dir="${p.app.jar.dir}/appname">
                    <include name="*.jar"/>
                </fileset>
                <fileset dir="${web.module.web-inf.dir}">
                    <include name="*.*"/>
                </fileset>
                <manifest>
                    <attribute name="Class-Path" value="Service-client.jar"/>
                </manifest>
            </war>
        </target>Just a thought your milage may of course vary.
    PS.

  • Include directive to include a JSP file from a JAR file

    I have an Eclipse project in which I have placed a JSP file in the package structure with the rest of my code. This is in fact only a code snippet page, not a full blown JSP file.
    I have a second project that is a Dynamic Web Project in Eclipse that incorporates the first project as a JAR in the /WEB-INF/lib directory.
    In this project I have a JSP file and I want to include the JSP file embedded in that JAR file.
    How do I do that?
    I'm thinking the only real solution is to rewrite the snippet portion as a custom tag.

    The JSP fragment page in question is actually a HTML form page. It is a form to be used specifically by a particular servlet. That is why they are "bundled" together in the same project, in the same package structure.
    I have multiple web applications that I want to include that form/servlet, so it gets added to these projects in the /WEB-INF/lib folder as a JAR library. But I don't want to recreate the form over and over again for each application. It would be nice if I could write a JSP page that wraps the fragment using an include directive to bring that fragment into the new page.
    So to do that with any other fragment I would write:
    <%@ include file="/WEB-INF/jsp/SOME_FORM.jsp" %>
    which works great if my fragment page is in the /WEB-INF/jsp subfolder. But if I want to access the JSP fragment as it is bundled in a JAR file, this:
    <%@ include file="/WEB-INF/lib/FORM.jar/SOME_FORM.jsp" %>
    doesn't work so good. It's just all wrong.
    I was wondering how I could just write one include statement to get what I need. There are work-arounds galore, but I thought if I could get this working it would be the simplest solution overall.

  • How to package an application as a JAR file?

    I want to package an executed JAR file,how to do?
    "jar cvf jar_name class_name"? But it can't run,:( help me.
    Thanks in advance.

    Suppose your main class call MyMainClass. You need to create a file called "mymanifest". In the mymanifest file, you need to include following line:
    Main-Class: MyMainClass
    Then you need to jar your jarfiles by:
    jar cvfm classes.jar mymanifest -C foo/ .
    After this, you can run your jar file by java -jar classes.jar.

  • Help! How to use a custom package (in the format of .JAR) in Forte4Java!

    Dear all,
    I am a beginner with Java. I have downloaded a Java package, jacob.jar, from the Internet. In order to import it in my Java program written under Forte4Java, I did the following stuff:
    1. Mount this JAR to the FileSystem; (this should include this package to the classpath, right?)
    2. Right-clicked the mounted JAR, and from the popup menu choose "Tool | Update Parser Database...";
    Next, I create a new Java project with a main class in it. At the head of this class file, I typed "import" to refer to this package. It turned out that the contextual completion window DOES show my package and all of its classes properly. In the body of this class file, I called some of the public methods defined in this package. The contextual completion window showed those methods properly too. Then I built this project and NO compilation error was reported. But, at run-time, an exception of "java.lang.UnsatisfiedLinkError: no jacob in java.library.path" was thrown at the invocation of the first public method of this package. I don't know what's happening here. Did I install the package the wrong way? If I can't get this problem solved as soon as possible, I will be in big big trouble :-( Please help and thanks in advance....
    FYI:
    the full exception message is as followed:
    java.lang.UnsatisfiedLinkError: no jacob in java.library.path
    at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1312)
    at java.lang.Runtime.loadLibrary0(Runtime.java:749)
    at java.lang.System.loadLibrary(System.java:820)
    at com.jacob.com.Dispatch.<clinit>(Dispatch.java)
    at testjacob.TestJACOB.main(TestJACOB.java:27)
    Exception in thread "main"
    Regards,
    Tracy

    I am not sure how exactly Forte works, so I don't know how useful my reply is, but here it is:
    Try checking the classpath manually that always helps. Your classpath should contain the directory in which the jar file is.
    Which OS are you using?

  • Don't know package of class in a jar using URLClassLoader

    Hello,
    i want to load a class out of a jar file but the only thing i know is the classname its the same as the jarname. the problem now is i packed the plugin as nice with packages and my Loader won't find the class without package, what can i do to know the package?
    i don't have any main method because it's a plugin loading. i know der should be a possibility to loop through all classes?! or even to find a class implementing an interface (but that was something with ServiceLoader)...how can i do it?
    for(int i = 0; files != null && i < files.length; i++) {
         MyClassLoader pluginLoader = null;
         try {
              pluginLoader = new MyClassLoader(MyConstants.MODULES_PATH+files);
         } catch(MalformedURLException e) {
              System.out.println("Exception: " + e.getMessage());
         // cut off extension for className
         int dot = files[i].lastIndexOf(MyConstants.MODULE_EXTENSION);
         String className = files[i].substring(0, dot);
         MyPluginInterface plugin = null;
         try {
              plugin = (MyPluginInterface)pluginLoader.findClass(className).newInstance();
         } catch(Exception e) {
              System.out.println("Exception: " + e.getMessage());
    this works (for one of the jars with this package then):plugin = (MyPluginInterface)pluginLoader.findClass("my.package.in.jar."+className).newInstance();
    public class MyClassLoader extends URLClassLoader {
         public MyClassLoader (String filenName) throws MalformedURLException {
              super(new URL[]{new File(filenName).toURI().toURL()}, MyClassLoader.class.getClassLoader());
         public Class<?> findClass(String name) throws ClassNotFoundException {
              return super.findClass(name);
    thx for you help!                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    YES! just a bit of work and it's running nice :-)
    if(!(Constants.MODULES_PATH.endsWith("/"))) Constants.MODULES_PATH = Constants.MODULES_PATH + "/";
    File path = new File(Constants.MODULES_PATH);
    if(path.exists() && path.isDirectory()) {
         // find all .jar files
         String[] files = path.list(new FilenameFilter() {
              public boolean accept(File d, String name) { return name.endsWith(Constants.MODULE_EXTENSION); }
         for(int i = 0; files != null && i < files.length; i++) {
              // create class loader for jar
              MySystemClassLoader classLoader = null;
              try {
                   classLoader = new MySystemClassLoader(Constants.MODULES_PATH+files);
              } catch(MalformedURLException e) {
                   System.out.println("Exception: " + e.getMessage());
              // load service(s)/module(s) (can be more than one in a jar!)
              ServiceLoader<ModuleInterface> moduleLoader = ServiceLoader.load(ModuleInterface.class, classLoader);
              for(ModuleInterface module : moduleLoader) {
                   System.out.println("load module: "+module.getClass().getName()+"!");
    }and this as class loader (given to the service loader)public class MySystemClassLoader extends URLClassLoader {
         public MySystemClassLoader(String filenName) throws MalformedURLException {
              super(new URL[]{new File(filenName).toURI().toURL()}, MySystemClassLoader.class.getClassLoader());
         public Class<?> findClass(String name) throws ClassNotFoundException {
              return super.findClass(name);
    in the jar-file (module/service) you need a file named as the interface (path.to.package.ModuleInterface) inside of a folder "META-INF/services/" and contains just as a string (path.to.package.ModuleImplementation) the name of the implementaion class (in the jar-file)
    Edited by: mrp_cologne on Jul 21, 2008 3:55 AM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • URL Mapping for packaged JSP's in web.xml file

              Hi,
              I am using weblogic6.0sp2 enterprise edition.I have my JSP's in package structure.
              Suppose my login.jsp is in package com.advice.document. So for URL mapping in
              web.xml what should be given so that by giving that my JSP runs. I have tried
              many options but not got success.
              Here is my web.xml file..
              <web-app>
              <servlet>
              <servlet-name> Login </servlet-name>
              <jsp-file> com\advice\document\login.jsp</jsp-file>
              </servlet>
              <servlet-mapping>
              <servlet-name> Login </servlet-name>
              <url-pattern> /Login</url-pattern>
              </servlet-mapping>
              </web-app>
              If any body knows or have worked on the same then let me know.
              Thanks in advance.
              --- Vipul
              

    Did you try specifying the jsp-file with forward slashes (e.g.,
              com/advice/document/login.jsp)?
              Vipul Garg wrote:
              > Hi,
              > I am using weblogic6.0sp2 enterprise edition.I have my JSP's in package structure.
              > Suppose my login.jsp is in package com.advice.document. So for URL mapping in
              > web.xml what should be given so that by giving that my JSP runs. I have tried
              > many options but not got success.
              > Here is my web.xml file..
              > <web-app>
              > <servlet>
              > <servlet-name> Login </servlet-name>
              > <jsp-file> com\advice\document\login.jsp</jsp-file>
              > </servlet>
              > <servlet-mapping>
              > <servlet-name> Login </servlet-name>
              > <url-pattern> /Login</url-pattern>
              > </servlet-mapping>
              > </web-app>
              >
              > If any body knows or have worked on the same then let me know.
              > Thanks in advance.
              > --- Vipul
              

  • Packaging JSP files.

    Hi all.
    Just a quick question that I can't find an answer to.
    Is it possible to put jsp files into packages? For example, say I want to have two JSPs with the same name, can I do something like:
    com.somepackage.Login.jsp
    and
    com.someotherpackage.Login.jsp
    rather than just putting them all in the webapps/myapp directory?
    And if so, how do I configure Tomcat, and how do I reference each one?
    Many thanks

    Hi all.
    Just a quick question that I can't find an answer
    to.
    Is it possible to put jsp files into packages? For
    example, say I want to have two JSPs with the same
    name, can I do something like:
    com.somepackage.Login.jsp
    and
    com.someotherpackage.Login.jsp AFAIK, no.
    rather than just putting them all in the
    webapps/myapp directory?
    You could ofcourse put them in sub-directories under myapp and not necessarily directly under myapp. So if you put your jsps under a folder
    , say, jsp which in turn is under the root folder myapp, they should be
    accessed as /jsp/filename.jsp. You could logically partition the jsps
    into sub-folders and say, you have folders like foo and bar inside your
    jsp folder, then the jsps would be accessed as /jsp/foo/filename.jsp and /jsp/bar/filename.jspAlternatively you could define a url for each jsp in your web.xml, just like
    how you do for servlets. For this use the <jsp-file> tag in place of
    <servlet-class> in your web.xml.
    By doing so, you register a JSP as a servlet using the <servlet> tag. In this example a URL containing /main will invoke myJSPfile.jsp:
    <servlet>
         <servlet-name>myFoo</servlet-name>
         <jsp-file>myJSPfile.jsp</jsp-file>
    </servlet>
    <servlet-mapping>
         <servlet-name>myFoo</servlet-name>
         <url-pattern>/main</url-pattern>
    </servlet-mapping>Registering a JSP in this manner allows you to specify the load order, initialization parameters, and security roles for a JSP, just as you would for a servlet.
    cheers,
    ram.
    >
    Many thanks

  • Unable to edit JSP files in a JAR file

    Hi,
    I am trying to edit biller direct screens and I am not able to open any JSP or XML file in NWDS editor. I get this below error whenever I try to edit a JSP file
    cannot open default editor on content_custExtension_html.jsp. Unsupported editor input type org.eclipse.jdt.internal.ui.javaeditor.JarEntryEditorInput
    any help will be rewarded for sure
    Thanks and regards,
    Nrisimhanadh Yandamuri

    Was mistaken... have to edit similar source in another DC.

  • Help me,JSP is not recognizing the class which in in jar under root of ear

    <%@ page import="com.sample.components.HttpUtil"%>
    I am not able to get the HttpUtil class in my JSP.Above is my declaration .I am getting compilation error.
    The HttpUtil class is under components package,which was in components.jar.
    And it is kept under root of ear.And the classpath for web is having entry of that jar.
    Please help me

    I changed the <form> in the jsp to div and its working fine. I do not need to have comments in JavaScript funcion() anymore. I don't know why that made the difference though? According to:
    http://www.w3schools.com/tags/tag_form.asp
    The <form> tag is used to create an HTML form for user input.
    The <form> element can contain one or more of the following form elements:
    <input>
    <textarea>
    <button>
    <select>
    <option>
    <optgroup>
    <fieldset>
    <label>
    An HTML form is used to pass data to a server.
    I do have <button> and also send the data - the value of checkboxes - to server. So I think it should also work with <form>.
    Please let me know if you have any idea. Thanks.

  • Moving a functional jsp and jar file to new directory breaks import?

    Simply put - how can I "move" or "copy" a functional JSP directory from the root of my site to a subdirectory
    of the same site and have it continue to work?
    here are the details:
    I have a site where the functional JSP content resides like so ...
    c:\site\itworkshere\thetestfile.jsp
    c:\site\itworkshere\WEB-INF\web.xml
    c:\site\itworkshere\lib\thejarfile.jar
    c:\site\itworkshere\classes\props.properties
    but when I copy the"itworkshere" directory to c:\site\newdirectory\itworkshere
    and try to load thetestfile.jsp page in my browser, I get ...
    thetestfile$jsp.java:6: Package com.corporatename.module.io not found in import.
    I know that the module.io classes are in thejarfile.jar, but for some reason, now that I've put the files
    in a new directory, the import is failing (simple import directive in thetestfile.jsp) And - yes - the .jar
    file is there in the new subdirectory.
    I am a newbie with jsp and just need to copy the files to new location and have them continue to work.
    Do I have to recompile the .jar with some sort of adjustments? I poked around and I don't see any assumptions about the directory structure in the build. The behavior leads me to believe that the build is assuming something
    about its location in the directory tree.
    Hope this question is clear and I appreciate any direction you can provide to steer me where to look/modify
    the necessary changes so I can move the .jsp's and .jar and not break them.

    Thanks for the suggestions and insights. I have made some progress.
    a context path of "/newdirectory/itworkshere" and a docBase of "./newdirectory/itworkshere" has resolved
    the .jsp include problem.
    However this seems a bit counter-intuitive to me considering that the default root context which is "" stands
    at the appBase which in my case is C:\Site. Since the default does not explicitly refer to the "itworkshere" directory,
    I'd expect that the newly added Context element would not have to either ---- BUT --- it does require that I include "itworkshere" in the context path and docBase (where I would expect ./newdirectory would have been sufficient since the default works that way) ... am I missing something?
    Now I havethe next odd behavior - the Servlet which resides in "itworkshere\WEB-INF\lib" is not loading when I put the appropriate URL in --> /newdirectory/itworkshere/DataCrunchingServlet
    I checked the web.xml file and it has the appropriate servlet-name and url-pattern (relative references)
    Furthermore I did a test where I simply rename the original working instance directory and again --- the URL is failing to find the servlet!!! (and yes I stopped/started Tomcat) It is as if the servlet can only be found in the originally installed scenario.
    I am extremely puzzled that the behaviors seem to indicate an assumption about the path structure, but the web.xml file is set up correctly.
    Help help!!! and Thank you.l

Maybe you are looking for

  • Moving I Tunes Files to an external hard drive

    How do I move my Movies out of I Tunes and on to an external hard drive?

  • Extract expense for a designated cost center group

    Hi, There is a problem that we want get expense for a designated cost center group instead of cost center and store in the cube. We can get the cost center group but it is a node in a hierachy. I don't know how to map cost center to it's group. Thank

  • EA6900 - How many wireless users do you have?

    Hey all, I have another post researching why my EA6900 keeps shutting down my wifi users while the router itself otherwise seems healthy.  Currently, the support team is wondering if I'm maxing out my wifi connections.  Is there anyone out there who

  • Query is running from a long time

    it just keeps running for a long time without returning any results. I am pasting here the execution plan for this query,please let me know which part could tune , | Id  | Operation                                  | Name                     | Rows 

  • Tvtime has no sound: no 'mixer' device in /etc? [~SOLVED]

    Hi everybody Every audio app were workin fine in this location up to 1 or 2 days ago. Got latest Alsa & edited /etc/modprobe.conf accordingly to alsa wikki a long time ago, removing anything but those lines: alias snd-card-0 snd-intel8x0 alias sound-