Avatar of TheFACTORY_Max
TheFACTORY_MaxFlag for South Africa asked on

How to retrieve a struts global forward in jsp without using the html taglibrary

Hello everyone,

Quick question, I have a jsp page which uses a javascript to open a popup window like this:

window.open('popup.html','name', 'height=255, width=250, address=no, toolbar=no, location=no, menubar=no, directories=no, status=no, scrollbars=no, resizable=no, modal=yes');

Now the (action)path of the page where I want this window tot popup to is defined in the global forwards of the struts framework:

<global-forwards>
    <forward name="pageEditLogo" path="/actions/pageEditLogo.do" />
</global-forwards>

I do this to keep all the workflow in one place. Normally I would use the html taglib for creating a link like:

<html:link forward="pageEditLogo" />

However this time I need the path of the forward to be retrieved, for use in the javascript, with either a taglib (other than html creating everything around it) or EL, since I want to place this path in a custom context. How do you do this?

Thanks
Java EEJSP

Avatar of undefined
Last Comment
TheFACTORY_Max

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Mr_It

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
See how we're fighting big data
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
ASKER
TheFACTORY_Max

       <bean:struts id="myId" forward="pageEditLogo" />
        ${myId.path}

That's it, thank you!!
Your help has saved me hundreds of hours of internet surfing.
fblack61