• 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
  • Ron McLeod
  • Rob Spoor
  • Tim Cooke
  • Junilu Lacar
Sheriffs:
  • Henry Wong
  • Liutauras Vilda
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Tim Holloway
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Mikalai Zaikin
  • Piet Souris

JSTL not working

 
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
as you can see i am playing with j2ee this weekend (hence the flurry of posts about servlets and jsps) and my most recent problem is that the jstl tags do not seem to be working. i looked through jsp faq and i dont see where i am going wrong. i am using tomcat 5.5. this is what i have done so far:

1. copied the jstl.jar and standard.jar files from $CATALINA_HOME/webapps/jsp-examples/WEB-INF/lib to my webapp's lib directory
2. created the following jsp page:



... that's it actually. i am sure that for loop doesn't do what i expect yet but the output is something else entirely:


<@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> ${param.test1} = a
:



what gives?
 
Sheriff
Posts: 67590
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
What gets sent to the browser? (In other words, what does a View Source show? Are the tags not getting evaluated before being sent to the browser? Or are you just getting unexpexted results?)
[ July 08, 2007: Message edited by: Bear Bibeault ]
 
Ra Carter
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
that was what was displayed in the browser. the page source is this:



i was expecting to see the results of the foreach loop...
 
Bear Bibeault
Sheriff
Posts: 67590
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
Inspect this line carefully:

 
Ra Carter
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i guess it is time i take a rest from programming right now. thanks.
[ July 08, 2007: Message edited by: ra carter ]
 
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
<%@ taglib prefix="" uri="" %>

that works for me. I guess you forgot the % before @
 
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic