% in JSP url

I need to have JSP accept un encoded URL with chars like %. Is there anyway I can do it ?
See the difference between http://www.google.com/search?q=%+in+url (it works) and http://onesearch.sun.com/search/developers/index.jsp?qt=%+in+url (doesn't work)
Anthos

Also this HTTP request got uncoded characters which fails request params in cases of %, # and so on.
1. Save the following as params.jsp
<%@ page contentType="text/html;charset=UTF-8"%>
<HTML>
<HEAD>
<TITLE></TITLE>
</HEAD>
<BODY>
<TABLE BORDER='1'>
<TR><TD>NAME</TD><TD>VALUE</TD></TR>
<%
java.util.Enumeration names = request.getParameterNames();
while(names.hasMoreElements())
String name = (String) names.nextElement();
Object value = request.getParameter(name);
out.println("<TR><TD>" + name + "</TD><TD>" + value + "</TD></TR>");
%>
</TABLE>
</BODY>
</HTML>
2. Invoke as http://localhost.../params.jsp?param1=value1&param2=value2
and http://localhost.../params.jsp?param1=value%1&param2=value2 and see the difference.

Similar Messages

  • Filter does not work with *.jsp URL pattern???

    Hi All,
    I am, by no means, very good at JSF or Java. I have looked at various forum posts on here for ways to implement a security filter to intercept requests to pages that first require one to be logged in, and if not, redirect them to the login page. Yes, I know a lot of you have heard this many times before, and I'm sorry to bring it up again.
    BUT, from the guidance of other posts, I have got a filter that works fine when the url pattern is set to "/faces/*" or "/<anything>/*", however it won't work for "*.jsp" or "*.<anything>"
    My filter is as follows:
    package test.security;
    import javax.faces.context.FacesContext;
    import javax.servlet.Filter;
    import javax.servlet.FilterChain;
    import javax.servlet.FilterConfig;
    import javax.servlet.http.HttpSession;
    import javax.servlet.ServletRequest;
    import javax.servlet.ServletResponse;
    import javax.servlet.ServletException;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;
    public class SecurityFilter implements Filter{
        /** Creates a new instance of SecurityFilter */
        private final static String FILTER_APPLIED = "_security_filter_applied";
        public SecurityFilter() {
        public void init(FilterConfig filterConfig) {
        public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws java.io.IOException, ServletException{
            HttpServletRequest req = (HttpServletRequest)request;
            HttpServletResponse res = (HttpServletResponse)response;
            HttpSession session = req.getSession();
            String requestedPage = req.getPathTranslated();
            String user=null;
            if(request.getAttribute(FILTER_APPLIED) == null) {
                //check if the page requested is the login page or register page
                if((!requestedPage.endsWith("Page1.jsp")) /* This is the login page */
                    //set the FILTER_APPLIED attribute to true
                    request.setAttribute(FILTER_APPLIED, Boolean.TRUE);
                    //Check that the session bean is not null and get the session bean property username.
                    if(((test.SessionBean1)session.getAttribute("SessionBean1"))!=null) {
                        user = ((test.SessionBean1)session.getAttribute("SessionBean1")).getUsername();
                    if((user==null)||(user.equals(""))) {
                       // try {
                     //       FacesContext.getCurrentInstance().getExternalContext().redirect("Page1.jsp");
                      //  } catch (ServletException ex) {
                      //      log("Error Description", ex);
                        res.sendRedirect("../Page1.jsp");
                        return;
            //deliver request to next filter
            chain.doFilter(request, response);
        public void destroy(){
    }My web.xml declaration for the filter is:
    <filter>
      <description>Filter to check whether user is logged in.</description>
      <filter-name>SecurityFilter</filter-name>
      <filter-class>test.security</filter-class>
    </filter>
    <filter-mapping>
      <filter-name>SecurityFilter</filter-name>
      <servlet-name>Faces Servlet</servlet-name>
    </filter-mapping>
    Note: I have also tried this with <url-pattern>*.jsp</url-pattern> for the filter mapping in place of the Faces Servlet
    My web.xml declaration for the url pattern is:
    <servlet-mapping>
      <servlet-name>Faces Servlet</servlet-name>
      <url-pattern>*.jsp</url-pattern>
    </servlet-mapping>Which JSC/NetbeansVWP automatically creates a "JSCreator_index.jsp" which has:
    <?xml version="1.0" encoding="UTF-8"?>
    <jsp:root  version="1.2" xmlns:jsp="http://java.sun.com/JSP/Page">
      <jsp:forward page="Page1.jsp"/>
    </jsp:root>When run, this causes an Error 500 in the browser and a NullPointerException in SecurityFilter.java on the line:
    if((!requestedPage.endsWith("Page1.jsp")) /* This is the login page */I think I'm missing something that would be obvious to anyone who knows better than me. Any ideas?

    Dear Ginger and Boris,
    thanks for the information - the problem seems to ocur in EP7 as well, Boris told me it is fixed in SP15. We are on SP14 now, so there is hope !
    actually the information in the oss note stated above is also true, as we have an Oracle DB. On a similar demo system (only difference is SQL DB) the hyphen search works !
    best regards, thank you !
    Johannes

  • JSP URL encoding

    Hi I've got this link that leads me to print_article.jsp. When I use the link, the encoding fine in the page that I get to. So in print_article.jsp, when I call ${param.title} it displays 'Assurance m�dicale � la carte', as it should.
    If I cut and paste that URL in a new browser, the encoding for ${param.title} is wrong. ${param.title} gives Assurance m&#65533;dicale &#65533; la carte.
    here is the URL in question:
    http://localhost/print_article.jsp?page=/assurance-voyage/trouver-produit/liste-protections/plan-medicaux/assurance-medicale-carte.fr.html&title=Assurance%20m�dicale%20�%20la%20carte&lng=fr
    I tried forcing the encoding using utf-8, windows-1252 and ISO-something and none of those work.
    I encoded the URL ( and only the param.title part ) using java.net.URLEncoder. That didn't work either.
    I tries IE7, firefox, got the same behavior
    What has me baffled is that all works fine, except when I cut and paste the URL in a new browser, new window, the I lost the encoding on the parameter title.
    Any idea?

    Design advice that solves the problem:
    Don't send whole title as url parameter, send only some article id and get all the other article attributes using this id.

  • JSP - URL File I/O BufferedReader

    I need help with the below code. I can grab external code fine, but I am looking for an efficient way to only buffer part of the code (i.e. everything in between <html> and </html>).
    URL url = new URL("http://www.yahoo.com/");
    BufferedReader in = new BufferedReader(new InputStreamReader(url.openStream()));
    String inputLine;
    StringBuffer sb = new StringBuffer();
    while ((inputLine = in.readLine()) != null)
    sb.append(inputLine);
    in.close();
    Do I need to modify the while statement?
    Or do I need to add StringTokenizer and/or trim()?
    something like this example:
    StringTokenizer stBegin = new StringTokenizer(inputLine,"<html>");
    I'm using JSP 1.1/JDK 1.3.1
    Any code samples or forum links are greatly appreciated.
    thanks.

    You cannot only buffer in the <html> part code. What you can do is buffer in the whole code and use indexOf() and subString() to cut the string u need. Something like that:
    while ((inputLine = in.readLine()) != null)
    String htmlCode = null;
    int htmlStart = inpputLine.indexOf("<html>");
    int htmlEnd = inputLine.indexOf("</html>");
    htmlCode = inputLine.substring(htmlStart, htmlEnd);
    }           

  • FacesServlet routing to a different jsp url

    I would like to encode information on which businessobject is currently in use in the URL. To view my Businessobject with with ID=123456 an URL would look like: http://host/faces/123456/view.jsp Still it should call the /view.jsp as should http://host/faces/3434/view.jsp and so on. The part between the /faces/ and the /view.jsp is only for my application use.
    Any hints on how to achive this?
    In the web.xml the facesservlet has a mapping of faces/* which makes it work for those urls, too. But how do I make it forward to /view.jsp. I the moment I believe it is looking for /123456/view.jsp which obviously does not exist.

    Andy,
    I do have an afh:body on my page. I just tried to replace it with a <body> tag, but then the partial page rendering won't work anymore (this caused all tabs of the detail page not to work anymore). I read that either afh:body, af:document or af:panelPartialRoot is needed.
    So I used af:panelPartialRoot instead, but that wouldn't help either.
    Anyway, I still can't navigate to a different page in the disclosure listener of my detail page tabs.
    Is there maybe a way to treat a tab as a normal button, with an action event and an according listener?
    Torsten

  • Workflow autogenerated jsp url

    I have created a simple workflow process using an auto generated jsp and deployed it to a middle tier installation using jdev. What is the url for the jsp? http://hostname:7777/????
    Thanks for your help.
    Sean.

    http://localhost:7777/integration/worklistapp/
    login and there it comes ..

  • Need JSP-URL in controlling servlet

    Hi,
    I have a simple questions which is driving me crazy.
    2 JSP's are using same Servlet which has to process their input.
    Inside this servlet I need to know which jsp is calling the servlet.
    I tried following code :
              System.out.println("req.getRequestURI() = \"" + req.getRequestURI() +"\"");
              System.out.println("req.getClass() = \"" + req.getClass() +"\"");
              System.out.println("req.getPathInfo() = \"" + req.getPathInfo() +"\"");
              System.out.println("req.getPathTranslated() = \"" + req.getPathTranslated() +"\"");
              System.out.println("req.getServletPath() = \"" + req.getServletPath() +"\"");
              System.out.println("HttpUtils.getRequestURL(req)= \"" + HttpUtils.getRequestURL(req) +"\"");
    but none of them are returning the correct name of the calling JSP...
    Here are the results in same sequence:
    req.getRequestURI() = "/servlet/com.clipper.servlets.FQController"
    req.getClass() = "class com.ibm.servlet.engine.webapp.WebAppDispatcherRequest"
    req.getPathInfo() = "null"
    req.getPathTranslated() = "null"
    req.getServletPath(req) = "/servlet/com.clipper.servlets.FQController"
    HttpUtils.getRequestURL()= "http://www.clippersupport.be:2031/servlet/com.clipper.servlets.FQController"
    As you can see, I only retrieve the Servlets info, not the JSP's...
    I need to find :
    /JSP/JSP1.jsp
    How do I do this ???

    I don't think it is possible to find out the details of the calling jsp in another servlet jsp or servlet. The only possibility is in the jsp get requestURL and place this as a request parameter in the request. Then when you call the servlet, the servlet can then extract this request parameter.

  • Quick question about url/jsp mapping

    Could anyone clarify whether the following mapping in the web.xml file is possible?
    I want to access the file webapps\examples\gate\login.jsp by going to the page http://192.168.2.143:8080/work/login.jsp instead of http://192.168.2.143:8080/examples/gate/login.jsp
    Currently I can map it fine to http://192.168.2.143:8080/examples/work/login.jsp,
    which is an existing folder, but when I try and get it above the examples folder, it gives me the 404 error.
        <servlet>
            <servlet-name>Login</servlet-name>
            <jsp-file>/gate/login.jsp</jsp-file>
        </servlet>
        <servlet-mapping>
            <servlet-name>Login</servlet-name>
            <url-pattern>/../work/login.jsp</url-pattern>
        </servlet-mapping>

    Using only work/login.jsp will cause an error, and the tomcat server to crash, if I use the pattern
    <url-pattern>/work/login.jsp</url-pattern>, I just map the URL http://192.168.2.143:8080/examples/work/login.jsp instead of
    http://192.168.2.143:8080/examples/gate/login.jsp
    My entire webaps structure is rather long, and contains code other than my own, so I'd rather not post it, I just need to figure out if it is possible to map the jsp page to a path above the file. (do you think I need to do it in another web.xml?)

  • How can I invoke a JSP using a URL instance from another JSP?

              Hi all.
              I've been developed a J2EE application using Oracle 9iAS.
              Now I'm migrating to WL Server and I have the following problem.
              I was using the following code to read a URL contents from another JSP:
              URL url = config.getServletContext().getResource("/path/to/url/of/textfile.xsl");
              This was working fine in a expanded directory project structure (typical during
              development time) and Oracle 9iAS.
              When I execute this code from my WL packed .ear file I get a URL not found exception.
              Which is the right way to get a resource available from the same context root?
              Thanks in advance for your answers (and sorry for my bad english ;-))
              

    The previous owner of that machine should have wiped it and install the original OS that shipped with the system leaving the system at the point where the new owner takes over and enters all there own information.
    Before you go much further with this machine you should seriously consider backing up any new stuff you have done and wiping it and starting from scratch. If you keep the system like it is you  will be plagued with problems. Even doing OS updates will prove frustrating.
    Right now the best you can do is to move the Aperture that is on the system into the trash, log into the App Store using your ID and buying Aperture. That should work but to be honest I have never had to do it so can;t say for sure.
    You might want to look at this What to do before selling or giving away your Mac from Apple to read what they recommend.
    good luck
    regards

  • Issue in applying SSL selectively to Login JSP Page--Session getting lost.

    Hi,
    I am facing some issues with SSL configuration on my web site running on tomcat 5.5. I am using jdk 1.5 and form based authentication with JAAS framework.
    The SSL configuration is working perfectly when applied to complete web site, but starts giving problem when applied selectively to some JSP pages. At present I am trying to apply SSL just on the login page.
    When the login screen loads up, the URL in the browser has a protocol "*https*", as expected, but it doesn't gets changed to "*http*" once the user has successfully logged in. Why is the automatic change from https to http not ocurring?
    Also I want to know which is the default page, tomcat will direct the logged in user to, once successfully authenticated using form based login; Is there any way to change this default page to some other page. It looks like that tomcat automatically directs to index.html , once the user has been successfully authenticated, but I am not so sure. My index.html page is having 4 frames; the source of these frames are different JSP pages, which are not under SSL.
    My aim is to apply SSL just on login.jsp so that password doesn't travel in clear text. Once the user is authenticated he should see index.html and the address bar's URL should change it's protocol from https to http.
    Please, find below the code in my web.xml
    <security-constraint>
    <web-resource-collection>
    <web-resource-name>CWA Application</web-resource-name>
    <url-pattern>/about.jsp</url-pattern>
    <url-pattern>/admin_listds.jsp</url-pattern>
    <http-method>DELETE</http-method>
    <http-method>GET</http-method>
    <http-method>POST</http-method>
    <http-method>PUT</http-method>
    </web-resource-collection>
    <auth-constraint>
    <role-name>*</role-name>
    </auth-constraint>
    <user-data-constraint>
    <transport-guarantee>NONE</transport-guarantee>
    </user-data-constraint>
    </security-constraint>
    <security-constraint>
    <web-resource-collection>
    <url-pattern>/*login.jsp*</url-pattern>
    <http-method>GET</http-method>
    <http-method>POST</http-method>
    </web-resource-collection>
    <auth-constraint>
    <role-name>*</role-name>
    </auth-constraint>
    <user-data-constraint>
    <transport-guarantee>CONFIDENTIAL</transport-guarantee>
    </user-data-constraint>
    </security-constraint>
    <login-config>
    <auth-method>FORM</auth-method>
    <realm-name>CWA Application</realm-name>
    <form-login-config>
    <form-login-page>/login.jsp</form-login-page>
    <form-error-page>/login.jsp?error=true</form-error-page>
    </form-login-config>
    </login-config>
    <welcome-file-list>
    <welcome-file>login.jsp</welcome-file>
    </welcome-file-list>
    My login. jsp has below code:
    <form name="login" method="POST" action='<%= response.encodeURL(*"j_security_check*") %>' >
    <tr>
    <td width="100%">
    <table width="260" border="0" cellspacing="0" cellpadding="1">
    <tr>
    <td align="left" valign="top" rowspan="4"><img src="images/space.gif" width="15" height="5"></td>
    <td align="right" class="login-user" nowrap ><p>User name: </p></td>
    <td align="left" valign="top"><input maxLength="64" name="j_username" size="20"></td>
    </tr>
    <tr>
    <td align="right" nowrap class="login-user"><p>Password: </p>
    </td>
    <td align="left" valign="top">
    <input maxLength=\"64\" tabindex="2" type="password" name="j_password" size="20">
    </td>
    </tr>
    </form>
    The entries in my server.xml are following:
    <Connector port="8080" maxHttpHeaderSize="8192"
    maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
    enableLookups="false" redirectPort="8443" acceptCount="100"
    connectionTimeout="20000" disableUploadTimeout="true" />
    <Connector port="8443" protocol="HTTP/1.1" SSLEnabled="true"
    maxThreads="150" scheme="https" secure="true"
    keystoreFile="${java.home}\lib\security\cacerts" keystorePass="changeit"
    clientAuth="false" sslProtocol="TLS" />
    I have gone through the http://forums.sun.com/thread.jspa?threadID=197150 and tried implementing it; The filter as explained in the thread does gets called but the session values are still lost.
    Please note I am using javascript to go from secure "https" to "http" once the user has successfully logged in The javascript code is as below:
    top.location.href="http://localhost:8080/qtv/index.html." ;
    If I use response.sendRedirect("http://localhost:8080/qtv/index.html") for going to non-secure mode, the index.html page does not gets loaded properly. (Please note that my index.html is made of *4 frames*, as explained earlier. This is a legacy code and frames can't be removed).
    The reason for index.html not getting loaded properly is that the Address bar URL does NOT change its URL and protocol from https (https://localhost:8443/qtv/index.html ) to "*http*" (http://localhost:8080/qtv/index.html) when esponse.sendRedirect() is used ;this is the default behaviour of response.sendRedirect(). And because the protocol in address bar is https, index.html is not able to load the other JSP's in it's frames because of cross-frame-scripting security issues (The other JSP's to be loaded in frames are are NOT secure as discussed earlier).
    Please let know if any way out.
    Thanks,
    Masaai

    Hi
    try to set the maximum interval between requests
    eg:
    session.setMaxInactiveInterval(6000);
    vis

  • How to remove faces from url

    Hi All,
    Following is my web.xml
    <?xml version = '1.0' encoding = 'windows-1252'?>
    <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
    <web-app>
        <description>Empty web.xml file for Web Application</description>
        <context-param>
            <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
            <param-value>client</param-value>
        </context-param>
        <context-param>
            <param-name>CpxFileName</param-name>
            <param-value>com.gemini.view.DataBindings</param-value>
        </context-param>
        <filter>
            <filter-name>adfBindings</filter-name>
            <filter-class>oracle.adf.model.servlet.ADFBindingFilter</filter-class>
        </filter>
        <filter>
            <filter-name>adfFaces</filter-name>
            <filter-class>oracle.adf.view.faces.webapp.AdfFacesFilter</filter-class>
        </filter>
        <filter-mapping>
            <filter-name>adfBindings</filter-name>
            <url-pattern>*.jsp</url-pattern>
        </filter-mapping>
        <filter-mapping>
            <filter-name>adfBindings</filter-name>
            <url-pattern>*.jspx</url-pattern>
        </filter-mapping>
        <filter-mapping>
            <filter-name>adfFaces</filter-name>
            <url-pattern>*.jsp</url-pattern>
        </filter-mapping>
        <filter-mapping>
            <filter-name>adfFaces</filter-name>
            <url-pattern>*.jspx</url-pattern>
        </filter-mapping>
        <servlet>
            <servlet-name>Faces Servlet</servlet-name>
            <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
            <load-on-startup>1</load-on-startup>
        </servlet>
        <servlet>
            <servlet-name>resources</servlet-name>
            <servlet-class>oracle.adf.view.faces.webapp.ResourceServlet</servlet-class>
        </servlet>
        <servlet>
            <servlet-name>geminiservlet</servlet-name>
            <servlet-class>com.gemini.view.managed.geminiservlet</servlet-class>
        </servlet>
        <servlet>
            <servlet-name>gemini</servlet-name>
            <servlet-class>com.gemini.view.managed.gemini</servlet-class>
        </servlet>
        <servlet-mapping>
            <servlet-name>Faces Servlet</servlet-name>
            <url-pattern>/faces/*</url-pattern>
        </servlet-mapping>
        <servlet-mapping>
            <servlet-name>resources</servlet-name>
            <url-pattern>/adf/*</url-pattern>
        </servlet-mapping>
        <servlet-mapping>
            <servlet-name>geminiservlet</servlet-name>
            <url-pattern>/faces/geminiservlet</url-pattern>
        </servlet-mapping>
        <servlet-mapping>
            <servlet-name>gemini</servlet-name>
            <url-pattern>/gemini</url-pattern>
        </servlet-mapping>
        <session-config>
            <session-timeout>35</session-timeout>
        </session-config>
        <mime-mapping>
            <extension>html</extension>
            <mime-type>text/html</mime-type>
        </mime-mapping>
        <mime-mapping>
            <extension>txt</extension>
            <mime-type>text/plain</mime-type>
        </mime-mapping>
        <welcome-file-list>
            <welcome-file>/login.jsp</welcome-file>
        </welcome-file-list>
    </web-app>I access the site using http://bri-dev2/Gemini/faces/login.jsp
    I want to remove faces from the URL. like http://bri-dev2/Gemini/login.jsp
    How can I achieve this ?
    I used /* in the Faces Servlet URL Pattern. and when I accessed the page using
    http://bri-dev2/Gemini/login.jsp it gave me FacesContext Exception. I am using FacesContext object in login.jsp and several other jsp pages. So /* did not work.
    Any idea ?
    thanks,
    pp

    Sorry, it took long time. bcoz after that, all the components of server were down. I had to restart the server.
    Well, Following is the log:
    07/08/09 18:12:35 Start process
    07/08/09 18:13:04 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:05 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:05 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:05 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:05 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:06 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:06 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:06 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:06 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:06 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:07 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:07 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:07 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:07 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:07 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:07 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:07 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:07 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:07 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:07 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/09 18:13:14 Error initializing site OracleAS Java Web Site: No application named 'BC4J' found in the server
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Short,null)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Short)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Byte,null)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Byte)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Integer,null)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Integer)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Long,null)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Long)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Float,null)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Float)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Double,null)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Double)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ValidatorRule end
    WARNING: [ValidatorRule]{faces-config/validator} Merge(javax.faces.LongRange)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.DateTime,null)
    Aug 9, 2007 6:13:19 PM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Number,null)
    07/08/09 18:13:25 Tutalii: D:\Apps\OraHome_1\j2ee\home\applications\webappjdk14ver80\webappjdk14ver80\WEB-INF\lib\adf-faces-api.jar archive
    07/08/09 18:13:25 Oracle Application Server Containers for J2EE 10g (10.1.2.0.2) initialized
    07/08/10 08:21:29 Error initializing site OracleAS Java Web Site: No application named 'BC4J' found in the server
    07/08/10 08:22:30 Notification ==> Application Deployer for webappjdk14ver80 STARTS [ 2007-08-10T08:22:30.864PDT ]
    07/08/10 08:22:30 Notification ==> Do not undeploy previous deployment
    07/08/10 08:22:30 Notification ==> Copy the archive to D:\Apps\OraHome_1\j2ee\home\applications\webappjdk14ver80.ear
    07/08/10 08:22:30 Copy file C:\WINDOWS\TEMP\dir53654.tmp\webappjdk14ver80.ear to D:\Apps\OraHome_1\j2ee\home\applications\webappjdk14ver80.ear
    07/08/10 08:22:31 Notification ==> Unpack webappjdk14ver80.ear begins...
    07/08/10 08:22:31 Auto-unpacking D:\Apps\OraHome_1\j2ee\home\applications\webappjdk14ver80.ear... done.
    07/08/10 08:22:31 Notification ==> Unpack webappjdk14ver80.ear ends...
    07/08/10 08:22:31 Notification ==> Initialize webappjdk14ver80.ear begins...
    07/08/10 08:22:31 Auto-unpacking D:\Apps\OraHome_1\j2ee\home\applications\webappjdk14ver80\webappjdk14ver80.war... done.
    07/08/10 08:22:32 Copying default deployment descriptor from archive at D:\Apps\OraHome_1\j2ee\home\applications\webappjdk14ver80/META-INF/orion-application.xml
    to deployment directory D:\Apps\OraHome_1\j2ee\home\application-deployments\webappjdk14ver80...
    07/08/10 08:22:32 Notification ==> Initialize webappjdk14ver80.ear ends...
    07/08/10 08:22:32 Notification ==> Initialize webappjdk14ver80 begins...
    07/08/10 08:22:32 Notification ==> Initialize webappjdk14ver80 ends...
    07/08/10 08:22:32 Error initializing data-source 'jdbc/GeminiSQLConnection1CoreDS': DriverManagerDataSource driver 'com.mysql.jdbc.Driver'
    not found
    07/08/10 08:22:32 Notification ==> Application Deployer for webappjdk14ver80 COMPLETES [ 2007-08-10T08:22:32.695PDT ]
    07/08/10 08:22:32 Error initializing site OracleAS Java Web Site: No application named 'BC4J' found in the server
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Short,null)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Short)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Byte,null)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Byte)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Integer,null)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Integer)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Long,null)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Long)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Float,null)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Float)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Double,null)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(null,java.lang.Double)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ValidatorRule end
    WARNING: [ValidatorRule]{faces-config/validator} Merge(javax.faces.LongRange)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.DateTime,null)
    Aug 10, 2007 8:22:36 AM com.sun.faces.config.rules.ConverterRule end
    WARNING: [ConverterRule]{faces-config/converter} Merge(javax.faces.Number,null)
    07/08/10 08:22:39 Tutalii: D:\Apps\OraHome_1\j2ee\home\applications\webappjdk14ver80\webappjdk14ver80\WEB-INF\lib\adf-faces-api.jar archive

  • How can I set time-out while accessing a url using URL object?

    Hi
    I'm trying to get the content of a URL using the following code. How can I set timeout
    (example, 10 secs), if the webserver takes a while to respond.?
    BufferedReader inbuf=null;
    URL url=null;
    try {      
         String urlString="http://host-machine/sms/index.jsp";          
         url = new URL(urlString);
         inbuf = new BufferedReader(new InputStreamReader(url.openStream()));
         String inputLine;
         String LongString="";
    while ( (inputLine=inbuf.readLine()) != null)
              LongString=LongString+inputLine;
              retString=LongString;          
              inbuf.close();
         catch (Exception e) {System.out.println(e)}
    Thanks a lot for your kind help
    Regards
    Kandasamy

    If you're using Java 5, see this thread (reply 10)
    http://forum.java.sun.com/thread.jspa?forumID=31&threadID=576157

  • Getting to next JSP from Servlet

    I am getting a 404 when I try to redirect from my servlet to an error page. The code that I am testing is....
    catch (SQLException es)
    LOG.error("Unexpected error in Login.createUser.Error
    message = " + es);
    session.setAttribute(Constants.MESSAGE, es.getMessage());
    session.setAttribute(Constants.ERROR_TITLE, "Login error: " + Constants.SQL_ERROR);
    resp.sendRedirect(Constants.ERROR_PATH);
    I have a compiled java class called Constants where the ERROR_PATH is defined as
    /** Constant name used in obtaining the path to the error page. */
    public static final String ERROR_PATH = "/Jsp/error.jsp";
    My JSP pages are located at the root...
    myapp
    ....Jsp
    ....WEB-INF
    ........classes
    My web.xml looks like this
    <servlet>
    <servlet-name>errorPage</servlet-name>
    <jsp-file>/Jsp/errorPage.jsp</jsp-file>
    </servlet>
    <servlet-mapping>
    <servlet-name>error</servlet-name>
    <url-pattern>/Jsp/error.jsp</url-pattern>
    </servlet-mapping>
    Can anyone point me in the right direction....Thanks

    I tend to use a utility method called redirectToResource in particular to redirect from any servlet to any JSP :
    /** This method will still work when the server is configured to
    *   listen to  port 80 rather than port 8080 (default in Tomcat)
    public void redirectToResource (HttpServletRequest req,
                                     HttpServletResponse resp,
                                  String resourceName)
                         throws ServletException, IOException
       int serverPort    = req.getServerPort();
       String scheme     = req.getScheme();
       String serverName = req.getServerName();
       StringBuffer urlBuffer = new StringBuffer(40);
       urlBuffer.append(scheme + "://" + serverName);
       urlBuffer.append(":" + serverPort);
       urlBuffer.append(resourceName);
        String location = resp.encodeRedirectURL(urlBuffer.toString());
        resp.sendRedirect(location);
    }

  • How to get JSP to forward a request over SSL?

    I'm new to JSP and servlets, although I've been working with Java for a long time. I'm trying to write a simple user registration and login system to teach myself JSP. I would like to set things up so that the user is able to login securely over https. I'm not sure how to do that, though. There seems to be no place in the relative URLs to indicate that you should be forwarding a request over SSL. I've got sample login page below - would anyone know how to modify it so that it happens securely?
    Also, do I need to install a certificate on my web server?
    index.jsp
    <html>
        <body>
            <h1>Index</h1>
            <a href="login.jsp">Login</a>
        </body>
    </html>login.jsp
    <%@page contentType="text/html" pageEncoding="UTF-8"%>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
       "http://www.w3.org/TR/html4/loose.dtd">
    <html>
        <body>
            <h1>Login</h1>
            <jsp:useBean id="userLogin"
                         class="com.kitfox.webrpg.UserLogin"/>
            <jsp:setProperty name="userLogin"
                             property="*"/>
            <%if (userLogin.isValid()) {%>
            <jsp:useBean id="userId"
                         class="com.kitfox.webrpg.UserIdent"
                         scope="session"/>
            <jsp:setProperty name="userId" property="*"/>
            <jsp:forward page="index.jsp"/>
            <%} else {%>
            <form action="login.jsp" method="post">
                <fieldset>
                    <legend>Enter login information</legend>
                    <label for="login">Login</label>
                    <input type="text" name="login" value="${userLogin.login}"/> <br/>
                    <label for="password">Password</label>
                    <input type="password" name="password"/> <br/>
                    <input type="submit" value="submit">
                </fieldset>
            </form>
            <%}%>
        </body>
    </html>

    <security-constraint>
    <web-resource-collection>
    <web-resource-name>Secure Login</web-resource-name>
    <url-pattern>/login.jsp</url-pattern>
    </web-resource-collection>
    <user-data-constraint>
    <transport-guarantee>CONFIDENTIAL</transport-guarantee>
    </user-data-constraint>
    </security-constraint>
    This code is used basically for different authentication type . Forward to any jsp under any layer works with <jsp:forward> or else try with request.getRequestDispatcher(" url (can be absolute or accurate path)").forward(request,response);
    Edited by: user8483670 on Mar 13, 2011 9:46 PM

  • Problem in Tiles2 intrigation with jsf when we keep jsp in folder location

    I have download “myfaces-example-tiles-1.1.10” from official apache web site. As it is code and I hvae create new one application it is working fine with java 1.5 and tomcat 6 in my eclipse.
    This example keep jsp file page1.jsp in root folder when we move this file in any other folder it geives error.
    When I put the home.jsp file in any folder it is given the error below are details what I have done and what I want and wht is the error.
    Error message which I got:
    An Error Occurred:
    javax.faces.FacesException
    Caused by:
    java.io.IOException - Error including path '/template/template.jsp'. java.lang.NullPointerException: context
    +- Stack Trace
    javax.faces.FacesException
    at org.apache.myfaces.tomahawk.application.jsp.JspTilesTwoViewHandlerImpl.renderTilesView(JspTilesTwoViewHandlerImpl.java:126)
    at org.apache.myfaces.tomahawk.application.jsp.JspTilesTwoViewHandlerImpl.renderView(JspTilesTwoViewHandlerImpl.java:110)
    at org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:41)
    at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:146)
    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:147)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:646)
    at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:436)
    at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:374)
    at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:302)
    at org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:426)
    at org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:255)
    at org.apache.myfaces.tomahawk.application.jsp.JspTilesTwoViewHandlerImpl.renderView(JspTilesTwoViewHandlerImpl.java:92)
    at org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:41)
    at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:146)
    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:147)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    at org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:349)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:849)
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
    at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:454)
    at java.lang.Thread.run(Unknown Source)
    Caused by: org.apache.tiles.TilesException: Error including path '/template/template.jsp'. java.lang.NullPointerException: context
    at org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.java:427)
    at org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.java:370)
    at org.apache.myfaces.tomahawk.application.jsp.JspTilesTwoViewHandlerImpl.renderTilesView(JspTilesTwoViewHandlerImpl.java:124)
    ... 31 more
    Caused by: java.io.IOException: Error including path '/template/template.jsp'. java.lang.NullPointerException: context
    at org.apache.tiles.servlet.context.ServletTilesRequestContext.forward(ServletTilesRequestContext.java:201)
    at org.apache.tiles.servlet.context.ServletTilesRequestContext.dispatch(ServletTilesRequestContext.java:185)
    at org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.java:419)
    ... 33 more
    This is the project struture:::----
    /MCMS/WebContent
    /MCMS/WebContent/common
    /MCMS/WebContent/common/footer.jsp
    /MCMS/WebContent/common/header.jsp
    /MCMS/WebContent/common/menu.jsp
    /MCMS/WebContent/css
    /MCMS/WebContent/css/tiles.css
    /MCMS/WebContent/images
    /MCMS/WebContent/images/logo.jpg
    /MCMS/WebContent/jsp
    /MCMS/WebContent/jsp/home.jsp
    /MCMS/WebContent/META-INF
    /MCMS/WebContent/template
    /MCMS/WebContent/template/template.jsp
    /MCMS/WebContent/WEB-INF
    /MCMS/WebContent/WEB-INF/lib
    /MCMS/WebContent/WEB-INF/tlds
    /MCMS/WebContent/WEB-INF/faces-config.xml
    /MCMS/WebContent/WEB-INF/struts-tiles.tld
    /MCMS/WebContent/WEB-INF/tiles.xml
    /MCMS/WebContent/WEB-INF/tiles-config_1_1.dtd
    /MCMS/WebContent/WEB-INF/web.xml
    /MCMS/WebContent/index.jsp
    This is the jar file which I am using in my proect:
    batik-awt-util-1.6-1.jar
    batik-ext-1.6-1.jar
    batik-gui-util-1.6-1.jar
    batik-util-1.6-1.jar
    commons-beanutils-1.7.0.jar
    commons-codec-1.3.jar
    commons-collections-3.2.1.jar
    commons-digester-1.8.jar
    commons-el-1.0.jar
    commons-fileupload-1.2.1.jar
    commons-io-1.3.2.jar
    commons-lang-2.4.jar
    commons-logging-1.1.1.jar
    commons-logging-api-1.1.jar
    commons-validator-1.3.1.jar
    jstl-1.2.jar
    myfaces-api-1.1.8.jar
    myfaces-impl-1.1.8.jar
    oro-2.0.8.jar
    standard-1.1.2.jar
    tiles-api-2.0.5.jar
    tiles-core-2.0.5.jar
    tiles-jsp-2.0.5.jar
    tomahawk-1.1.10.jar
    xmlParserAPIs-2.0.2.jar
    Web.xml:------
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" id="WebApp_ID" version="2.5">
    <display-name>MCMS</display-name>
    <!-- Tiles ViewHandler config file -->      
    <context-param>      
    <description>Tiles configuration      
    definition files and a listener need to be defined.      
    the listener will initialize JspTilesViewHandlerImpl with tiles definitions.      
    </description>
    <param-name>tiles-definitions</param-name>      
    <param-value>/WEB-INF/tiles.xml</param-value>      
    </context-param>
    <filter>
    <filter-name>extensionsFilter</filter-name>
    <filter-class>org.apache.myfaces.webapp.filter.ExtensionsFilter</filter-class>
    <init-param>
    <description>Set the size limit for uploaded files.
    Format: 10 - 10 bytes
    10k - 10 KB
    10m - 10 MB
    1g - 1 GB</description>
    <param-name>uploadMaxFileSize</param-name>
    <param-value>100m</param-value>
    </init-param>
    <init-param>
    <description>Set the threshold size - files
    below this limit are stored in memory, files above
    this limit are stored on disk.
    Format: 10 - 10 bytes
    10k - 10 KB
    10m - 10 MB
    1g - 1 GB</description>
    <param-name>uploadThresholdSize</param-name>
    <param-value>100k</param-value>
    </init-param>
    </filter>
    <filter-mapping>
    <filter-name>extensionsFilter</filter-name>
    <url-pattern>*.jsf</url-pattern>
    </filter-mapping>
    <filter-mapping>
    <filter-name>extensionsFilter</filter-name>
    <url-pattern>/faces/*</url-pattern>
    </filter-mapping>
    <welcome-file-list>
    <welcome-file>index.jsp</welcome-file>
    </welcome-file-list>
    <servlet>
    <servlet-name>Faces Servlet</servlet-name>
    <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
    <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet>
    <servlet-name>SourceCodeServlet</servlet-name>
    <servlet-class>org.apache.myfaces.shared_tomahawk.util.servlet.SourceCodeServlet</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>Faces Servlet</servlet-name>
    <url-pattern>*.jsf</url-pattern>
    </servlet-mapping>
    <servlet-mapping>
    <servlet-name>Faces Servlet</servlet-name>
    <url-pattern>/jsp/*</url-pattern>
    </servlet-mapping>
    <servlet-mapping>
    <servlet-name>SourceCodeServlet</servlet-name>
    <url-pattern>*.source</url-pattern>
    </servlet-mapping>
    </web-app>
    faces-config.xml:---
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE faces-config PUBLIC
    "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
    "http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
    <faces-config>
    <application>
    <view-handler>org.apache.myfaces.tomahawk.application.jsp.JspTilesTwoViewHandlerImpl</view-handler>
    </application>
         <navigation-rule>
    <from-view-id>*</from-view-id>
    <navigation-case>
    <from-outcome>nav_page1</from-outcome>
    <to-view-id>/jsp/home.jsp</to-view-id>
    </navigation-case>
    </navigation-rule>
    </faces-config>
    tiles.xml:---
    <!DOCTYPE tiles-definitions
    <!ENTITY % Boolean "(true|false)">
    <!ENTITY % ContentType "(string|template|definition|object)">
    <!ENTITY % ClassName "CDATA">
    <!ENTITY % RequestPath "CDATA">
    <!ENTITY % DefinitionName "CDATA">
    <!ENTITY % BeanName "CDATA">
    <!ENTITY % PropName "CDATA">
    <!ENTITY % Location "#PCDATA">
    <!ELEMENT tiles-definitions (definition+)>
    <!ELEMENT definition (icon?, display-name?, description?, put-attribute*, put-list-attribute*)>
    <!ATTLIST definition id ID #IMPLIED>
    <!ATTLIST definition preparer CDATA #IMPLIED>
    <!ATTLIST definition extends CDATA #IMPLIED>
    <!ATTLIST definition name CDATA #REQUIRED>
    <!ATTLIST definition role CDATA #IMPLIED>
    <!ATTLIST definition template CDATA #IMPLIED>
    <!ELEMENT put-attribute (#PCDATA)>
    <!ATTLIST put-attribute id ID #IMPLIED>
    <!ATTLIST put-attribute name CDATA #REQUIRED>
    <!ATTLIST put-attribute type (string|template|definition|object) #IMPLIED>
    <!ATTLIST put-attribute value CDATA #IMPLIED>
    <!ATTLIST put-attribute role CDATA #IMPLIED>
    <!ELEMENT put-list-attribute ( (add-attribute* | item* | bean* | add-list-attribute*)+) >
    <!ATTLIST put-list-attribute id ID #IMPLIED>
    <!ATTLIST put-list-attribute name CDATA #REQUIRED>
    <!ATTLIST put-list-attribute role CDATA #IMPLIED>
    <!ELEMENT add-attribute (#PCDATA)>
    <!ATTLIST add-attribute id ID #IMPLIED>
    <!ATTLIST add-attribute type (string|template|definition|object) #IMPLIED>
    <!ATTLIST add-attribute value CDATA #IMPLIED>
    <!ATTLIST add-attribute role CDATA #IMPLIED>
    <!ELEMENT add-list-attribute ( (add-attribute* | item* | bean* | add-list-attribute*)+) >
    <!ATTLIST add-list-attribute id ID #IMPLIED>
    <!ATTLIST add-list-attribute role CDATA #IMPLIED>
    <!ELEMENT bean (set-property*)>
    <!ATTLIST bean id ID #IMPLIED>
    <!ATTLIST bean classtype CDATA #REQUIRED>
    <!ELEMENT set-property EMPTY>
    <!ATTLIST set-property id ID #IMPLIED>
    <!ATTLIST set-property property CDATA #REQUIRED>
    <!ATTLIST set-property value CDATA #REQUIRED>
    <!ELEMENT item (#PCDATA)>
    <!ATTLIST item id ID #IMPLIED>
    <!ATTLIST item classtype CDATA #IMPLIED>
    <!ATTLIST item icon CDATA #IMPLIED>
    <!ATTLIST item link CDATA #REQUIRED>
    <!ATTLIST item tooltip CDATA #IMPLIED>
    <!ATTLIST item value CDATA #REQUIRED>
    <!ELEMENT description (#PCDATA)>
    <!ATTLIST description id ID #IMPLIED>
    <!ELEMENT display-name (#PCDATA)>
    <!ATTLIST display-name id ID #IMPLIED>
    <!ELEMENT icon (small-icon?, large-icon?)>
    <!ATTLIST icon id ID #IMPLIED>
    <!ELEMENT large-icon (#PCDATA)>
    <!ATTLIST large-icon id ID #IMPLIED>
    <!ELEMENT small-icon (#PCDATA)>
    <!ATTLIST small-icon id ID #IMPLIED>
    ]>
    <tiles-definitions>
    <definition name="layout.example" template="/template/template.jsp" >
    <put-attribute name="header" value="/common/header.jsp" />
    <put-attribute name="menu" value="/common/menu.jsp" />
    </definition>
    <definition name="/home.tiles" extends="layout.example" >
    <put-attribute name="body" value="/jsp/home.jsp" />
    </definition>
    </tiles-definitions>
    template.jsp:--
    <%@ page contentType="text/html;charset=UTF-8" language="java" %>
    <%@ taglib prefix="f" uri="http://java.sun.com/jsf/core" %>
    <%@ taglib prefix="h" uri="http://java.sun.com/jsf/html" %>
    <%@ taglib uri="http://tiles.apache.org/tags-tiles" prefix="tiles"
    %><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <head>
    <meta http-equiv="Content-Type" content="text/html;CHARSET=iso-8859-1" />
    <title>Myfaces - Tiles</title>
    <link rel="stylesheet" type="text/css" href="css/tiles.css" />
    </head>
    <f:view>
    <body>
    <div id="lftBar">
    <f:subview id="menu">
    <tiles:insertAttribute name="menu" flush="false" />
    </f:subview>
    </div>
    <div id="level0">
    <div id="level1">
    <div id="topBar">
    <f:subview id="header">
    <tiles:insertAttribute name="header" flush="false"/>
    </f:subview>
    </div>
    <div id="level2">
    <f:subview id="content">
    <tiles:insertAttribute name="body" flush="false"/>
    </f:subview>
    </div>
    </div>
    </div>
    </body>
    </f:view>
    header.jsp:---
    <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"
    %><h:graphicImage id="logo" url="/images/logo.jpg" />
    menu.jsp:--
    <%@ taglib uri="http://myfaces.apache.org/tomahawk" prefix="t"%>
    <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
    <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
    <h:form>
    <h:panelGrid columns="1" >
    <h:commandLink action="nav_page1">
    <h:outputText value="Page1" />
    </h:commandLink>
    </h:panelGrid>
    </h:form>
    ----------------------------------------

    Despite the fact that in preferences it says the folder is located in "C:\itunes
    Setting iTunes prefs -> Advanced simply sets the locaion of the iTunes Music/Media folder. It does not set the location of the iTunes folder, which the default location is \My Music\iTunes\. This contains the library files, which tells iTunes where/what everything is.
    We have drive space for 'personal' use on the C Drive. This is where I keep my itunes folder,
    Is this the \iTunes\ folder an in it is the iTunes library.itl file, iTunes music library.xml, iTunes media folder, Artwork folder, Previous iTunes libraries folder and a few other files?
    If so, hold Shift and launch iTunes. Select *Choose library* and select the *iTunes library.itl* file in this folder.
    iTunes will not create an iTunes folder in \My Music\.

Maybe you are looking for

  • Problem With Adobe Reader X (10.1.2)

    Just updated Adobe Reader to X (10.1.2). Every time I try to print a pdf document, I get message advising that Reader has encountered a problem and must be shot down.  Tried removing and reinstalling, but problem persists.

  • HOW DO I GET OUT OF FULL SCREEN MODE AND BACK TO THE HOME PAGE?

    I was at a website and expanded the view to full screen mode. i pressed ESCAPE but it would not return the screen to smaller size. I had to press CONTROL+ALT+DELETE end the session. Now, when I restart Firefox it wants to restore the session. I have

  • Search external files on RoboHelp Server

    With the RoboHelp Server (previously called the RoboEngine) installed on a server, you can add external files to your WebHelp or FlashHelp project and have the Search tab also search the contents of those files (PDF, DOC, XLS, PPT, and HTML). All you

  • Embedding a dtd with jdom

    Does anyone know how to embed a dtd into the xml using jdom? Thanks,

  • Dry loop availability

    I have been told both on the phone and using the online availbility checker that DLS is not available.  Even though I am in a densly populated area, I am not close enough to a "switching station" apparently.  But what about Dry Loop?  Since it's carr