How to invoke "j_security_check" in jsf page

Hi,
with ADF security configure in Jdeveloper11.1.1.2, it automatically generate login.html and error.html for form authentication.
I found in login.html, the action for form is "j_security_check", and I try to customize login page with jsf page, but don't know how to invoke "j_security_check" in jsf page, there is no more action attribute within af:form and I cannot find the "j_security_check" in commandButton action Expression Build.
Thanks in advanced.
Best Regards,
Bill

Hi,
you will have to add the login form to the JSf page wrapped in f:verbatim so it shows as part ofthe JSF page. In JSF 1.2 using f:verbatim shoucl not be require, but by experience, better is.
If you develop and deploy on WLS, then chapter 30 of the Fusion Developer Guide has a god solution for you to build a login form in JSF completely
http://download.oracle.com/docs/cd/E15523_01/web.1111/b31974/adding_security.htm#BABDEICH
This does not require j_security_check at all
Frank

Similar Messages

  • How to add fragment in jsf page using include tag in jdeveloper

    Hi all
    Can you tell me wat is syntax of using include tag .or how to add fragment in jsf page ..
    Edited by: 947228 on Jul 18, 2012 5:01 AM

    Hi,
    Why do you want to do that?
    Check [url https://blogs.oracle.com/jheadstart/entry/avoid_use_of_jspinclude_where]this out before proceeding further.
    Btw, always mention your JDev version, clear usecase to get help.
    -Arun

  • How can I set a JSF page to accept requests from outside

    I have a file upload page in my application(JSF and MyFaces). It works fine when I navigate to page and select the file to upload and submit. Do I need to make any changes to this page to post from an external system?
    I created a perl script to send a file to this page. When I called the URL for this page, it returned the page content. How can I submit from the perl script?
    <h:form id="apppostform" name="apppostform" enctype="multipart/form-data" >
              <h:panelGrid styleClass="mbformdata" columns="2" border="0" cellspacing="25" cellpadding="0">
              <h:outputText value="#{appmsg.prompt_upload_file}"/>
              <t:inputFileUpload id="fileupload"
              value="#{fileUploadForm.upFile}"
              storage="file"
              styleClass="fileUploadInput"
              />
                   <h:commandButton type="submit" value="submit" action="#{fileUploadForm.uploadFile}"/>
                   </h:panelGrid>
    </h:form>
    Thanks,
    rm

    I created uploadservlet. I specified in web.xml:
    <servlet>
    <servlet-name>uploadservlet</servlet-name>
    <display-name>UploadServlet</display-name>
    <servlet-class>servlet.UploadServlet</servlet-class>
    </servlet>
    When I try to access uploadservlet, I am getting 404 error.
    I have few questions:
    How does it know about uploadservlet if it is not inherited from facesservlet while using JSF?
    Do I need to add any info about this in faces-config.xml?
    Please help!
    Thanks

  • How can I include a jsf page?

    I need to include a jsp page that contains jsf code, I try with:
    <c:import url="faces/include.jsp" var="prova" />
    but the server response:
    javax.servlet.ServletException: Cannot find FacesContext
    There something that is wrong?
    Thank's
    Teo

    I read the document but is not my case.
    My java server faces works well until I put the tag
    <c:import url="./include.jsp" var="jsf" />
    from tag library, ans I don't know why
    Thank's
    Matteo

  • How to run and JSF page from Bea Weblogic 8.1

    Hi, I am new to JSF . Can anybody help me that how can i access a JSF page from Bea Weblogic 8.1. How can deploy. What libraries and files are needed and where to put these required .jar or library files. I just wrote a single page and now i am not able to run it . Any help would be highly appreciated.I am looking forward for your kind replies.Thank you.
    Regards,
    Waqar

    You need to package your application into the standard .war format. Make sure jsf-api.jar and jsf-impl.jar are placed in WEB-INF/lib, your faces-config.xml is in WEB-INF, and your tld files are defined appropriately. Once you have your .war file, deploy it to your servers applications directory or use the console for deployment.
    You should not have any problems if everything is packaged correctly. I am successfully using WebLogic Server 8.1 with my JSF-based web app.

  • Move and rename JSF page

    How can I rename a JSF page? and how can I move a JSF page from one viewController project to another?

    Hi
    I am using JDev 10 and there is no refactor menu for refactoring a *.jsp page. You can create a new page and copy the content out of the old page into the newer. But dont forget to customize the faces-config.xml and your corresponding backing bean before you delete the old page.
    Regards
    Majo

  • How do mathematical functions in a table invoked in jsf page

    hi i need detail about how can i do mathematical functions for data in table in jsf page using adf bc. for example in my table(sales) i give product id,name,unit price, quantity then i want to calculate product of quantity and unit price in a table automatically and store in total amount column

    Hi,
    John suggestion would work. Another option is to define it in EL using #{row.quantity * row.unitPrice} as the outputText value. Then add a numberConverter to the outputText using type="currency". The best option, imho, is to define the totalAmount attribute on the VO and implement the product there. However, keep the converter on the inputText and don't use the display hints on the VO.
    Regards,
    ~ Simon

  • How to Open an Oracle Report From a JSF Page

    Hi there,
    I would be really grateful if anyone would find me a solution to the following scenario:
    In my company, we have a project where we have to convert Oracle Forms and Reports to Java Web Application. The conversion of forms is being done thourgh JSF/ADF technology but how can i open an Oracle Report from a JSF page after supplying it with parameters ? Or i have to do some type of conversion before ?
    Once again i would be thankfull for your replies.

    Tapash,
    Thanks for reponding.
    Here is the URL I am currently using :
    https://gccss.glendale.edu:8001/dev60cgi/rwcgi60?server=rep60_crp3+userid=apps/pswd@crp3+report=/u07/oracle/crp3appl/gcccus/11.5.0/reports/US/GCC_ACCRUAL_BAL_0505.rdf+desformat=html+paramform=yes+destype=cache+p_accesscode=""
    The p_accesscode is the parameter I need to pass to the Oracle report.
    Currently, when I click the button, it invokes the above URL and takes me to the parameter form of the Oracle report and when I enter the Username, it runs the report and displays the desired output. But, what I need to achieve is, to pass the current user who has logged in behind the scene and to get rid of the parameter screen totally. Is this doable ? If yes, please help me !!!
    Thanks
    Hilal

  • How to call a struts action from a JSF page

    I am working on a small POC that has to do with struts-faces. I need to know how to call a struts ".do" action from a JSF page..
    Sameer Jaffer

    is it not possible to call a action from the faces submit button and/or the navigation?
    This a simple POC using struts-faces exmaples.
    Here is my struts-config and faces-config file.
    <struts-config>
    <data-sources/>
    <form-beans>
      <form-bean name="GetNameForm" type="demo.GetNameForm"/>
    </form-beans>
    <global-exceptions/>
    <global-forwards>
      <forward name="getName" path="/pages/inputname.jsp"/>
    </global-forwards>
    <action-mappings>
      <action name="GetNameForm" path="/greeting" scope="request" type="demo.GreetingAction">
       <forward name="sayhello" path="/pages/greeting.jsp"/>
      </action>
    </action-mappings>
    <controller>
        <set-property property="inputForward" value="true"/>
        <set-property property="processorClass"
                value="org.apache.struts.faces.application.FacesRequestProcessor"/>
    </controller>
    </struts-config>faces-config
    <faces-config>
    <managed-bean>
      <managed-bean-name>calculate</managed-bean-name>
      <managed-bean-class>com.jsftest.Calculate</managed-bean-class>
      <managed-bean-scope>request</managed-bean-scope>
    </managed-bean>
    <managed-bean>
      <managed-bean-name>GetNameForm</managed-bean-name>
      <managed-bean-class>demo.GetNameForm</managed-bean-class>
      <managed-bean-scope>request</managed-bean-scope>
    </managed-bean>
    <navigation-rule>
      <from-view-id>/calculate.jsp</from-view-id>
      <navigation-case>
       <from-outcome>success</from-outcome>
       <to-view-id>/success.jsp</to-view-id>
      </navigation-case>
      <navigation-case>
       <from-outcome>failure</from-outcome>
       <to-view-id>/failure.jsp</to-view-id>
      </navigation-case>
    </navigation-rule>
    <navigation-rule>
      <from-view-id>/inputNameJSF.jsp</from-view-id>
      <navigation-case>
       <to-view-id>/pages/greeting.jsp</to-view-id>
      </navigation-case>
    </navigation-rule>
    </faces-config>in my inputNameJSF.jsp (faces page)
    <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
    <%@ taglib prefix="f" uri="http://java.sun.com/jsf/core" %>
    <%@ taglib prefix="h" uri="http://java.sun.com/jsf/html" %>
    <%@ taglib prefix="s" uri="http://struts.apache.org/tags-faces" %>
    <!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>Say Hello!!</title>
    </head>
    <body>
    Input Name
    <f:view>
         <h:form >
              <h:inputText value="#{GetNameForm.name}" id = "name" />
              <br>
              <h:commandButton id="submit"  action="/greeting.do" value="   Say Hello!   " />
         </h:form>
    </f:view>
    </body>
    </html>I want to be able to call the struts action invoking the Action method in the that returns the name
    package demo;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;
    import org.apache.struts.action.ActionForm;
    import org.apache.struts.action.ActionForward;
    import org.apache.struts.action.ActionMapping;
    public class GreetingAction extends org.apache.struts.action.Action {
        // Global Forwards
        public static final String GLOBAL_FORWARD_getName = "getName";
        // Local Forwards
        private static final String FORWARD_sayhello = "sayhello";
        public GreetingAction() {
        public ActionForward execute(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception {
            String name = ((demo.GetNameForm)form).getName();
            String greeting = "Hello, "+name+"!";
            request.setAttribute("greeting", greeting);
            return mapping.findForward(FORWARD_sayhello);
    }Edited by: sijaffer on Aug 11, 2009 12:03 PM

  • Invoke secured WS from ADF JSF Page

    Hello,
    How can I invoke secured Web Service from simple adf jsf page?? Service is secured by wss_username_token_service_policy.
    I'll be glad if somebody could give me some tutorial how to build this page. I mean inputs for username and password.
    Best regards,
    MK

    Hi,
    I've read your article: http://www.oracle.com/technology/products/jdev/howtos/1013/protectedws/access_protected_web_services_from_adf.htm I added to the Model - Web Service Data control and as a service give a link to my composite application deployed on soa_server (http://localhost:8001/soa-infra/services/default/registerMyPassComposite/registerMyPassWebService?WSDL). When i click on Define Web Service security I only have a window to add policies and there is no wizard steps as you shown i your article Figure 9. I cannot chose Authentication type but I can only define policies for my dataControl.
    How to resolve it?

  • How to invoke JSF With Standard Urls and parameters

    Hi,
    Could some one please help me how to invoke JSF with standard Urls and parameters?
    My requirement is:
    http://localhost:8080/myapp/faces/jsf_page.jsp?trackerID=11&viewPage="products"
    then i want to save the tracker details into database and redirect the user to "products" page.
    Would some one suggest me where can i get some example?

    Hi BalusC,
    It didn't solve my proble.....Your solutions are fantastic for most of the issues. But mine problem is unclear where JSF page tags.
    If possible, Could you please provide me how to invoke the method from JSF page....
    same code works if the user click on command button but my requirement is as soon as the user click on the link from 3rd party website, then he need to come to our web application and invoke the JSF page along with ManagedBean for saving details and redirect to disganted webpage.
    I will provide the following link to 3rd party websites. the URL is :: http://somedomain.com/myApp/Tracker.JSF?trackerID=111
    Could you please provide me the code i need to write in JSF ....just for invoking ManagedBean class...? how i code for page on load call the managedBean for specific method?

  • How do I pass input values from a html page to a jsf page

    hi,
    In my project,for front view we have used html pages.how can I get input values from that html page into my jsf page.for back end purpose we have used EJB3.0
    how can I write jsf managed bean for accessing these entities.we have used session facade design pattern and the IDE is netbeans5.5.
    pls,help me,very urgent
    thanx in advance

    Simplest way is to rewrite html page into jsf page.
    You can use session bean in your managed bean like this:
    import javax.naming.Context;
    import javax.naming.InitialContext;
    public class ManagedBean {
    private Context  ctx;
    private Object res;
    // session bean interface
    private Service service;
              public ManagedBean() {
                try{
                     ctx = new InitialContext();
                     res = ctx.lookup("Service");
                     service = (Service) res;
               catch(Exeption e){
    }Message was edited by:
    m00dy

  • How to get values from a query string in URL in a jsf page?

    if i have a url, http://my.com/?name=john+smith, how do i get the values from that url in a jsf page and then pass those values to a servlet?
    i know how to do that in jsp using "request.getParamter("name")" and save it in a bean and then forward to a servlet. But what about in jsf?

    Hello,
    Try this:
    Map requestMap = FacesContext.getCurrentInstance().getExternalContext().getRequestMap();
    String name = (String) requestMap.get("name");If isn't worked one of these methods probably will solve your problem.
    FacesContext.getCurrentInstance().getExternalContext().getRequestParameterMap();
    FacesContext.getCurrentInstance().getExternalContext().getRequestHeaderMap();hth.

  • How-to get attributes from one JSF page redirected to another?

    How do I send information from one JSF page when the navigation rule redirects it to another?
    When JSF navigation does a forward I can use request.setAttribute() in the from-page and then use request.getAttribute() in the to-page, but this doesn't work with <redirect/>.
    Regards,
    Al Malin

    The process scope in ADF Faces solves this. See:
    http://www.oracle.com/webapps/online-help/jdeveloper/10.1.3/state/content/navId.4/navSetId._/vtTopicFile.adffacesguide%7Cdevguide%7CcommunicatingBetweenPages%7Ehtml/

  • How to Use another JSF page that I load by XMLHttpRequest?

    Hi everyone, I'm a newbie of JSF and curisous about how to load page content seperately by AJAX.
    I saw example of Java Blue Print. It's load some data to use in page. What I want is to load another JSF page when click a link or button, (Like include another page). And work with functions privoided by loaded JSF Page.
    My example is, In a main page. I request a JSF page and set it into a div layer.
    var requestURL = "/admin/customer/customer-list-body.faces";
    var content = postDataWithoutContent(requestURL);     divContent.innerHTML = content;     
    All JSF components are required under <f:view>, thus action of form is set as "action='"/admin/customer/customer-list-body.faces'"
    But my page is main.jsp. Each time I click command button in customer-list-body.faces, the url will change to customer-list-body.faces, I want to request and hold in main.jsp.
    What can I do then? Any advices?

    Hi,
    the list doesn't seem to be your problem. You need to track down the illegal argument exception. Once you have that sorted out, expose the method on the AM so it gets shown as a method binding. The return values then could be picked up in a managed bean to create the select Item list
    Frank

Maybe you are looking for