Announcement Announcement Module
Collapse
No announcement yet.
Login form on multiple pages Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Login form on multiple pages

    Hi,

    I'd like to have a login form available on every page on the web site. I'm having troubles when configuring the SimpleFormController because formview & successview are not constant (I think so).

    The first issue was a Exception raised when the form was displayed because the 'command' object was no initialized by the formBackingObject method and the form binding fails.

    I resigned for direct data binding using a standard HTML form but when I try to dynamically assign the formview/successview in the controller logic, it's not really consistant and I get some errors.

    I can't figure how achieve this facility and I feel it's a quite common subject that many site offer.

    Any idea ?

  • #2
    [solved]

    Hi,

    I finally sorted this out by setting the sessionForm attribute to false to force to go by the formBackingObject method where I initialize the formview to the current page.

    Comment


    • #3
      Hi sylbal

      Just a question because I will be in a similar situation soon How did you "include" your login from on every page of your application? Are you using Tiles, JFS, Freemarker, "pure" JSPs, ...?

      I imagine I could have a "link" to let's say "login.html" in a "template" that is used on every page and map "/login.html" to my login controller?

      Something along these lines?


      Rgds
      guybrush

      Comment


      • #4
        Hi there,

        The login form is basically included as a jsp fragment in the main navigation bar. I don't know jsf but I assume it's possible. My little experience with Tiles, Freemarker or Velolicy just make me sure it's easy to do with these technologies. As far as I remember , Tiles would be the best choice as there's a 'Layout' approach where you could include your login form and present it on every pages but this technologiy is sometimes overkill for simple sites.

        Hope this helps,
        -sb

        Comment

        Working...
        X