How to init the login page in JSF?

I should receive the cookie data, if the cookie exists, then redirect to another page, and if not, just turn to the login page.
how can i do all these init operation in JSF?
P.S maybe my English is poor, i am sorry.......

Just implement a Filter which listens on /*. No need to do this simple redirection task in JSF.

Similar Messages

  • How to submit the login Page by pressing enter key.

    Hi,
    I am using JDev 11g TP3,JBoss 4.2.1, Trinidad 1.2.4.
    I have a login page in my project.I have a Submit button on the page.After filling in the details when I hit on the enter key my page doesn't get submitted.The submit butto does not get activated.I have to click on the submit button separately to submit the page. How should I get this working??

    Hi,
    If your page is built using ADF Faces / Trinidad, you can specify the "defaultCommand" attribute on the form component setting it to the client id of the default command component. For example:
    <af:form defaultCommand="SubmitCommandButtonId">If it is pure html (may be in a <f:verbatim /> tag), then simply having a submit button will do the trick.
    Olivier
    Message was edited by:
    Olivier Lafontaine

  • How to design the activate page in JSF?

    When user register in our site, we will send an activate email with embedded url something like that:
    http://localhost:8080/eshop/faces/activate.jsp?auth=Q849+kMSA2XSThYHJHJHsYUI
    When user click the url, we will get the parameter auth and set the flag in table to indicate the a/c is activated.
    How to implement this mechanism in JSF?

    Create a backbean for the page activate.jsp, inject your get parameter (auth) into it and execute your logic inside a postconstruct method.
    A useful article to learn how to inject get parameters: [Passing GET parameters from JSF to backing beans|http://balusc.blogspot.com/2006/06/communication-in-jsf.html#PassingGETParametersFromJSFToBackingBeans]

  • My Macbook Pro is frozen on the login page with a white screen and only my login picture. How do I fix this? I can't turn it off and I closed it and let it charge but it's still not working.

    My Macbook Pro is frozen on the login page with a white screen and only my login picture. How do I fix this? I can't turn it off and I closed it and let it charge but it's still not working. It's only 3 months old and was working perfectly fine 30min before this happened.

    Hello Kierasully,
    I would start your troubleshooting with the article below for issues of not being able to log in to your Mac. Start with booting up in to Safe Boot as well as resetting PRAM on your Mac. If that does not work, then verify the hard drive with booting to the Recover HD and go to Disk Utility to verify it.
    Mac OS X: Gray screen appears during startup
    http://support.apple.com/en-us/ts2570
    Regards,
    -Norm G. 

  • I made a big mistake to change the setting of my Mac book pro to "me only". Now ofcourse It cannot open the login page, for how would the mac know it is me? How can I change the setting back to "everyone"?

    I made a big mistake to change the setting of my Mac book pro to "me only". Now ofcourse It cannot open the login page, for how would the mac know it is me? How can I change the setting back to "everyone"? I have back up in the past but the last month I have not. I really want to keep the data.
    So how can I go in and change the setting, It stays ofcourse at the apple screen with wheel. All info is there and the computer works fine, just cannot use it or have been able to log in.

    wjosten is spot on.  If you really want iCloud, then you will need to acquire a new or second hand MBP that can run Lion.
    Ciao.

  • How to get rid of the Login page in Portal?

    Hi Guys,
    I have a newly developed intranet portal project for my company which does not need login no more. I hope you can help me how to get rid of the login page in portal which is I know in every application you create, there should be a login. Is this possible that I can just simply type in to the URL address bar my application then it will no longer ask for any logins? Please help! Many thanks!
    Russel

    Hi Russel,
    You can give public access to pages, applications etc. Users won't need to supply a username/password then, while you still can hide some of the pages to authorized people.
    Check the access tab for pages and the manage tab for applications.

  • How do I customize the login page?

    Hi, floks:
    How do I customize the login page?
    Can I just create a page with login portlet in it? what do I put as on Success URL,
    if I choose to go to the home page?
    thanks.
    null

    You can create a page and add a login portlet to it.Make it accesible to public.
    change the default page of the user "public" to the page you have created.(by default it is WELCOME)
    if there is an error in the user name or the password entered the portal still navigates to the default single-sign on page.(You have not changed the sign on page still)
    To change this page look at on-line help.
    search with string "customize" in online help
    null

  • How to show the login user Id in the upper right corner of each page?

    Hi,
    I was wondering how to show the login user Id in the upper right corner of each page?
    thanks so much!
    cchu

    Cchu,
    The easy question first: applying a style to the welcome message. If you look at the page source, you'll see that #WELCOME_USER# is expanded to <div class="app-user">Welcome: DEMO</div> So to change the style of the message, you need to tweak the style of the app-user div in your CSS, or override it in a style block in your HTML header.
    Now, the tougher question: why the text is wrapping for you. And, really, without seeing your entire page, I can't give a full answer. But I'd suggest that what's most likely happening is that the table column you're putting it in is too narrow, so it's wrapping; try replacing the td tag with <td nowrap="nowrap"> This will force the column to be wide enough to display the full message, but might result in weird formatting elsewhere on the page (depending on what all is in your table).
    -David

  • I can't open my work web site it lets me go right to the login page and won't open how can I fix this

    I can't open my work web site it let's me go to the login page then it won't go any further how do I fix this

    To see whether this problem is caused by the new HTML5 parser feature in Firefox 4, you can turn it off like this:
    (1) In a new tab, type or paste '''about:config''' in the address bar and press Enter. Click the button promising to be careful.
    (2) In the filter box, type or paste '''html5''' and pause while the list is filtered
    (3) Double-click '''html5.parser.enable''' to toggle it to false (it will turn bold).
    Then return to your work site and reload the page.
    Does that make any difference? If so, you can leave it that way. If not, you might as well switch it back (double-click that preference again to toggle it back to true.)
    If not, and you need to roll back, here's the process:
    First, I recommend backing up your Firefox settings in case something goes wrong. See [https://support.mozilla.com/en-US/kb/Backing+up+your+information Backing up your information]. (You can copy your entire Firefox profile folder somewhere outside of the Mozilla folder.)
    Next, download and save Firefox 3.6 to your desktop for future installation. http://www.mozilla.com/firefox/all-older
    Close Firefox 4.
    You could install Firefox 3.6 over it (many have reported success) or you could uninstall Firefox first. If you uninstall, do not remove your personal data and settings, just the program.
    Unless you have installed an incompatible add-on, Firefox 3.6 should pick up where you left off. If there are serious issues, please post back with details.
    Note: I haven't actually tried this myself!

  • How to insert an username from the login page to the form page

    Hi friends,
    I created one database apex application in which it consist of three pages...
    1)login page----->1
    2)form page along with report page(in same page) i.e. i created a report region within a form region
    3)form page(this page appears when i click the edit option in my previous report page
    (i.e.) my 3rd form page depends upon my 2nd report page, as soon after i click the edit option of each and every row in my report which is in 2nd page it has to go to the corresponding 3rd form page for making an updations in each and every row...
    I have created my above listed applications....
    But the scenario for me is since the login page contains two fields, that is
    user name:
    password:
    so i will be giving my name in the user name and also respective PW for accessing to my 2nd and 3rd page in my application...
    Since my 2nd form page consist of following fields like
    *) user name---------->
    *) assigned to
    *) status
    *) start date
    *) priority
    so my requirement over here is soon after i logging into my application through the user name and PW into second page, while coming to the second form page
    my user name field in my 2nd form page has to get inserted automatically with the user name that i have entered in the login page...
    example: my user_name in login page is :harry
    after going into the second form page with the user name "harry"
    the field of my 2nd form page "username" has to get automatically generated with the name "harry"
    Whether it is possible friends to do this in my application....i doesn't have any idea of it...Kindly help me friends to solve my scenario...please explain each and every steps in detailed manner...
    Since the user_name: harry, is of I got from the admin side as a developer for the workspace......
    Thanks in advance
    Harry....

    Hi Karthik,
    I made the following changes that you said, but there is just a one change in it...
    You told these changes
    Source Used: always, replacing any existing values in session state.
    Source Type: Database column
    Source value or expression: (respective column name)
    and in Default: u need to give-----> &APP_USER.(exactly the same including the full stop)....
    Thanks for your help Patel....I just worked and inserting for me in table of the corresponding user name who login.....

  • Modify the login page (login.jsp) of B2B scenario of the Internet Sales app

    All
    I wanted to modify the login page (login.jsp) of B2B scenario of the Internet Sales application
    By typing the URL "http://<servername>:50001/b2b/b2b/init.do." I could able to see the login page
    My requirement is to add an extra link in this page
    when I use showmodule=true it gives the location of jsp which is "user/logon/login.jsp"
    I could able to find this jsp in the DC "crm-isa-web-b2b"
    when I open the DC in package explorer i could able to locate this jsp in a jar file but not able to open/modify it
    Awaiting experts response
    Thanks
    Murali.K.N

    When I work on ours ISA4, I go to the file on the server
    \jsp\crm.b2b\servlet_jsp\b2b\root\b2b\login\login.jsp
    Now, I'd imagine there might be a much easier way to work with the files, but that's how I edited ours. 

  • Big authentication problem: not being redirected to the login page

    Hello, everybody!
    I've just noticed a big problem in the web application I'm developing. In this
    application I'm using the FORM authentication method as you can see below in the
    web.xml file:
      <security-constraint>
         <web-resource-collection>
                <web-resource-name>permitido</web-resource-name>
                <url-pattern>/*</url-pattern>
           </web-resource-collection>
           <user-data-constraint>
                <transport-guarantee>NONE</transport-guarantee>
           </user-data-constraint>
      </security-constraint>
      <security-constraint>
           <web-resource-collection>
                <web-resource-name>restrito</web-resource-name>
                <url-pattern>/confirmacaoreserva.jsp</url-pattern>
                <url-pattern>/confirmacaoreserva.faces</url-pattern>
                <url-pattern>/reservaconfirmada.jsp</url-pattern>
                <url-pattern>/reservaconfirmada.faces</url-pattern>
           </web-resource-collection>
           <auth-constraint>
                <role-name>ADMINISTRADOR</role-name>
                <role-name>USUARIO</role-name>
           </auth-constraint>
           <user-data-constraint>
                <transport-guarantee>NONE</transport-guarantee>
           </user-data-constraint>
      </security-constraint>
      <login-config>
           <auth-method>FORM</auth-method>
           <form-login-config>
              <form-login-page>/login.jsp</form-login-page>
                <form-error-page>/errologin.jsp</form-error-page>
           </form-login-config>
      </login-config>
      <security-role>
           <role-name>ADMINISTRADOR</role-name>
      </security-role>
      <security-role>
           <role-name>USUARIO</role-name>
      </security-role>If I type in the browser's address field any of the protected pages,
    confirmacaoreserva.faces or reservaconfirmada.faces, the web container redirects
    me to the login page as expected, as I was'n authenticated yet. Until till
    this point everything is working without problem. But I noticed, to my surprise,
    that when I click on a link in a web page like this:
    <h:commandLink value="#{msg.reservar}" action="#{materiais.reservarMaterial}">
        <f:setPropertyActionListener target="#{materiais.codigoMaterial}" value="#{material.codigo}" />
    </h:commandLink>
    // in the backing bean
    public String reservarMaterial()
        // some processing...
        return "confirmacaoReserva";
    // in faces-config.xml
    <navigation-rule>
        <navigation-case>
            <from-outcome>confirmacaoReserva</from-outcome>
            <to-view-id>/confirmacaoreserva.jsp</to-view-id>
        </navigation-case>
    </navigation-rule>it completely by-passes the web container authentication and redirects me to the
    protected page (+confirmacaoreserva+) without asking me first to authenticate in
    the login page. Of course this is unacceptable.
    So, how can I solve this? How do I fix this problem?
    Thank you.
    Marcos

    Marcos_AntonioPS wrote:
    BalusC wrote:
    Which appserver implementation/version are you using?JBoss 4.2.3.GAOK.
    Which JSF implementation/version are you using?The default JSF implementation that comes with JBoss 4.2.3.GAWhich one? Read the manifest file of the JSF implementation JAR.
    Does it work if you redirect instead of forward in the navigation case (just add <redirect />) ?I haven't tested yetAnd?

  • Does anyone here knows how to create a login page thru JDBC?

    Anyone here knows how to create a login page which connect to database thru JDBC but not JDBC-ODBC bridge?

    Hi..pls you'll do people here a great good if you could explain yourself better..!
    Anyway if you are trying to connect to an Oracle Database you dont need the jdbc-odbc bridge as oracle provides a special driver for java applets/applications that is "the thin driver" and the "oci driver"..so if you are connecting to Oracle your connection will look like this:
    Class.forName("oracle.jdbc.driver.OracleDriver"); //not sun.jdbc.odbc.JdbcOdbcDriver
    Connection con = DriverManager.getConnection ("blah blah, blah");
    no need for the jdbc-odbc bridge.
    I hope i've answered your question.
    Thanks.

  • Firefox does not automatically load nor find the login page for a public network (i.e. username and password)

    To log in on a public network without a password-key (not secured), a user login is required.
    After connecting to the network, the browser, upon opening it, normally automatically loads the login page, in order to enter a username and password and connect to the internet.
    Firefox doesn't find the login page automatically, so I need to switch to google Chrome just to log in to the network.
    Does this have anything to do with user settings in the options of firefox?
    Any ideas?
    thx!

    Hi,
    You can try setting the login page as the [https://support.mozilla.org/en-US/kb/How%20to%20set%20the%20home%20page Home page] and choose to '''Show my home page''' beside '''When Firefox starts:'''.
    Alternatively, and/or to preserve your current settings you could also pin it as an always present one-click away [https://support.mozilla.org/en-US/kb/what-are-app-tabs App tab].

  • How to link the resource bundle in JSF implemented in  eclipse?

    Kindly help me out

    This is how I called the resource bundle in JSF
    <%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
    <%@ taglib prefix="f" uri="http://java.sun.com/jsf/core"%>
    <%@ taglib prefix="h" uri="http://java.sun.com/jsf/html"%>
    <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
    <title>Insert title here</title>
    </head>
    <body>
    <f:view>
    <f:loadBundle basename="constantsUIProp" var="prop"/>
    <h:form>
    <h:inputText maxlength="#{prop.AREA_CODE_MAX}"></h:inputText>
    </h:form>
    </f:view>
    </body>
    </html>
    when i tend to build, it shows an error like+ Resource bundle cannot be found on the classpath+
    I have saved the resource bundle in WebContent/Web-Inf/classes/constantsUIProp

Maybe you are looking for

  • [Solved] 32bits app on 64bits system

    Hi, I get the following message when trying to execute the anubis program : $ anubis bash: /usr/bin/anubis: Aucun fichier ou dossier de ce type (which means No such file or directory) The file exists so I guess the probem is that anubis is a 32bits p

  • Query on IT0585

    Hi, I have a query on IT0585 country India specific infotypes. When the payrol is in Release mode, whenther the country specific infotypes can we able to modify? Regards, Chandra

  • I load cbc.ca and it loads ok then a grey screen covers the page and freezes everything - doesn't happen on other browsers

    I load cbc.ca - I assume other sites but haven't test - and it loads ok - then a grey screen covers everything and freezes the content- Other tabs work fine for other pages just not cbc.ca - what's wrong. This happens on all my copies of ffox. So not

  • ITunes 7.+Compatability with Ask the DJ --getting nowhere

    I have iTunes 7.0+ & Ask the DJ on my MacBookPro. When I drag tunes to ATDJ they get all bpm ect. but when I play them they're garbled then just stop. It only happens on MBP none of the other machines, I've erased the old copies & downloaded new soft

  • N85 can't send files to Non-Nokia Devices

    pls help, i had to reformat my N85 due to a virus which cause my phone to auto browse.  After which i can not anymore send files to non-nokia phones thru bluetooth but i am able to receive.  I can even pair with non-nokia devices but i just CANT SEND