Skip to Content
avatar image
Former Member

Dynamic JSPDynpage

Hello!

It's question for my understanding, I think.

I have JSPDynpage: JSP, class, bean.

If I want to dynamic show/hide (add/remove) some elements(button, for example) on my page, what should I do?

When I have only class(Dynpage) it's simple, but I have JSPDynpage.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    avatar image
    Former Member
    Oct 08, 2008 at 09:10 AM

    Hi Paul,

    Since you are using JSPDynpage, and need to show/hide buttons, you will need to so in the .jsp file of your portal application.

    for. eg. the edit button needs to be showed to the Administrator and not to the enduser.

    In this case i will write the code to access the logged in user details in the .java file. Here once i find that the user is an admin i will save a boolean flag called checkAdminFlag in the bean to true.

    Then in the .jsp file i will access the bean and retrieve the value of the checkAdminFlag. Depending on the value the edit button is made visible or not in a if condition.

    Hope this helps.

    Regards,

    Melwyn

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 08, 2008 at 08:57 AM

    This question is still actual

    Add comment
    10|10000 characters needed characters exceeded