• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Xtags tag in html:link problem ...

 
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello all...

I don't know if this is the correct title for the topic , but here's the problem.
I have a dynamic menu in my app. The menu definition is read from a xml file using xtags library. I use <html:link action="..." > to navigate.
The code looks something like:

The error I get is
which means that the quotes in the "action" attribute mess up. Is there any way I can fix this ?!

Thanks a lot.
[ October 10, 2005: Message edited by: Daniel Platon ]
 
Ranch Hand
Posts: 354
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
one set of tag must use double quote while the other must use single. try the single quotes for your xtags and place that inside html:link's action attribute.
 
Daniel Platon
Ranch Hand
Posts: 42
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks a lot. It compiles now but it still doesn't work. When I put it like this:

it says

meaning that he's not able to interpret the xtags tag.

When I put it like this
it displays funny and still isn't able to interpret the tag.

I have finally tried without the qoutes on the action tag but it raises a compilation errors.

Thanks a lot.
 
alan do
Ranch Hand
Posts: 354
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
tough one buddy. struts-html generally evaluates values passed into the tags as strings. some tag attributes accept scriptlets, but others you cannot. it's even worse in your case.

the only way i can think of that may let this work is to see if xtags can set a value to a variable and place the variable into the request or page scope and use html_el:link (that is the expression language library - http://struts.apache.org/faqs/struts-el.html) to access it. ex. <html_el:link action="${requestScope.xActionName}" .../>
 
reply
    Bookmark Topic Watch Topic
  • New Topic