Web Project

I have a WEB project in JDev and under web Content directory I have a package called "mypackage", and under that package I have a java file called myjava
Under Web Content directory I also have a JSP in which I reference that java class file as:
<jsp:useBean id="user" class="mypackage.myjava" scope="session"/>
I am getting an error: Type mypackage.myjava not found.
Where else do I have to create this file so that my jsp runs?

It seems to me that it should work that way.
What's your JDeveloper version?
A good programming practice is naming classes with the first character in uppercase.
http://geosoft.no/development/javastyle.html
Although, it comes from another ide and forum, this could be of some help:
http://www.coderanch.com/t/478897/vc/jsp-useBean-type-package-class
NA
http://nickaiva.blogspot.com
Edited by: Nick Aiva on Jan 29, 2011 9:36 PM

Similar Messages

  • Eclipse web project using Glassfish 4.1 can not load some libraries in modules directory

    We installed latest "Glassfish Tools for Luna" (updated on 2 October 2013) and created a new Eclipse dynamic web project using Glassfish 4.1. When try to annotate a class with "javax.enterprise.context.ApplicationScoped", it complains as "ApplicationScoped cannot be resolved to a type" although imported as "import javax.enterprise.context.ApplicationScoped".
    Checking "glassfish-4.1/glassfish/modules/" directory and there is cdi-api.jar that contains ApplicationScoped class. But when checking from the project libraries in the eclipse, couldnt see such a jar.
    My configuration:
    Eclipse 4.4
    Glassfish runtime java development kit : java 1.8.0_20
    Project java development kit : java 1.8.0_20
    Project compiler level : 1.8
    Project facets : Dynamic web module 3.1, Java 1.8, Glassfish Web Extensions 4.0, Javascript 1.0
    How to solve this issue?
    Thanks.

    There are 274 jars in the Glassfish 4.0 modules directory, whereas there are 282 jars in the Glassfish 4.1 modules directory. So it is not only cdi-api.jar. Moreover there are some libraries, the names of which have been changed.
    Why not simply importing all libraries in the modules directory to Eclipse, like Tomcat plugin does for tomcat/lib directory? So when manually deploying a library(jar) to modules directory Eclipse will discover it automatically.
    Thanks.

  • How to change the application alias for a web project in NW7.2

    Hi,
    a simple question, but I could not manage to solve it: How do I change the application alias (the url) of a web project? I'm using Netweaver 7.2 and all the tutorials I found refer to earlier versions and do not work anymore.
    In particular, I would like to change e.g. "server.com/vendor~webbappname" (the standard url of the web project) to "server.com/mywebapp".
    Thanks in advance for your help!

    Hi,
    Try customizing the <context-root> element in the web.xml deployment descriptor, for example:
    <?xml version="1.0" encoding="ASCII"?>
    <application xmlns="http://java.sun.com/xml/ns/javaee"
               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
              http://java.sun.com/xml/ns/javaee/application_5.xsd"
               version="5">
               <display-name>YourWebApp</display-name>
               <module>
                   <web>
                   <web-uri>YourWebApp.war</web-uri>
                   <context-root>mywebapp</context-root>
              </web>
         </module>
         <module>
              <ejb>YourWebAppEjb.jar</ejb>
         </module>
    </application>
    Afterwards, rebuild and redeploy your application.
    I hope that helps.
    Regards,
    Yordan

  • Images do not show up in web project in J2EE application[/b]

    I have cretead a web project in which i hava a servlet and couple of jsp's and some java util classes. This application gets the data from the database and displays it on a screen. Beside displaying, this app also transform the xml document to html using. I have the the XSL Stlesheet under Web Content along with all the jsp's.
    I also have images folder under Web-Content which has all the images for this application. When i run the application using Oracle 10g application server within Jdev, the application cannot find the images or the xsl stylesheet. Relative path to images in jsp is /images/someimage.gif while relative path to xsl is /some.xsl. For some reason it cannot find the images or the xsl when the application runs or deployed in OC4J container. Any help on this will be appreciated.
    I have checked the path in reference to the context-root and it seems to be correct.

    Relative path to images in jsp is /images/someimage.gif while relative path to xsl is /some.xsl.
    Is the images dir under the jsp dir?
    If the images dir and the jsp dir are at the same level, the relative path would be ../images/someimage.gif

  • How to create the Custom project System as Web Project

    Hi,
    I have created a custom project system using this walkthrough. But
    this walk through is targeting Visual C# project system. I need to create the Custom project system as Web project and set the start up page as index.html file. How can I achieve this?
    Note: 
    I have got the Custom project system sample from VS2013 SDK samples(https://mpfproj12.codeplex.com/).
    But it demonstrate the Custom console applications only.
    - Abbas K

    Hi,
    So you didn't even follow this walkthrough yet? If you did, how did you do it?
    I failed to create such a web project system because I finally messed up my VS experimental instance. But it's possible to create a custom web project system, by following this walkthrough. Someone else has successfully made it, check this
    link.
    The difference is that you have to use web project type instead of the console application project type. You could copy a web project's .csproj file into the VSPackage project and rename it to xxx.myproj. There's an error in the walkthrough that the AssemblyInfo.cs
    file should be put into Properties folder and set the "Build Action" property to Content, "Include in VSIX" to true.
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • How does Azure Compute Emulator (or the Azure one) determine if a role is web project or something else ("The Web Role in question doesn't seem to be a web application type project")?

    I'm not sure if this is F# specific or something else, but what could cause the following error message when trying to debug locally an Azure cloud service:
    The Web Role in question doesn't seem to be a web application type project.
    I added an empty F# web api Project to a solution (which adds Global.asax etc., I added an OWIN startup class Startup etc.) and then from an existing
    cloud service project I picked Roles and
    chose Add
    -> Web Role Project in solution, which finds the F# web project (its project type guids are 349C5851-65DF-11DA-9384-00065B846F21 and F2A71F9B-5D33-465A-A702-920D77279786),
    of which the first one seem to be exactly the GUID that defines a web application type.
    However, when I try to start the cloud project locally, I get the aforementioned error message. I have a C# Web Role project that will start when I remove the F# project. I also have F# worker
    role projects that start with the C# web role project if I remove this F# web role project. If I set the F# web project as a startup project,
    it starts and runs as one would expect, normally.
    Now, it makes me wonder if this is something with F# or could this error message appears in C# too, but I didn't find anything on Google. What kind of checks are there when starting the emulator and which one needs
    failing to prompt the aforementioned message? Can anyone shed light into this?
    Sudet ulvovat -- karavaani kulkee

    Sudet,
    Yeah you are right, the GUID mentioned seems to be correct and the first one i.e. {349C5851-65DF-11DA-9384-00065B846F21} means the web application project which compute emulator uses to determine while spawning up role instances.
    You might want to compare the csproj of your C# and F# web projects which might give some pointers.
    Are you able to run your F# web project locally in IIS? If yes then you will definitely be able to run it on azure so I will recommend to test it in IIS Express first.
    Here are some other tips which you can refer or see If you are yet to do those settings
    1. Turn on the IIS Express - You can do it by navigating to project properties
    2. Install Dependent ASP.NET NuGets / Web Api dependencies (If there are any missing), Reference System.Web assembly
    Also I will suggest to refer this nice article about how to create a F# web Api project
    http://blog.ploeh.dk/2013/08/23/how-to-create-a-pure-f-aspnet-web-api-project/
    Hope this helps you.
    Bhushan | http://www.passionatetechie.blogspot.com | http://twitter.com/BhushanGawale

  • Jsf web project is not working in eclipse ConfigureListener

    Hi, I created a dynamic web project in eclipse with tomcat server, I also referenced the jsf jar files, besides the web.xml files contains <listener-class>com.sun.faces.config.ConfigureListener</listener-class>; even though when I run the web project or the jsp file, it appears with the following error:
    Estado HTTP 404 - /ejmweb6/start.jsp
    INFO: Starting Servlet Engine: Apache Tomcat/6.0.14
    25-abr-2010 22:46:10 org.apache.catalina.core.StandardContext listenerStart
    Error configuring class listener com.sun.faces.config.ConfigureListener
    java.lang.NoClassDefFoundError: javax/servlet/ServletRequestListener
    java.lang.NoClassDefFoundError: javax/servlet/ServletRequestListener
         at java.lang.ClassLoader.defineClass1(Native Method)
         at java.lang.ClassLoader.defineClass(Unknown Source)
         at java.security.SecureClassLoader.defineClass(Unknown Source)
    Caused by: java.lang.ClassNotFoundException: javax.servlet.ServletRequestListener
         at java.net.URLClassLoader$1.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
    Can you help me with problem? please
    Regards
    Carlos

    That class should be provided by the application server. Double check that the version of Tomcat you have supports servlet 2.4. Also check there are no bug reports against it for this error.

  • Importing web project into Workshop 9.2

    Hi,
    I'm trying to import an existing web project into Workshop 9.2.1 from my Subversion source. Unfortunately Workshop doesn't recognize this project as a valid web project.
    I imported the code project using 'File>Import>Existing Projects' into Workspace.
    Unfortunately, I get the following errors:
    - "The library module reference : beehive-netui-1.0 is not allowed from the classpath of a non-web project, only JAR,EJB, and EAR module types are allowed."
    - "The library module reference : jstl is not allowed from the classpath of a non-web project, only JAR,EJB, and EAR module types are allowed."
    How do I tell Workshop that this project is indeed a web project?
    Does anyone have any suggestions?
    Thanks,
    Derrek

    Wow.... I figured out a workaround (aka Ugly Hack). It seems that Workshop doesn't properly import Portlet projects. Here's how I got around it:
    1. Checkout the code from Subversion
    d:\MyProjects\Project\trunk\MyComponent\
    2. Move MyComponent to a temp directory
    d:\MyProjects\Project\trunk\MyComponent\ --> d:\tmp\MyComponent
    3. Open Workshop and create a new Portal project and PortalEAR project of the same name as the MyComponent projects
    File>New myComponentPortal
    4. Copy over the src and WebContent directories in the SVN directory with the files from tmp.
    d:\tmp\MyComponent\src -> d:\MyProjects\Project\trunk\MyComponent\src
    d:\tmp\MyComponent\src\WebContent -> d:\MyProjects\Project\trunk\MyComponent\WebContent
    5. Refresh Workshop and let the spooky voodoo happen. Viola! Now I've got a running portal project with a SVN connection.

  • How can I use my log4j config file of my web project in ias?

    I used log4j in my web project. So I put a config file "log4j.properties" in my project WEB-INF/classes/.
    It works well in tomcat. But when I deploy it to ias parent by orabpel project, It didn't work know!
    I can only see my log in "$ORACLE_HOME/opmn/logs", and some message I nedd is losed, such as the class name, line,datetime, Thread and so on.
    I think the config file of my project is't work, maybe log4j use some config file of ias but me.thx
    So where is the log4j config file of ias, can i modify it ?
    Or how can I let my project use my config file not ias? Any one can help me, thx!

    If you are wondering if/how to control the log messages coming from bpel, here is the corresponding log4j config file that it uses:
    $ORACLE_HOME/bpel/domains/<DOMAIN_NAME>/config/log4j-config.xml

  • Not able to create a web project with jsf or jsp or struts or spring

    Hi,
    I am trying to create a dynamic web project with jsf or jstl or struts or spring or any of web options available for a web project, but I am not able to do it.
    When I choose any of these options, the wizard asks me to "select an existing jstl/jsf/Spring 2.0 library, or click Add to add a new library." and since it doesn't show any existing libraries there, I clicked on add new library. When I click add, it opens a new dialog box where it has two options :
    1. to use spring/jstl/jsf lib from bea web site - when I choose this option, it tries to connect to the bea web site and gives me error that "connect time out". I don't know why it is not able to connect to the internet. I am not able to see the help also. There it gives error "The requested URL could not be retrieved".
    2. to use libraries from an existing spring installation - I provide the path of a directory where spring lib are, but then it gives me error that this is not a valid installation.
    On another machine, I am able to see the help contents, but still not able to get these libraries from the bea site.
    Please help.
    Thanks in advance,
    Sushma

    Hi Sushma,
    The issue you are facing has been addressed and will be part of the next release. For the current release, please follow the steps listed below.
    Send an email to [email protected] with details on specific facets you are trying to enable on your project.
    You will be provided with a url where you can download the required jars and details on how to manually add the jars to the workspace which will prevent the download on demand scenario.
    Cheers
    Raj

  • How to add a custom web project to creator?

    I am using Creator EA2. I want to add a custom web project, which is created based on standard web project, to Creator. I wonder if it is possible by creating a jar and put it into a directory or I should develop a plugin with layout description files, templates?
    Thanks
    jnewbie

    If your struts-enabled project is already compatible with Creator (i.e. you can open it in the IDE) you can get close to what you way using the project template facility available in EA2.
    Select Tools->Project Template Manager. From the template manager dialog, click the Add... button and browse to your struts project. The project should appear under the My Templates node in the dialog. Close the dialog and bring up the New Project Wizard. You should see a new project category called My Templates which should contain an entry to your custom project. You can now select this project and proceed through the wizard which will actually clone the project for you as if it were a custom project type.

  • Creation of a context listener in a web project

    Hello.
    We need to create a custom context within a web application.
    In other projects what we do is create an implementation of the class javax.servlet.ServletContextListener, and reference it as a listener in the web.xml. This alows us to create threads within the container of the server, for instance.
    The problem is that after I create the web project in my developer studio 7.2 the class javax.servlet.ServletContextListener is not found within the classpath, that is referencing a Java CE 7.2 server.
    The project I created received the SAP Java EE 5 Library, but the class is not present in that.
    Is there another library from SAP I need to add? If I import that class from another jar, will it be well supported by the server?
    Thanks!

    I found the solution, that was only related to problems on my classpth. Thanks!

  • Applet location in a Web project

    Hi All,
    I have a question regarding deploying an applet in JDeveloper 10.1.3.
    The applet is part of a web project so when compiling the project the .class file ends up in WEB-INF/classes together with the servlet classes and not visible from the applet html page.
    What is the right way of handling this in JDeveloper?
    Currently I have created a different project for the applet and have it deployed as a jar file in the public_html directory of the webapp. Then I can "run" my webapp and the html applet page will be able to access the applet.
    Is there a better/automatic way of handling this?
    Thanks in advance
    Regards,
    Sebastian

    Sebastian,
    not that I am aware of. The issue you are running into is that the HTM page does a request to the class or jar file in the WEB-INF directory, which by definition is protected from direct browser access. I think the solution you worked out is elegant to use.
    Frank
    Ps.: I'll keep this thread reference to look at it for an ER or documentation

  • File Reading in Web Project, file path help.

    Hi,
    I have a web project with the folloing directory structure.
    Thesis
    > build
    > dist
    > nbproject
    > src
    > test
    > web
    Using netbeans and GlassFish V2 webserver I'm trying to call a function in a Java file (src folder) from a JSP file (web folder).
    In my java source code I have the following line:
    BufferedReader in = new BufferedReader(new FileReader("data.txt"));
    which means the file should be found at the root of the project (Thesis). However after many hours of frustration, I finally found out that when my project gets deployed to GlassFish server, my program is trying to look for the data.txt file in "C:\Program Files\glassfish-v2ur2\domains\domain1\config\"
    I got the path from with the following command in my java code
    File file = new File("highscore.txt");
    System.out.println(file.getCanonicalPath());
    Is there anyway of changing the path it is looking for? I've tried looking throught all the settings in GlassFish and cannot find anything that is set as "C:\Program Files\glassfish-v2ur2\domains\domain1\config\"
    Thanks

    Don't cross-post - it's rude:
    http://forum.java.sun.com/thread.jsp?thread=519223&forum=31&message=2479278
    http://forum.java.sun.com/thread.jsp?thread=519222&forum=33&message=2479275
    %

  • Converting Air Project to Web Project in Flash Builder 4

    I have an Air project that I need to convert to a web project to post online.  I've looked online with no luck so far, but perhaps someone can point me in the right direction.
    The closest thing I see to being what I want is if I go to Properties > Run/Debug Settings.  In there I tried going to New > Web Application but when I browse for Project it comes up empty, and so is the "Application file" dropdown.  I tried screwing around int he Source tab in the same window but it doesn't seem to help much.
    Other things that look close to what I want but don't work are when I right click my project, there's a "Add/Change project type" but all options are greyed out and I don't see anything web related in the options anyway.
    Also there's Properties > Targeted Runtimes, but there's nothing there I can do.
    Then in Properties > Flex Compiler I have "Generate accessible SWF file" checked.  But when I try to use that file it won't work in the browser flash player.
    So... is there an easy way to convert an Air project to a Web project?
    Thanks!

    I'm glad (but at the same time sad) someone has had the exact same problem I had.
    I've tried a few things (though none successful).
    - creating a flash pro project from the fb project
    - creating an AS3 project from the as3 mobile project (which runs on air). now this one I thought would work, and it does in Flash Player, however, when I try to run it with the generated html file, all I get is a string of errors.
    Here is something that does work.
    If you create an AIR project in Flash Pro (I've only tried this in CS5.5), when you publish the project, it will generate the swf and html files and the html file works and the swf runs great. Unfortunately you have to start that way (which sucks for programmers that want the benefits of Flash Builder). I haven't found anything to properly convert it yet.
    I hope this is some insight, even a year later.

  • Crystal Report 4 Eclipse Web Project

    Hi guys,
    I have a crystal web project which connect to the RAS server and display a report. I just downloaded the CR4E and created a web project with the "new project" wizard. I copied my old project's code and libraries to this CR4E project without overriding anything in the lib folder. When I run the project on server, I get the following error:
    INFO  LogManager org.apache.jsp.testOpenReport_jsp._jspService(testOpenReport_jsp.java:167) - Open document.
    7/05/2009 12:41:38 org.apache.catalina.core.StandardWrapperValve invoke
    SEVERE: Servlet.service() for servlet jsp threw exception
    java.lang.NoSuchMethodError: com.crystaldecisions.sdk.occa.report.application.ReportAppSession.setCommunicationAdapter(Lcom/crystaldecisions/proxy/remoteagent/ICommunicationAdapter;)V
         at com.crystaldecisions.sdk.occa.managedreports.ras.internal.RASReportAppFactory.a(Unknown Source)
         at com.crystaldecisions.sdk.occa.managedreports.ras.internal.RASReportAppFactory.a(Unknown Source)
         at com.crystaldecisions.sdk.occa.managedreports.ras.internal.RASReportAppFactory.openDocument(Unknown Source)
    The error came from here:
    reportAppFactory = (IReportAppFactory)enterpriseSession.getService("RASReportService");     
    LogManager.getLogger().info("Open document.");
    reportClientDocument = reportAppFactory.openDocument(oInfoObject, 0, Locale.ENGLISH);
    Is this library issue? If yes, which set of jar files should I use with CR4E to access RAS server?
    Thanks,
    Jun Dong

    CR4E is a Component SDK solution.
    RAS is a server-client solution.
    You cannot use the CR4E SDK in lieu of the RAS SDK to communicate with the RAS server.
    You must use the RAS SDK jars that come with the RAS server.
    The APIs are very similar - however, the backends are different.
    Sincerely,
    Ted Ueda

Maybe you are looking for

  • How can I delete all my contact card "custom images"?

    Hi, My contact images have been (mysteriously) randomly mixed... I just can't delete them one by one because there are hundreds and hundreds of them. How can I delete them all? This situation is also verified in my iCloud contacts, which is obvious s

  • How can I execute command passwd in solaris with Java (ProcessBuilder)

    Hi all, my problem is that I want to change the user password in solaris 10, but from a Java programm, I was trying with ProcessBuilder but I don't know how insert the new password, Who can help me?

  • Restoring/Formatting my ipod classic?

    After replacing my ipod classic for a third time, the sales representative, to test my ipod, plugged it into his mac. The ipod began to optimize itself for a mac. he assured me this was no problem, and so I went on my way. When I home, I plug in the

  • HR ABAP: Infotype 25 updation

    In my server table PA0025 is empty.....even i entered data (annual aprrisal ) for infotype 25 and save then also the table PA0025 is not updated.....!! Can anybody explain me why its behave like this??? and also <b>How to update the table PA0025 tabl

  • Dump when executing DTP right after infopackage in BI 7.0 SP 7

    Hello. whenever I try to execute DTP <b>right after</b> run infopackage (eg.master loading), exception error occurs like below. <b><u>"A RAISE statement in the program "SAPLRSSTATMAN" raised the exception"</u></b> can't find any notes related to this