You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Rick Schumeyer <rs...@ieee.org> on 2006/12/20 02:36:56 UTC
basic JSTL question
These should be easy questions, but I can't find the answers...if
someone could either answer them or point me to the right docs, I would
appreciate it.
1. What is the proper uri for the jstl core library? According to my
JSP book it should be
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
but eclipse complains about unknown tags like <c:out>.
2. In another thread I learned that it is preferred not to use the
struts bean tags (Or are the bean tags ok, but not the logic tags...)
Do I want to use c:out or jsp:usebean to display the contents of an
actionform? How about a "normal" bean?
3. Can someone show me an example of using the c:out tag to display the
contents of an ActionForm?
4. Same as 3, but for a regular bean set in the action via
request.setAttribute ?
It's possible that if I fix #1, the rest will fall into place. Thanks
for any help!
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: basic JSTL question
Posted by Wendy Smoak <ws...@gmail.com>.
On 12/19/06, Rick Schumeyer <rs...@ieee.org> wrote:
> These should be easy questions, but I can't find the answers...if
> someone could either answer them or point me to the right docs, I would
> appreciate it.
>
> 1. What is the proper uri for the jstl core library? According to my
> JSP book it should be
>
> <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
>
> but eclipse complains about unknown tags like <c:out>.
It depends on what JSTL and Servlet spec versions you're using. (And
the rest of the answers depend on this one.)
There is some information here to help you sort it out:
http://wiki.apache.org/struts/StrutsAndJSTL
--
Wendy
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: basic JSTL question
Posted by Rick Schumeyer <rs...@ieee.org>.
Never mind! The solution involved some not-so-obvious steps
1. download and install the jstl (ok, this should have been obvious)
2. Change the top of my web.xml (this was not obvious...see
http://forum.java.sun.com/thread.jspa?threadID=629437&tstart=0)
3. read the docs on jstl and FormBeans
Thanks anyway.
Rick Schumeyer wrote:
> These should be easy questions, but I can't find the answers...if
> someone could either answer them or point me to the right docs, I
> would appreciate it.
>
> 1. What is the proper uri for the jstl core library? According to my
> JSP book it should be
>
> <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
>
> but eclipse complains about unknown tags like <c:out>.
>
> 2. In another thread I learned that it is preferred not to use the
> struts bean tags (Or are the bean tags ok, but not the logic tags...)
> Do I want to use c:out or jsp:usebean to display the contents of an
> actionform? How about a "normal" bean?
>
> 3. Can someone show me an example of using the c:out tag to display
> the contents of an ActionForm?
>
> 4. Same as 3, but for a regular bean set in the action via
> request.setAttribute ?
>
> It's possible that if I fix #1, the rest will fall into place. Thanks
> for any help!
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org