• 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

Custom tag not evaluating ${} expressions

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I've been stuck for a few days now... I'm trying to build a custum tag with parameters but my setter always receive a string when I pass a value as ${model.testStr}.

It's one of my first tag so I as an exemple I redefined the c:out tag in my library... Same soruce code, same config and yet the explression is passed as a srting...
JSP:

Results in :

ps : "SWEET!" is my ${model.testStr}

Here's my lcc.tdl:


Any help will be greatly appreciated,

Thanks,

Matt
 
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
As per forum instructions, please include what versions of JSP, JSTL and Servlets that you are using.

Problems like this are a sign of mixing incompatible versions, or of web app misconfiguration.
 
Matthieu Levesque
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Here's what i'm using :
tomcat 6 with liferay 5.2 portlet container
portlet 2.0

For my jsp version I think it's 1.2 since in my web.xml I have the http://java.sun.com/dtd/web-app_2_3.dtd specified.

For my jstl version 2.0, as it was showing in my last post...

The problem is probably between the jsp 1.2 and jstl 2.0... I'll experiment a bit and let guys kknow...
 
Bear Bibeault
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You'll need to get your versions straight. For example, there is no JSTL 2.0.

Check the JSP FAQs for info on setting up the proper versions and declaring your web.xml properly.
 
Matthieu Levesque
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

Obviously my config is wrong... Would you have any good working example that I could follow?

Keep in mind that it'is my first custom tag...
 
Bear Bibeault
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Have you consulted the JSP FAQ as instructed?
 
Matthieu Levesque
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I finaly figured it out...

I changed my web.xml header to this :



Thanks
 
reply
    Bookmark Topic Watch Topic
  • New Topic