jsp:useBean /jsp:useBean

Hi,
I am really sorry for the inconvenience.I wrongly mentioned name in place of id vice versa.
I am trying to use the beans within the JSP page by sending its input to other class which i used it in Bean.The tags and contents listed are as follows:
<jsp:useBean id="register1" class="/rms/reigister">
<jsp:setProperty name="register1" property="*"/>
</jsp:useBean>
On executing it i get the error as the class attribute /rms/register is invalid.
<jsp:useBean name="register1" class="org.apache.catalina.rms.reigister">
<jsp:setProperty id="register1" property="*"/>
</jsp:useBean>
On executing it i get the error as the class attribute "org.apache.Catalina.rms.register" is invalid.
Thanks in advance

Hi,
I am really sorry for the inconvenience.I wrongly mentioned name in place od id vice versa.
I am trying to use the beans within the JSP page by sending its input to other class which i used it in Bean.The tags and contents listed are as follows:
<jsp:useBean id="register1" class="/rms/reigister">
<jsp:setProperty name="register1" property="*"/>
</jsp:useBean>
On executing it i get the error as the class attribute /rms/register is invalid.
<jsp:useBean name="register1" class="org.apache.catalina.rms.reigister">
<jsp:setProperty id="register1" property="*"/>
</jsp:useBean>
On executing it i get the error as the class attribute "org.apache.Catalina.rms.register" is invalid.
Thanks in advance

Similar Messages

  • " ')' expected " Error when compile jsp that use useBean tag

    I'm using JDeveloper 10.1.3 and I have a page with a next jsp tag
    <jsp:useBean id="objectid" type="package.MyClass" scope="application"/>
    When I compile this JSP page, I got the error:
    ')' expected
    If the application is deployed in the J2EE container like Tomcat or OC4J, the page works fine.
    Is this a JDeveloper bug?? What Can I do?

    The JSP page works fine in OC4J 10.1.2, but in the OC4J 10.1.3 it throws the same error.
    The soruce code that the container generates is this:
    if ((objectid= (package.MyClass) pageContext.getAttribute( "objectid", PageContext.APPLICATION_SCOPE)) == null) {
    throw new InstantiationException("No se ha encontrado el bean "objectid" en el ámbito "application"");
    The bug consist in the generation of the servlet source code. The double quotation is the problem, for that, the compiler generates the error ')' expected...

  • File Not found error when calling Form Post Method to a JSP from JSP Portlet

    I have built a set of JSP forms using post method to call other JSPs. Normally, the code looks like
    <form name="MyForm" action="MyJsp.jsp" method="post">
    I migrated the calling form containing this code to a portlet, but not the MyJsp.jsp. When I submit the form, I get a file not found in Jserv.log
    Exception:javax.servlet.ServletException: java.io.FileNotFoundException: D:\servlet\RegisterCompany.jsp (The system cannot find the file specified)
    [14/06/2001 13:59:59:679 PDT] JspServlet: unable to dispatch to requested page: Exception:javax.servlet.ServletException: java.io.FileNotFoundException: d:\oracle\isuites\apache\apache\MyJsp.jsp (The system cannot find the file specified)
    I notice that launching the calling jsp from a portlet, my opriginal context that uses ../Apache/Apache/htdocs is not being searched for the JSp. Why is this? Moreover, I try to set up an Alias in httpd.conf file to the this director and use it with the jsp in the action tag, but still get an error that my jsp servlets/Myjsp can't be found. Why is it insiting on looking at servlets context instead of htdocs.
    I have none of these issues outside of Portal30 using IAS.
    regard

    Initially, I couldn't do this unless I moved tghe jsp's up to the root directory of IAS, i.e ../Apache/Apache. Nomrally, htdocs is my doc directory for IAS. I could not do http:\\myUrl\htdocs\myJsp. If I tgried this, I got an error in Apache error logg that said can't find file ..\htdocs\htdocs\MyJsp.jsp.
    If I just tried the the URL http:\\myUrl\MyJsp.jsp with Jsp file in htdocs, I would get an error in the Jserve log that file d:\oracle\isuites\apache\apache\MyJsp.jsp could not be found. Once I moved the file MyJsp to Apache/Apache directory, it could be found using http:\\myUrl\MyJsp.jsp. Later, I delted these files and kept the ones in htdocs and they continued to work.
    I'm confused why launching pages through portal isn't consistant with Apache Standards. Where is the documentation that tells me how to configure context and aliases for pages launched from portal pages?
    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Sue Vickers ([email protected]):
    David,
    Passing information using Portal is different than just using Apache/Jserv. Does it work in portal if you use the absolute path?
    <form name="MyForm" action="http://host.domain/MyJSP.jsp" method="post">
    Portal will not be on the same relative path as your Apache, so you may need to adjust your action somehow.
    Thanks,
    Sue<HR></BLOCKQUOTE>
    null

  • UTF-8: JSP to JSP: okay, JSP to servlet to JSP: fail

    Hello,
    Yes, another guy having problems with UTF-8. I have searched this forum a lot for day, but cannot find a solution that works for me... here it is:
    Requests from JSP to JSP work with UTF-8, but only after adding an old-style <% request.setCharacterEncoding("UTF-8"); %> scripting element. Of course, the page has content type text/html with UTF-8 set.
    Thus, the result JSP correctly shows UTF-8, e.g. umlauts work then etc.
    However, as soon as a servlet is involved, i get data garbage that has nothing to do with wrong fonts etc., per character i get two bytes for special chars.
    I tried to set System.setProperty("file.encoding", "UTF-8"), but that does not work also.
    The strange thing is that this works on my home Debian GNU/Linux system but not at work on WinNT.
    Any ideas?
    Here the setup:
    J2SE SDK 1.4.1_02
    Tomcat 4.1.24
    Windows NT 4.0 German
    IE 5.0 + Mozilla Firebird 0.7
    FYI: the servlet is an inherited Struts class.
    Thank you, Timo

    Hello MamtzGroove!
    You are my hero! I tried all that getBytes() stuff and formatting the sources to UTF-8 etc. and nothing worked. Only when insterting your two statements as is into my servlet, the in works.
    The funny thing is that i had used both statements before, but one in the JSP and one in the servlet and vice versa.
    THANKS! THANKS! THANKS! Can i give you duke dollars without having created this question with this option?!?!
    Greetings + Thanks, Timo
    P.S. but why did this work in GNU/Linux? Does it have to do with other System settings????? An idea?

  • Jsp-descriptor jsp-param jspCheckSeconds weblogic.xml?

    For some reason I can't get weblogic to recompile my jsp's when I change
              them. I am using Weblogic 6sp1 on NT4. I place my weblogic.xml in the
              d:\weblogic6.0sp1\wlserver6.0sp1\config\mydomain\applications\cam\Web-inf
              directory.
              When I change one of the jsps I copy it into the
              d:\weblogic6.0sp1\wlserver6.0sp1\config\mydomain\applications\cam directory
              and expect weblgoic to notice it changed. I use ant to copy the jsp's and I
              confirmed that it is actually copying correctly.
              The jsp's use custom tags, but I tried a simple jsp, not using custom tags,
              that doesn't get recompiled either. What could I be doing wrong? Has
              anybody else run into this problem? Restarting weblogic on every change to
              a jsp takes way too long.
              please help.
              -Scot
              <-------here is my weblogic.xml--------------------------->
              <?xml version="1.0" encoding="ISO-8859-1"?>
              <!DOCTYPE weblogic-web-app
              PUBLIC "-//BEASystems, Inc.//DTD Web Application 6.0//EN"
              "http://www.bea.com/servers/wls600/dtd/weblogic-web-jar.dtd">
              <weblogic-web-app>
              <description>
              CAM - Customer Account Management
              </description>
              <session-descriptor>
              <session-param>
              <param-name>
              TimeoutSecs
              </param-name>
              <param-value>
              900
              </param-value>
              </session-param>
              <session-param>
              <param-name>
              URLRewritingEnabled
              </param-name>
              <param-value>
              false
              </param-value>
              </session-param>
              </session-descriptor>
              <jsp-descriptor>
              <jsp-param>
              <param-name>
              pageCheckSeconds
              </param-name>
              <param-value>
              1
              </param-value>
              </jsp-param>
              <jsp-param>
              <param-name>
              verbose
              </param-name>
              <param-value>
              true
              </param-value>
              </jsp-param>
              <jsp-param>
              <param-name>
              keepgenerated
              </param-name>
              <param-value>
              true
              </param-value>
              </jsp-param>
              </jsp-descriptor>
              </weblogic-web-app>
              

    This is correct. I started my web-app under a new directory which was not
              the default web-app originally and was not able to refresh the jsp's upon a
              change to the jsp. Next I tried it as the default web-app and I was able to
              refresh the jsp's as described in the weblogic.xml. Thank you for your
              help.
              Is this a known bug? Or should you not be able to use the weblogic.xml
              properites in a web application that is not the default application?
              "cheenle" <[email protected]> wrote in message
              news:[email protected]...
              >
              > Are you start a new server for you own application?
              > I met the same problem, but I found it only appear under a new server
              >
              > "Scot Hale" <[email protected]> wrote:
              > >For some reason I can't get weblogic to recompile my jsp's when I change
              > >them. I am using Weblogic 6sp1 on NT4. I place my weblogic.xml in the
              > >d:\weblogic6.0sp1\wlserver6.0sp1\config\mydomain\applications\cam\Web-inf
              > >directory.
              > >
              > >When I change one of the jsps I copy it into the
              > >d:\weblogic6.0sp1\wlserver6.0sp1\config\mydomain\applications\cam
              directory
              > >and expect weblgoic to notice it changed. I use ant to copy the jsp's
              > >and I
              > >confirmed that it is actually copying correctly.
              > >
              > >The jsp's use custom tags, but I tried a simple jsp, not using custom
              > >tags,
              > >that doesn't get recompiled either. What could I be doing wrong? Has
              > >anybody else run into this problem? Restarting weblogic on every change
              > >to
              > >a jsp takes way too long.
              > >
              > >please help.
              > >
              > >-Scot
              > >
              > >
              > ><-------here is my weblogic.xml--------------------------->
              > >
              > ><?xml version="1.0" encoding="ISO-8859-1"?>
              > >
              > ><!DOCTYPE weblogic-web-app
              > > PUBLIC "-//BEASystems, Inc.//DTD Web Application 6.0//EN"
              > > "http://www.bea.com/servers/wls600/dtd/weblogic-web-jar.dtd">
              > >
              > ><weblogic-web-app>
              > > <description>
              > > CAM - Customer Account Management
              > > </description>
              > >
              > > <session-descriptor>
              > > <session-param>
              > > <param-name>
              > > TimeoutSecs
              > > </param-name>
              > > <param-value>
              > > 900
              > > </param-value>
              > > </session-param>
              > > <session-param>
              > > <param-name>
              > > URLRewritingEnabled
              > > </param-name>
              > > <param-value>
              > > false
              > > </param-value>
              > > </session-param>
              > > </session-descriptor>
              > >
              > > <jsp-descriptor>
              > > <jsp-param>
              > > <param-name>
              > > pageCheckSeconds
              > > </param-name>
              > > <param-value>
              > > 1
              > > </param-value>
              > > </jsp-param>
              > >
              > > <jsp-param>
              > > <param-name>
              > > verbose
              > > </param-name>
              > > <param-value>
              > > true
              > > </param-value>
              > > </jsp-param>
              > >
              > > <jsp-param>
              > > <param-name>
              > > keepgenerated
              > > </param-name>
              > > <param-value>
              > > true
              > > </param-value>
              > > </jsp-param>
              > > </jsp-descriptor>
              > >
              > ></weblogic-web-app>
              > >
              > >
              >
              

  • Extension data not showing in order.jsp & order_change.jsp

    Hi Experts,
    My requirement is to display the gross weight of the order in Order.jsp,Order_change.jsp. I have implemented the BADI CRM_ISA_BASKET_HEAD and method GETHEAD_GET_DATA to get the gross weight.
    In the BADI I am using CRM_ORDER_READ to get the value gross weight of the order.
    Here is the code to get the extension data in Order.jsp
    <input class="textInput" 
                type="text"
                name="ZGRWT"
                value="<%= JspUtil.encodeHtml(ui.header.getExtensionData("ZGRWT")) %>"/>
    Not sure after doing this both order.jsp & order_change.jsp simply not displying any thing in the page.
    To get the extension data should I write any custom action? Not sure about the issue.

    Hello sirivaram!
    I think you should use custom action.
    You can do it like this:
    1) create custom action class extended BaseAction
    2) in this class you should pass values from ExtensionData to request.
    3) use request attributes instead extensionData() on the jsp page
    4) do not forget register your action before standart ShowBasketAction in config.xml
    My last message Re: Display String Variable on ISA JSP page, that gets value from Z java class. can help you with points 2 and 3.
    For point 4 you have to replace this code in file config.xml:
    <action path="/b2b/showbasket" type="com.sap.isa.isacore.action.order.ShowBasketAction">
    <forward name="showbasket" path="/b2b/order.jsp"/>
    </action>
    with this code:
    <action path="/b2b/showbasket" type="foo.bar.Z_ShowBasketAction">
    <forward name="success" path="/b2b/z_showbasket.do"/>
    </action>
    <action path="/b2b/z_showbasket" type="ru.sng.isa.isacore.action.order.Z_ExtShowBasketAction">
    <forward name="showbasket" path="/b2b/order.jsp"/>
    </action>
    About your issue - I suppose that ui.header can't have to access to ExtensionData or ui.header.getExtensionData("ZGRWT") return null. Anyway you will be able to debug your application and check value of ExtensionData only if you will take your own action.
    Hope this helps.
    Regards, Lev

  • Displaying Applet in JSP Using jsp:plugin tag

    The following code is not working eventhough i downloaded to JRE plug-in .Please help me to work the
    following code in JSP.
    <jsp:plugin code="mani.Clock2.class"
    codebase="/classes/" width=300 height=300
    jreversion="1.3"
    nspluginurl="http://java.sun.com/products/plugin/1.1.3/plugin-install.html"
    iepluginurl="http://java.sun.com/products/plugin/1.3/jinstall-13-win32.cab#Version=1,3,0,0">
    <jsp:fallback>
    <font color=#FF0000 size=10>Sorry Error While Loading Applet </font>
    </jsp:fallback>
    </jsp:plugin>

    why don't ypu just use the <applet> tag?

  • Use classes in JSP without jsp:useBean

    hi
    i want to instantiate my own classes within a jsp.
    the classes are in web-inf/classes/chat/
    there is one main class which is used all over the app, so i use it with the jsp:useBean and scope on application.
    The messages are saved in objects of the class Message. now i want to use this class in my JSP without useBean.
    Is this possible without extra setting the classpath?!
    I get the error because the interpreter searchs in a package from tomcat itself..
    Thanks a lot and rgds
    Ruven

    I think you can use any class in your jsp file without the <jsp:useBean>, this implies that you have to declare your class in the ordinary way i.e
    <% MyClass c = new MyClass() ;
    //other code
    %>
    the important thing is to use the page directive's import attribute i.e include this line in your jsp page
    <%@ page import="mypackage.inner.MyClass" %> the web containers when sees this line will assume that you have the following directory structure in your web application ( /mywebapps/web-inf/classes/mypackage.inner/* )
    I hope this helps
    Regards

  • JSPG0227E: Exception caught while translating /index.jsp:  /index.jsp(12,2)

    While i am creating label in JSF i am getting the following error.
    JSPG0227E: Exception caught while translating /index.jsp: /index.jsp(12,2) --> JSPG0006E: Custom Tag is missing required attribute for
    Please help me.
    Thanks in Advance.

    Add the for attribute to the custom tag.

  • Which Web Client Framework? BC4J-JSP, UIX-JSP, UIX-XML, etc

    Trying to determine which, if any of the JDeveloper frameworks, to use for do web browser (HTML) clients.
    What are the pros/cons of BC4J-JSP, UIX-JSP, UIX-XML, etc?
    What are some common things you might rule out using one or more of the frameworks?
    I plan to be using BC4J, updating, inserting data (currently MS-SQL) and the apps will run on WebLogic 7 or Caucho Resin (webapps no EJB) in a cluster. I would like to be as RAD as possible and still be able to do what I need to do. One main concern is being able to add custom HTML/JavaScript for things like client side validation. I didn't see a way to do this when doing BC4J-JSP. Is that right?
    If I define any validation in the BC4J, will UIX utilized any of this to define a JavaScript validator or must it be redudantly defined?
    One other concern is what the framework requires in terms of architecture, like do I have to have sticky sessions in my web cluster or can it work fine stateless or stateful?
    For UIX-XML, how is this architected for performance? Specifically, is the XML effectively compiled and converted into something more efficient and performant or does it do XML parsing all the time? Is there any significant performance differences between the frameworks?
    Is there any significant difference in dealing with security? Anything in the framework to make it easier to handle certain users being able to see/edit different set of data?
    I have things like some groups can edit only certain entities (product info but not pricing), others only certain types of products (possibly subclass entities) and others situations where what fields than can edit varies. Obviously I can handle this programmatically, but I was wondering what the frameworks had to offer, especially in terms of having different views of the same data.
    Steve

    ...I am little confused then about how BC4J works and what is meant by "session" here.
    When you talk about appmodules in the plural, does this mean that there are potentially multiple instances of the same data on a single server or there is a common datastore with pending data and client specific stuff varying?
    The common datastore is the database. Each client (momentarily, during the span of their request) uses an instance of an application module from the pool. The pool can grow and shrink with load on your system and all of the various tuning parameters. Our doc on the AM Pool covers all the parameter settings and their users.
    What kind of "session" is this?
    It is an abstract notion of a session for a user. The implementation used for Web clients uses the HTTP Session Key as the session key. However, we have other session implementations (and you can provide your own to do custom stuff for more sophisticated needs). We don't store anything else in the HTTP Session to the best of my knowledge. This way in a cluster, the web container doesn't have to waste time propagating all of your serialized HTTP Session state among cluster members. This session key also include an id for the application module and together those provide the key to store your pending state in the database for the "Stateful == Managed State" feature.
    I assume that if I have a cluster which doesn't use session-to-same-server-affinity but uses JDBC for http-session persistance or distributed in-memory http-sessions then I cannot use stateful BC4J even though I can use http-sessions.
    You can use BC4J in this way because the browser will send a cookie that contains the key to your database-stored pending state. In this way, we work great in a server farm for failover and/or scalability reasons.
    Even if I use stateless BC4J, are there issues with round-robin'ng all requests to different servers in a cluster?
    As I said, both our Stateless and Stateful features are designed to be used in Server farms, no problem.
    BTW I wouldn't necessarily say you picked the wrongs terms for the modes, but I know what you mean. There's problems with these terms. I am trying to explain to my mgrs/engineers that there is some state in stateless transactions - that simply making everything "stateless" doesn't mean don't lose anything in a disastrous failure. I am arguing to get support for sessions in our cluster, that the performance gain and simplified development is worth it as long as you put intelligent limits on what you store in the session. Right now, they are insisting on randomly sending requests into two entirely different data centers, with two different clusters.
    Amen. I have seen too many developers make the mistake of trying to be totally stateless, only to completely complicate their development environment with having to peristent partially-completed transaction data to the database. I've seen this done with sets of "Shadow" tables (yuck!) or using hand-written techniques similar to what BC4J provides a robust implementation of in the box.
    We've tuned our "Stateless With Affinity for Server Farms" model over several releases of carefully studying the performance of the Web apps built by our internal Oracle Applications teams using BC4J (over 20 of them now, and growing!) so compared with a hand-written strategy for your web-tier state management, using BC4J's implementation will be much more productive for you.
    We're tuning and tweaking and enhancing it even more for the 9.0.3 release as new needs are highlighted with continued use by our customers (both Oracle internal and external).

  • How to deploy a JSP with jsp:plugin with applet type?

    Hi,
    I am a new comer for JSP and when to try to a simple JSP with plugin for applet. Following is part of my JSP script:
    <jsp:plugin type="applet" code="DigitalClock" align="center" height="25" width="300"
    >
         <jsp:params>
              <jsp:param name="language" value="<%=request.getLocale().getLanguage()%>" />
              <jsp:param name="country" value="<%=request.getLocale().getCountry()%>" />
              <jsp:param name="bgcolor" value="FFFFFF" />
              <jsp:param name="fgcolor" value="CC0066" />
         </jsp:params>
              <jsp:fallback>
              <p>Unable to start plugin.</p>
         </jsp:fallback>
    </jsp:plugin>
    ===========
    And Java plugin tell me that can't find DigitalClock class. I want to ask how to deply this JSP using deploytool.
    Thanks,
    Wise

    Hi
    It should be in such a way,
    The Jsp:param is similar to PARAM used in Applet.
    <jsp:plugin type="applet"
    code="MyApplet.class"
    width="475" height="350"
    <jsp:params>
    <jsp:param name = "PARAM1" value="VALUE1" />
    </jsp:params>
    </jsp:plugin>
    jsp:fallback Element
    It provides alternate text to browsers that do not Support OBJECT or EMBED. You can use this element in the same way as you provide alternate text in your applet.
    <jsp:fallback>
    <b> Error: This example requires java </b>
    </jsp:fallback>
    </jsp:plugin>
    I hope this will help you.
    Thanks
    Bakrudeen
    Technical Support Engineer
    Sun MicroSystems Inc, India

  • New to Jsp. Jsp and java bean not running

    hi
    i have created a simple jsp file and using a java bean. but it is showing errors. my file directory structure in tomcat4.1 is:
    aptechsamples:
    index.jsp
    WEB-INF/classes:
    myPackage:
    Counter.class
    i have no web.xml file i dont know how to use it or not. i need it or not.
    the index.jsp file:<html>
    <head><title> A Simple JSP Bean </title></head>
    <body>
    <%@ page language ="java" %>
    <%@ page import ="mypackage.Counter" %>
    <jsp:useBean id="id_counter" scope="session" class ="Counter"/>
    <jsp:setProperty name="id_counter" property="count" param="count" />
    <jsp:getProperty name="id_counter" property="count" />
    </body>
    </html>the Counter.java file is: package mypackage;
    public class Counter{
         String msg;
         public Counter(){
              msg = "Hello World";
         public String getCount(){
              return msg;          
         public void setCount(String c){
              msg = c;
    }please help me and tellme what the hell is wrong with it or me. im getting an error:
    exception
    org.apache.jasper.JasperException: Cannot create bean of class Counter

    Java is already telling you what is wrong: it cannot create an instance of your Counter class. The reason being: it can't find it.
    What do you mean by "myPackage"? Before you can use any class in your JSP's or servlets, they MUST be stored in a package. If you don't know what that is, I highly suggest you lookup "java package" and "java classpath" using google.
    Let's say your Counter class is in a package mypackage (so it starts with the line package mypackage;). Then you have to store the .class file as:
    WEB-INF/classes/mypackage/Counter.class
    If done correctly, the error message should disappear.

  • Typical login.jsp, middle_page.jsp and logout.jsp

    Hi all,
    I have been tring to build a login system in JSP.
    The problem is every time the session expires I am
    not able to login again immediately and on few
    ocassions lots of sessions are opened automatically
    which prevents re-loging.
    I dont even want to discuss what I did in fear of
    confusing you.
    So somebody please send me excerpts from a typical
    1.)login.jsp
    2.) someMiddlePage.jsp
    3.) logout.jsp
    That really works
    I think I am sure about the login and middlepages i.e
    -->creating a login.java bean that creates a session and
    -->adding userdata into session.
    --> and declaring <jsp:usebean id=login class=login scope =session/>
    in the middle page and check if the session has valid userid
    before serving...
    --> I am not sure about the rest..
    I think answering this question with a "working code"
    can prevent hundreds of other questions that can follow..
    Thanks a lot in advance..

    See: http://www.open-group.biz/xmlportal/Portal?xpc=1$@5$@1$@3
    The example is embedded in a portal but the source code is visible on-line.
    Good luck!

  • BUG JSP editor jsp:attribute action

    Hello, there's a bug in JDeveloper.
    1. Create tag file
    <%@ tag pageEncoding="UTF-8"%>
    <%@ attribute name="x" fragment="true" required="true" %>
    2. Create JSP file
    <%@ page contentType="text/html;charset=UTF-8"%>
    <%@ taglib tagdir="/WEB-INF/tags/" prefix="tags"%>
    <tags:tagFile1>
    <jsp:attribute name="x">
    Hello
    </jsp:attribute>
    </tags:tagFile1>
    JDeveloper underlines the tag in red and says "Required attribute x is missing..." OC4J runtime behaviour is normal (if we ignore other issues with tag files). I am using JDeveloper 10.1.3.1.

    Hi,
    Put this code in the editor and see it will show you the preview
    =========================================
    <%@ taglib uri="tagLib" prefix="hbj" %>
    <html>
    <body>
    Hello
    </body>
    </html>
    ============================================
    This will not show you a preview
    ===========================================
    <%@ taglib uri="tagLib" prefix="hbj" %>
    <jsp:useBean id="myBean" scope="application" class="com.cts.bean.User" />
    <hbj:content
         id="myContext">
    <hbj:page title="Kirupanand">
       <hbj:form id="myFormId" >
      <hbj:inputField type="String"  id="Getuser"
        size="30"  value="" maxlength="8"
        disabled="false">
       </hbj:inputField>
    <hbj:inputField  type="String"
    id="Displayuser"  size="30"
    value="<%=myBean.getUser()%>"
    maxlength="8"      disabled="false">
    </hbj:inputField>
    <hbj:button  id="Store"  text="Save"  width="125px"
    tooltip="Save User Name"  onClick="clientSave"
    disabled="false" design="STANDARD" />     
      </hbj:form>
    </hbj:page>
      </hbj:content>
    <html>
    <body>
    Hello
    </body>
    </html>
    ===================================================
    what does this mean? If you use HTMLB tags then you cannot see a preview. Not because of " <%@ taglib uri="tagLib" prefix="hbj" %> " this statement is used to tell to the program which executes the jsp that use this TagLib to understand what the component starting with hbj should do.

  • Parameter passing from jsp to jsp

    i have a jsp(mother page) there is a link when i click from my mother page a pop-up window appear now what i want is to get the value from my pop-up window (textarea, inputs, etc.) to my mother page.
    thanx a lot

    mother page(calendar.jsp)
    <%@page contentType="text/html"%>
    <%@page pageEncoding="UTF-8"%>
    <%@page session="true" import="java.util.*" %>
    <%@page import="java.io.*"%>
    <style type="text/css">
        body{
        font-family: tahoma;
        font-size: 12pt;
        a {text-decoration: none}
        a:hover { font-family: Tahoma; font-size: 12pt; color:#ff0000; text-decoration: none }
    </style>
    <%
        // Global Vars
        int action = 0;  // incoming request for moving calendar up(1) down(0) for month
        int currYear = 0; // if it is not retrieved from incoming URL (month=) then it is set to current year
        int currMonth = 0; // same as year
        String boxSize = "50";  // how big to make the box for the calendar
        //build 2 calendars
        Calendar c = Calendar.getInstance();
        Calendar cal = Calendar.getInstance();
        if (request.getParameter("action") == null) // Check to see if we should set the year and month to the current
            currMonth = c.get(c.MONTH);
            currYear = c.get(c.YEAR);
            cal.set(currYear, currMonth,1);
        else {
            if (!(request.getParameter("action") == null)) // Hove the calendar up or down in this if block
                currMonth = Integer.parseInt(request.getParameter("month"));
                currYear = Integer.parseInt(request.getParameter("year"));
                if (Integer.parseInt( request.getParameter("action")) == 1 ) {
                    cal.set(currYear, currMonth, 1);
                    cal.add(cal.MONTH, 1);
                    currMonth = cal.get(cal.MONTH);
                    currYear = cal.get(cal.YEAR);
                } else {
                    cal.set(currYear, currMonth ,1);
                    cal.add(cal.MONTH, -1);
                    currMonth = cal.get(cal.MONTH);
                    currYear = cal.get(cal.YEAR);
    %>
        <%!
            public boolean isDate(int m, int d, int y) // This method is used to check for a VALID date
                m -= 1;
                Calendar c = Calendar.getInstance();
                c.setLenient(false);
                try {
                    c.set(y,m,d);
                    Date dt = c.getTime();
                } catch (IllegalArgumentException e) {
                    return false;
                return true;
        %>
                <%!
                    public String getDateName(int monthNumber) // This method is used to quickly return the proper name of a month
                        String strReturn = "";
                        switch (monthNumber) {
                            case 0:
                                strReturn = "January";
                                break;
                            case 1:
                                strReturn = "February";
                                break;
                            case 2:
                                strReturn = "March";
                                break;
                            case 3:
                                strReturn = "April";
                                break;
                            case 4:
                                strReturn = "May";
                                break;
                            case 5:
                                strReturn = "June";
                                break;
                            case 6:
                                strReturn = "July";
                                break;
                            case 7:
                                strReturn = "August";
                                break;
                            case 8:
                                strReturn = "September";
                                break;
                            case 9:
                                strReturn = "October";
                                break;
                            case 10:
                                strReturn = "November";
                                break;
                            case 11:
                                strReturn = "December";
                                break;
                        return strReturn;
                %>
                <script>
                    function doLoad()
                    setTimeout( "refresh()", 2*1000 );
                </script>
                        <html>
                            <form name="upform" method="post">
                                <body bgcolor='white'>
                                    <table border="0" width="520" bordercolorlight="#C0C0C0" bordercolordark="#808080" style="border-collapse: collapse" bordercolor="#111111">
                                        <td>                   
                                            <table border='1' height="20" width='520' celpadding='3' cellspacing='0'>
                                                <tr>
                                                    <td width='120' align='center' valign='middle' height="40"><a href="calendar.jsp?month=<%=currMonth%>&year=<%=currYear%>&action=0"><font size="2"><< Previous Month</font></a></td>
                                                    <td width='280' align='center' valign='middle' height="40" style="font-family: tahoma; font-size: 14pt; color:#800000 "><b><%=getDateName (cal.get(cal.MONTH)) + " " + cal.get(cal.YEAR)%></b></td>
                                                    <td width='120' align='center' valign='middle' height="40"><a href="calendar.jsp?month=<%=currMonth%>&year=<%=currYear%>&action=1"><font size="2">Next Month >></font></a></td>
                                                </tr>
                                            </table>
                                            <table border="0" width="520" bordercolorlight="#C0C0C0" bordercolordark="#808080" style="border-collapse: collapse" bordercolor="#111111">
                                                <td width="100%">
                                                    <table border="2" width="520" bordercolorlight="#C0C0C0" bordercolordark="#000000" style="border-collapse: collapse" bordercolor="#000000"  bgcolor="#DFDCD8">
                                                        <tr style="background-color: #B22222">
                                                            <td width="<%=boxSize%>" align="center" nowrap bordercolor="#666666">
                                                            <font color="#FFFFFF"><b>Sun</b></font></td>
                                                            <td width="<%=boxSize%>" align="center" nowrap bordercolor="#666666">
                                                            <font color="#FFFFFF"><b>Mon</b></font></td>
                                                            <td width="<%=boxSize%>" align="center" nowrap bordercolor="#666666">
                                                            <font color="#FFFFFF"><b>Tue</b></font></td>
                                                            <td width="<%=boxSize%>" align="center" nowrap bordercolor="#666666">
                                                            <font color="#FFFFFF"><b>Wed</b></font></td>
                                                            <td width="<%=boxSize%>" align="center" nowrap bordercolor="#666666">
                                                            <font color="#FFFFFF"><b>Thu</b></font></td>
                                                            <td width="<%=boxSize%>" align="center" nowrap bordercolor="#666666">
                                                            <font color="#FFFFFF"><b>Fri</b></font></td>
                                                            <td width="<%=boxSize%>" align="center" nowrap bordercolor="#666666">
                                                            <font color="#FFFFFF"><b>Sat</b></font></td>
                                                        </tr>
                                                        <%
                                                            //'Calendar loop
                                                            int currDay;
                                                            String todayColor;
                                                            int count = 1;
                                                            int dispDay = 1;
                                                            for (int w = 1; w < 7; w++) {
                                                        %>
                                                        <tr>
                                                            <%
                                                                for (int d = 1; d < 8; d++) {
                                                                    if (! (count >= cal.get(c.DAY_OF_WEEK))) {
                                                            %>
                                                            <td width="<%=boxSize%>" height="<%=boxSize%>" valign="top" align="left"> </td>
                                                            <%
                                                                count += 1;
                                                                } else {
                                                                    if (isDate( currMonth + 1, dispDay, currYear) ) // use the isDate method
                                                                        if ( dispDay == c.get(c.DAY_OF_MONTH) && c.get(c.MONTH) == cal.get(cal.MONTH) && c.get(c.YEAR) == cal.get(cal.YEAR)) // Here we check to see if the current day is today
                                                                            todayColor = "#A52A2A";
                                                                        } else {
                                                                            todayColor = "#ffffff";
                                                            %>
                                                            <td bgcolor ="<%=todayColor%>" width="<%=boxSize%>" align="left" height="<%=boxSize%>" valign="top"><%=dispDay%><br>
                                                            </td>
                                                            <%
                                                                count += 1;
                                                                dispDay += 1;
                                                                        } else {
                                                            %>
                                                            <td width="<%=boxSize%>" align="left" height="<%=boxSize%>" valign="top"> </td>
                                                            <%
                                                            %>
                                                        </tr>
                                                        <%
                                                        %>
                                                    </table>
                                                </td>
                                            </table>
                                        </td>
                                    </table>
                                    <input type="text" name="selMonth" value="">
                                    <input type="text" name="selDay" value="">
                                    <input type="text" name="selYear" value="">
                                    <input type="text" name="txtDesc" value="">
                                    <%
                                        String month=request.getParameter("selMonth");
                                        String day=request.getParameter("selDay");
                                        String year=request.getParameter("selYear");
                                        String desc=request.getParameter("txtDesc");
                                        out.println(month);
                                        out.println(day);
                                        out.println(year);
                                        out.println(desc);
                                    %>
                                    <br>
                                    <a href="addevents.jsp" target="popup" onClick="wopen('addevents.jsp', 'popup', 390, 130); return false;">  ADD EVENTS</a>
                                </body>
                            </form>
                        </html>
    <script>
        function wopen(url, name, w, h)
        w += 32;
        h += 96;
        var win = window.open(url,
        name,
        'width=' + w + ', height=' + h + ', ' +
        'location=no, menubar=no, ' +
        'status=no, toolbar=no, scrollbars=no, resizable=no');
        win.resizeTo(w, h);
        win.focus();
    </script> popupwindow(addevents.jsp)
    <%@page contentType="text/html"%>
    <%@page pageEncoding="UTF-8"%>  <%@ page language="java" import="javazoom.upload.*,java.util.*" %>
        <%@ page errorPage="ExceptionHandler.jsp" %>
        <jsp:useBean id="upBean" scope="page" class="javazoom.upload.UploadBean" >
            <jsp:setProperty name="upBean" property="folderstore" value="C:\ffwApplication\uploadbean\web\uploads"/>
            <jsp:setProperty name="upBean" property="overwrite" value="true" />
        </jsp:useBean>
    <style type="text/css">
        body {color:#ff0000 ;
        margin-left: 0px;
        margin-right: 0px;
        margin-top: 0px;
        margin-bottom: 0px;
        td{font-family: Tahoma;
        font-size: 9pt;
        color: #B22222;
        h4{font-family: Arial, Helvetica, sans-serif;
        font-size: 12pt;
        color: #800000;
        a {text-decoration: none}
        a:hover { font-family: Tahoma; font-size: 11pt; color:#ff0000; text-decoration: none }
    </style>
    <script type="text/javascript">
        function returninput(){
          var form = document.upform;
          var release = true;
            if (upform.txtDesc.value == "")
               alert('Please input description for reference.');
                release = false;
                if (release)
                  var checkform = window.opener.document.upform;
                  checkform.selMonth.value = form.selMonth.value;
                  checkform.selDay.value = form.selDay.value;
                  checkform.selYear.value = form.selYear.value;
                  checkform.txtDesc.value = form.txtDesc.value;
                  //window.close();
    </script>
    <html>
        <head>
            <title></title>
        </head>
        <body>
            <form method="post" action="addevents.jsp" name="upform" enctype="multipart/form-data" onsubmit="javascript:returninput()">
                <table>
                    <tr>
                        <td align="center" colspan="4"><h4>Add Events<h4></td>
                    </tr>
                    <tr>
                        <td align="right">Select Date</td>
                        <td>
                            <select id="selMonth" name="selMonth">
                                <option value="January">January</option>
                                <option value="February">February</option>
                                <option value="March">March</option>
                                <option value="April">April</option>
                                <option value="May">May</option>
                                <option value="June">June</option>
                                <option value="July">July</option>
                                <option value="August">August</option>
                                <option value="September">September</option>
                                <option value="October">October</option>
                                <option value="November">November</option>
                                <option value="December">December</option>
                            </select> / 
                            <select name="selDay" id="selDay">
                                <option value="1">1</option>
                                <option value="2">2</option>
                                <option value="3">3</option>
                                <option value="4">4</option>
                                <option value="5">5</option>
                                <option value="6">6</option>
                                <option value="7">7</option>
                                <option value="8">8</option>
                                <option value="9">9</option>
                                <option value="10">10</option>
                                <option value="11">11</option>
                                <option value="12">12</option>
                                <option value="13">13</option>
                                <option value="14">14</option>
                                <option value="15">15</option>
                                <option value="16">16</option>
                                <option value="17">17</option>
                                <option value="18">18</option>
                                <option value="19">19</option>
                                <option value="20">20</option>
                                <option value="21">21</option>
                                <option value="22">22</option>
                                <option value="23">23</option>
                                <option value="24">24</option>
                                <option value="25">25</option>
                                <option value="26">26</option>
                                <option value="27">27</option>
                                <option value="28">28</option>
                                <option value="29">29</option>
                                <option value="30">30</option>
                                <option value="31">31</option>
                            </select> /  
                            <select name="selYear" id="selYear">
                                <option value="2000">2000</option>
                                <option value="2001">2001</option>
                                <option value="2002">2002</option>
                                <option value="2003">2003</option>
                                <option value="2004">2004</option>
                                <option value="2005">2005</option>
                                <option value="2006">2006</option>
                                <option value="2007" selected>2007</option>
                                <option value="2008">2008</option>
                                <option value="2009">2009</option>
                                <option value="2010">2010</option>
                                <option value="2011">2011</option>
                                <option value="2012">2012</option>
                                <option value="2013">2013</option>
                                <option value="2014">2014</option>
                                <option value="2015">2015</option>
                                <option value="2016">2016</option>
                                <option value="2017">2017</option>
                                <option value="2018">2018</option>
                                <option value="2019">2019</option>
                                <option value="2020">2020</option>
                                <option value="2021">2021</option>
                                <option value="2022">2022</option>
                                <option value="2023">2023</option>
                                <option value="2024">2024</option>
                                <option value="2025">2025</option>
                            </select> 
                        </td>
                    </tr>
                    <tr>
                        <td align="right">Description</td>
                        <td><textarea name="txtDesc" rows="2" cols="35"></textarea></td>
                    </tr>
                    <tr>
                        <td align="right">File Upload</td><td><input type="file" name="uploadfile" size="35"></td>
                    </tr>
                    <tr>
                        <td align="center" colspan="3">
                            <br>
                            <input type="hidden" name="todo" value="upload">
                           <!--input type="button" name="Submit" value="Upload" onclick="javascript:returninput()"-->
                           <input type="submit" name="Submit" value="Upload">
                            <input type="reset" name="Reset" value="Cancel" onclick="window.close()">
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <%
                                if (MultipartFormDataRequest.isMultipartFormData(request)) {
                                    // Uses MultipartFormDataRequest to parse the HTTP request.
                                    MultipartFormDataRequest mrequest = new MultipartFormDataRequest(request);
                                    String todo = null;
                                    if (mrequest != null) todo = mrequest.getParameter("todo");
                                    if ( (todo != null) && (todo.equalsIgnoreCase("upload")) ) {
                                        Hashtable files = mrequest.getFiles();
                                        if ( (files != null) && (!files.isEmpty()) ) {
                                            UploadFile file = (UploadFile) files.get("uploadfile");
                                            //if (file != null) out.println("<li>Form fields : uploadfile"+"<BR> Uploaded file : "+file.getFileName()+" ("+file.getFileSize()+" bytes)"+"<BR> Content Type : "+file.getContentType());
                                            // Uses the bean now to store specified by jsp:setProperty at the top.
                                            upBean.store(mrequest, "uploadfile");
                                        } else {
                                            out.println("<li>No uploaded files");
                                    /*    if (mrequest != null) {
                                            month=mrequest.getParameter("selMonth");
                                            day= mrequest.getParameter("selDay");
                                            year=mrequest.getParameter("selYear");
                                            desc=mrequest.getParameter("txtDesc");
                                            out.println(month);
                                            out.println(day);
                                            out.println(year);
                                            out.println(desc);
                                    } else out.println("<BR> todo="+todo);
                            %>
                        </td>
                    </tr>
                </table>
            </form>
        </body>
    </html>
                            Project description:
    If user wants to add events he/she click the add events link from my calendar.jsp then a pop-up window appear which is addevents.jsp then select date, description and offcourse he/she can upload file store in a certain directory from that info it will return to my calendar.jsp to parse the date to my calendar and create a link through the description towards my uploaded data in a certain directory
    thanx a lot...

Maybe you are looking for

  • Customer group wise sales report

    can somebody give me a clue as to how to take customer group wise sales report thanks

  • ITunes Audio/Video Not Synched

    Why do movies play great in Quicktime player but the audio and video are out of synch when played in iTunes? Here's how i get around the problem... Watch all movies using Quicktime player. Can't watch rented movies with the Quicktime player, so I use

  • Opatch Issue on Solaris 10

    I am having a bit of an issue using the opatch command; for some reason, it's not returning the desired output. All I keep getting is a "OPatch succeeded" response. I can't even confirm the Java version installed; when I execute the java command, I d

  • Dramatically reduce the amt of space used by OSX

    I have a late 09' Mac Mini that's recently been upgraded from 2GB to 8GB of DDR3 1066Mhz RAM. Plus, it's had it's 2.5" 5400RPM 160GB HDD replaced by a 240GB SSD... With SSD's, it's typically a good idea to have at least 10% of the total capacity allo

  • Explorer.exe Application Error

    Hi. (Sorry if this is in the wrong category.) Just today, I downloaded a Windows update(it said I had like 150+ things to install, so I did) Well, that's where my problem began. Once I did that, I turned my laptop on and right after I type my passwor