#1
  1. No Profile Picture
    guest
    Guest
    Devshed Newbie (0 - 499 posts)

    Where is the advantage?


    I'm loving these tutorials. Keep them coming please.

    But what I'm curious about is where the advantage of JSP is? I can do everything you've mentioned here in PHP with 1/4 of the difficulty. Sessions are the only thing that I think are easier in JSP.

    I know it's all personal preference and "use what you know" but does it ever come out to a clear advantage for JSP at some point? for certain operations?

    Right now I'm just learning JSP so I can translate it into PHP... :)

    ---John Holmes...
  2. #2
  3. No Profile Picture
    guest
    Guest
    Devshed Newbie (0 - 499 posts)

    Re: Where is the advantage?


    Don't now whether PHP's support them but some of the JSP real advantages are:

    a) Tag libraries (do a lot with almost no code)
    b) Frameworks

    bad e.g. but still:

    <taglib:SENDMAIL ADDRESS="abc@abc.com">
    Dear John, ...
    </taglib:SENDMAIL>

    ASP .NET will have similar capabilities...

    t.
  4. #3
  5. No Profile Picture
    guest
    Guest
    Devshed Newbie (0 - 499 posts)

    Great Article!


    This article gave me a great jump-start in JSP! I can't wait for part 7????
  6. #4
  7. No Profile Picture
    guest
    Guest
    Devshed Newbie (0 - 499 posts)

    Error!


    use response.sendRedirect("start.html");

    instead of

    response.setHeader("Location", "start.html");


    1

  8. #5
  9. No Profile Picture
    guest
    Guest
    Devshed Newbie (0 - 499 posts)

    s


    s
  10. #6
  11. No Profile Picture
    guest
    Guest
    Devshed Newbie (0 - 499 posts)

    Great Article


    These JSP articles are great! I have a book about JSP that makes it look much harder than it really is. These examples are pretty straightforward.
  12. #7
  13. No Profile Picture
    guest
    Guest
    Devshed Newbie (0 - 499 posts)

    invalidate: Session already invalidated


    Hi
    <br />
    <br />
    your article was good but if u can help me in below problem with session then it would me great!!
    <br />
    <br />
    i am using session in my JSP and after sesson time out when i try to login again my same id , it gives me following error
    <br />
    <br />
    Root cause: java.lang.IllegalStateException: invalidate: Session already invalidated
    <br />
    <br />
    it dosent allow me to login in again with the same id until i restart my tomcat
    <br />
    <br />
    the code that i am using to invalidate sesiion is
    <br />
    <br />
    if(monitor.containsKey(user)) {
    <br />
    <br />
    HttpSession oldSession = (HttpSession) monitor.get(user);
    <br />
    <br />
    oldSession.invalidate();
    <br />
    <br />
    }
    <br />
    <br />
    session.setAttribute(&quot;user&quot;, user);
    <br />
    <br />
    session.setAttribute(&quot;usertype&quot;, loginBean.getUtype());
    <br />
    <br />
    session.setAttribute(&quot;uepin&quot;, loginBean.getUepin());
    <br />
    <br />
    monitor.put(user, session);
    <br />
    <br />
    <br />
    pls kindly help me and suggest me what is wrong with my code that it is not allowing me to register again with same name
    <br />
    <br />
    Thanks
    <br />
    <br />
    pradeepkharvi@hotmail.com
  14. #8
  15. No Profile Picture
    guest
    Guest
    Devshed Newbie (0 - 499 posts)
  16. #9
  17. No Profile Picture
    guest
    Guest
    Devshed Newbie (0 - 499 posts)
  18. #10
  19. No Profile Picture
    guest
    Guest
    Devshed Newbie (0 - 499 posts)
  20. #11
  21. No Profile Picture
    Ducani
    Guest
    Devshed Newbie (0 - 499 posts)

    The JSP Files (part 6): State Of Grace


    The JSP Files \(part 6\): State Of Grace

    Now that you've mastered the basics, it's time to bring out the big iron. This week, The JSP Files explores the various techniques available to "maintain state" on a JSP-based Web site. Learn about the Cookie and Session objects, find out how to build a cookie-based hit counter, and read about a simple yet effective way of protecting sensitive Web pages with the Session object.

    Please discuss this article in this thread. You can read the article here .

IMN logo majestic logo threadwatch logo seochat tools logo