Page 2 of 2 FirstFirst 12
Results 11 to 12 of 12

Thread: Problem with stylesheet in acegilogin.jsp page

  1. #11
    Join Date
    May 2006
    Posts
    26

    Default

    Has anyone else found a solution to this redirect problem? I'm getting the same thing where once a user logs in, it redirects to the correct page but it just downloads and displays the css style link from the adminLogin. I am authenticated and authorized correctly and if I logout and log back in, it redirects correctly. However that first time, it's certainly disconcerting.

    I have tried several ways of linking in the stylesheet information, using import in a couple of ways (with and without URL("...")), as well as the link tag in the header. If it is present, the default url that it goes to after a login is the css text. If the css link/import is not there, it goes to the correct url.

    Btw, I am using acegi 0.9.0.

  2. #12
    Join Date
    May 2006
    Posts
    26

    Default

    Sweet mercy, oddities with web browsers.

    I tried this with Safari, Firefox, Camino, and Opera on my Mac all with the same results - the first time to load the login page, once I logged in, it would redirect to the contents of the css file linked from the login page.

    Like Ben said, it was a problem with the css access. Apparently, if you are redirected to the login page and it has resources that are secure and you are not yet authenticated, the browser seems to put that request into the queue or something and once you've authenticated, that's the thing that it goes to.

    So the net solution is as he suggested - to make both the login jsp as well as the css file it references accessible by the ROLE_ANONYMOUS and it redirects correctly.

    It's just interesting to me to see that all the browsers I tried exhibited the same behavior - I would have thought that it would not have loaded the css file initially but redirectly correctly upon login in at least one of the browsers.

    Anyway, issue resolved (for me at least). Thanks for the previous posts!

Similar Threads

  1. Servlet writing byte[] image in jsp page
    By xmartinx in forum Web
    Replies: 2
    Last Post: Apr 26th, 2012, 04:50 AM
  2. Pageable data list with Hibernate
    By robmorgan in forum Data
    Replies: 23
    Last Post: Jul 24th, 2006, 06:12 PM
  3. Replies: 0
    Last Post: Jun 10th, 2005, 08:22 AM
  4. Replies: 2
    Last Post: May 13th, 2005, 05:42 AM
  5. problem view in a jsp page
    By susu80 in forum Web
    Replies: 1
    Last Post: Nov 3rd, 2004, 11:28 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •