You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Todor Sergueev Petkov <t....@basalmed.uio.no> on 2003/10/22 11:39:11 UTC

STRUTS TAGLIBS USAGE question

I have the following in a jsp search page:

<html:textarea property="field(SourceArea)" rows="0" cols="0" 
styleClass="searchTextArea"/>

field is an ActionForm and is a map. In this example "SourceArea" is 
hard coded as string.
Is it possible to retrive this hard coded string from properties file?
I tried something like :

     <html:textarea property="field('<bean:message 
key="source.area"/>')" rows="0" cols="0" styleClass="searchTextArea"/>

but it doesn't seem to work...
Any suggestions ?

Todor


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


Re: Cannot find bean org.apache.struts.taglib.html.BEAN in any scope (URGENT)

Posted by lover birds <ua...@yahoo.com>.
In that case I would suggest to add setter and getter method for the new text field with exactlt same name for variable in your form bean, hope this helps.

Caroline Jen <ji...@yahoo.com> wrote:I am also in trouble. My problem is sort of related
to yours although not directly relevant. I am also
looking for org.apache.struts.taglib.html.BEAN

I am trying to modify Ted Husted's artimus_1_1 example
- I want to add one more property to his articleForm.

To submit an article in the artimus_1_1 example, his
form.jsp in the /article/content folder asks for
title, author, and article. I inserted one more text
field:


Journal Category:

maxlength="75"/>


to indicate the academic field of the article. I got
the error message:

ServletException in: /article/content/form.jsp
No getter method for property journal_category of bean
org.apache.struts.taglib.html.BEAN

Really wish someone could help me out.

--- lover birds wrote:
> I did not get single reply, so thought of posting
> this mail again.
> I hope I am making some sense by asking this
> question.Please guide me ASAP as I am newbie and
> stuck very badly
> 
> lover birds wrote:
> 
> Hi folks,
> 
> I am getting this error.
> 
> "Cannot find bean org.apache.struts.taglib.html.BEAN
> in any scope"
> 
> I am trying something as follows:
> 
> input="/pages/count/List.jsp" path="/New"
> scope="request"/>
> 
> 
> content of List.jsp is
> 
> 
> 
> 
> 
> New.jsp is absolutely blank:
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> Click on the New image of the List JSP gives me this
> error.
> 
> I would appreciate help in this regard.
> 
> I would like to know the best way to forward to a
> specific page on an image click.
> 
> 
> 
> 
> 
> ---------------------------------
> Do you Yahoo!?
> The New Yahoo! Shopping - with improved product
> search
> 
> ---------------------------------
> Do you Yahoo!?
> The New Yahoo! Shopping - with improved product
search


__________________________________
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search
http://shopping.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org



---------------------------------
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search

RE: Cannot find bean org.apache.struts.taglib.html.BEAN in any scope (URGENT)

Posted by David Friedman <hu...@ix.netcom.com>.
Did you add the methods:

getJournal_category() 
setJournal_category()

To the form used by the action which goes to that
page?

Regards,
David

-----Original Message-----
From: Caroline Jen [mailto:jiapei_jen@yahoo.com]
Sent: Thursday, October 23, 2003 12:58 AM
To: Struts Users Mailing List
Subject: Re: Cannot find bean org.apache.struts.taglib.html.BEAN in any
scope (URGENT)


I am also in trouble.  My problem is sort of related
to yours although not directly relevant.  I am also
looking for org.apache.struts.taglib.html.BEAN

I am trying to modify Ted Husted's artimus_1_1 example
-  I want to add one more property to his articleForm.

To submit an article in the artimus_1_1 example, his
form.jsp in the /article/content folder asks for
title, author, and article.  I inserted one more text
field:

<TR> 
<TD class="label" nowrap>Journal Category:</TD>
<TD class="input">
<html:text property="journal_category" size="30"
maxlength="75"/></TD>
</TR>

to indicate the academic field of the article.  I got
the error message:

ServletException in: /article/content/form.jsp
No getter method for property journal_category of bean
org.apache.struts.taglib.html.BEAN

Really wish someone could help me out.

--- lover birds <ua...@yahoo.com> wrote:
> I did not get single reply, so thought of posting
> this mail again.
> I hope I am making some sense by asking this
> question.Please guide me ASAP as I am newbie and
> stuck very badly
> 
> lover birds <ua...@yahoo.com> wrote:
> 
> Hi folks,
> 
> I am getting this error.
> 
> "Cannot find bean org.apache.struts.taglib.html.BEAN
> in any scope"
> 
> I am trying something as follows:
> 
> input="/pages/count/List.jsp" path="/New"
> scope="request"/>
> 
> 
> content of List.jsp is
> 
> 
> 
> 
> 
> New.jsp is absolutely blank:
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> Click on the New image of the List JSP gives me this
> error.
> 
> I would appreciate help in this regard.
> 
> I would like to know the best way to forward to a
> specific page on an image click.
> 
> 
> 
> 
> 
> ---------------------------------
> Do you Yahoo!?
> The New Yahoo! Shopping - with improved product
> search
> 
> ---------------------------------
> Do you Yahoo!?
> The New Yahoo! Shopping - with improved product
search


__________________________________
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search
http://shopping.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


Re: Cannot find bean org.apache.struts.taglib.html.BEAN in any scope (URGENT)

Posted by Caroline Jen <ji...@yahoo.com>.
I am also in trouble.  My problem is sort of related
to yours although not directly relevant.  I am also
looking for org.apache.struts.taglib.html.BEAN

I am trying to modify Ted Husted's artimus_1_1 example
-  I want to add one more property to his articleForm.

To submit an article in the artimus_1_1 example, his
form.jsp in the /article/content folder asks for
title, author, and article.  I inserted one more text
field:

<TR> 
<TD class="label" nowrap>Journal Category:</TD>
<TD class="input">
<html:text property="journal_category" size="30"
maxlength="75"/></TD>
</TR>

to indicate the academic field of the article.  I got
the error message:

ServletException in: /article/content/form.jsp
No getter method for property journal_category of bean
org.apache.struts.taglib.html.BEAN

Really wish someone could help me out.

--- lover birds <ua...@yahoo.com> wrote:
> I did not get single reply, so thought of posting
> this mail again.
> I hope I am making some sense by asking this
> question.Please guide me ASAP as I am newbie and
> stuck very badly
> 
> lover birds <ua...@yahoo.com> wrote:
> 
> Hi folks,
> 
> I am getting this error.
> 
> "Cannot find bean org.apache.struts.taglib.html.BEAN
> in any scope"
> 
> I am trying something as follows:
> 
> input="/pages/count/List.jsp" path="/New"
> scope="request"/>
> 
> 
> content of List.jsp is
> 
> 
> 
> 
> 
> New.jsp is absolutely blank:
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> Click on the New image of the List JSP gives me this
> error.
> 
> I would appreciate help in this regard.
> 
> I would like to know the best way to forward to a
> specific page on an image click.
> 
> 
> 
> 
> 
> ---------------------------------
> Do you Yahoo!?
> The New Yahoo! Shopping - with improved product
> search
> 
> ---------------------------------
> Do you Yahoo!?
> The New Yahoo! Shopping - with improved product
search


__________________________________
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search
http://shopping.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


Re: Cannot find bean org.apache.struts.taglib.html.BEAN in any scope (URGENT)

Posted by lover birds <ua...@yahoo.com>.
I did not get single reply, so thought of posting this mail again.
I hope I am making some sense by asking this question.Please guide me ASAP as I am newbie and stuck very badly

lover birds <ua...@yahoo.com> wrote:

Hi folks,

I am getting this error.

"Cannot find bean org.apache.struts.taglib.html.BEAN in any scope"

I am trying something as follows:

input="/pages/count/List.jsp" path="/New" scope="request"/>


content of List.jsp is





New.jsp is absolutely blank:













Click on the New image of the List JSP gives me this error.

I would appreciate help in this regard.

I would like to know the best way to forward to a specific page on an image click.





---------------------------------
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search

---------------------------------
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search

RE: Cannot find bean org.apache.struts.taglib.html.BEAN in any scope

Posted by David Friedman <hu...@ix.netcom.com>.
Dear Anonymous (kidding),

If you want an HTML Image button to jump to New.jsp,
why don't you simply go into /pages/count/List.jsp
directly using the onclick function of the and <img>
tag or the <html:img ... /> tag?

Examples:
<html:img src="/images/somepic.jpg"
onclick="window.location='http://www.bu.edu'"/>

In your case the onclick might be:

<html:img src="/images/somepic.jpg"
onclick="window.location='http://myhost.com/pages/count/List.jsp'"/>

OR perhaps an action that hides /pages/count/List.jsp:

<html:img src="/images/somepic.jpg"
onclick="window.location='http://myhost.com/someApp/someAction.do'"/>

Regards,
David

-----Original Message-----
From: lover birds [mailto:uareformi@yahoo.com]
Sent: Thursday, October 23, 2003 12:50 AM
To: Struts Users Mailing List
Subject: RE: Cannot find bean org.apache.struts.taglib.html.BEAN in any
scope


Hi David,

Thanx for the reply and suggestion, I would change it to my real name.

Basically I wanted to handle the  onclick event of image(a button) on the
List.jsp and direct it to New.jsp.
I am not sure how to do it using struts, so could you suggest me the best
way to do so.

David Friedman <hu...@ix.netcom.com> wrote:
Dear "lover birds" (do you have a real name you can sign in your email(s)
?),

You didn't list 'validate="true"' in your declaration. Why?
Did you not customize the form validation so it will bounce back to
/pages/count/List.jsp for input? Does your script actually bounce back to
that page if you go directly to /pages/count/New.jsp directly in a new
browser?

Regards,
David

P.S. I read your current email but chose to reply to this older one from
earlier today because it included the example JSP's and action declarations
so you can see what I'm talking about in the above notes.

-----Original Message-----
From: lover birds [mailto:uareformi@yahoo.com]
Sent: Wednesday, October 22, 2003 5:59 AM
To: struts-user@jakarta.apache.org
Subject: Cannot find bean org.apache.struts.taglib.html.BEAN in any
scope



Hi folks,

I am getting this error.

"Cannot find bean org.apache.struts.taglib.html.BEAN in any scope"

I am trying something as follows:

input="/pages/count/List.jsp" path="/New" scope="request"/>


content of List.jsp is





New.jsp is absolutely blank:













Click on the New image of the List JSP gives me this error.

I would appreciate help in this regard.

I would like to know the best way to forward to a specific page on an image
click.





---------------------------------
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


---------------------------------
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


RE: Cannot find bean org.apache.struts.taglib.html.BEAN in any scope

Posted by lover birds <ua...@yahoo.com>.
Hi David,
 
Thanx for the reply and suggestion, I would change it to my real name.
 
Basically I wanted to handle the  onclick event of image(a button) on the List.jsp and direct it to New.jsp.
I am not sure how to do it using struts, so could you suggest me the best way to do so.

David Friedman <hu...@ix.netcom.com> wrote:
Dear "lover birds" (do you have a real name you can sign in your email(s)
?),

You didn't list 'validate="true"' in your declaration. Why?
Did you not customize the form validation so it will bounce back to
/pages/count/List.jsp for input? Does your script actually bounce back to
that page if you go directly to /pages/count/New.jsp directly in a new
browser?

Regards,
David

P.S. I read your current email but chose to reply to this older one from
earlier today because it included the example JSP's and action declarations
so you can see what I'm talking about in the above notes.

-----Original Message-----
From: lover birds [mailto:uareformi@yahoo.com]
Sent: Wednesday, October 22, 2003 5:59 AM
To: struts-user@jakarta.apache.org
Subject: Cannot find bean org.apache.struts.taglib.html.BEAN in any
scope



Hi folks,

I am getting this error.

"Cannot find bean org.apache.struts.taglib.html.BEAN in any scope"

I am trying something as follows:

input="/pages/count/List.jsp" path="/New" scope="request"/>


content of List.jsp is





New.jsp is absolutely blank:













Click on the New image of the List JSP gives me this error.

I would appreciate help in this regard.

I would like to know the best way to forward to a specific page on an image
click.





---------------------------------
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


---------------------------------
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search

RE: Cannot find bean org.apache.struts.taglib.html.BEAN in any scope

Posted by David Friedman <hu...@ix.netcom.com>.
Dear "lover birds" (do you have a real name you can sign in your email(s)
?),

You didn't list 'validate="true"' in your <action..../> declaration. Why?
Did you not customize the form validation so it will bounce back to
/pages/count/List.jsp for input?  Does your script actually bounce back to
that page if you go directly to /pages/count/New.jsp directly in a new
browser?

Regards,
David

P.S. I read your current email but chose to reply to this older one from
earlier today because it included the example JSP's and action declarations
so you can see what I'm talking about in the above notes.

-----Original Message-----
From: lover birds [mailto:uareformi@yahoo.com]
Sent: Wednesday, October 22, 2003 5:59 AM
To: struts-user@jakarta.apache.org
Subject: Cannot find bean org.apache.struts.taglib.html.BEAN in any
scope



Hi folks,

I am getting this error.

"Cannot find bean org.apache.struts.taglib.html.BEAN in any scope"

I am trying something as follows:

  <action forward="/pages/count/New.jsp"
   input="/pages/count/List.jsp" path="/New" scope="request"/>


content of List.jsp is

  <html:link action="New.do">
     <html:img src="../images/new.gif" width="62" height="19" />
   </html:link>

New.jsp is absolutely blank:

<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>

<html>

<head>

<title>

New

</title>

</head>

Click on the New image of the List JSP gives me this error.

I would appreciate help in this regard.

I would like to know the best way to forward to a specific page on an image
click.





---------------------------------
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


Cannot find bean org.apache.struts.taglib.html.BEAN in any scope

Posted by lover birds <ua...@yahoo.com>.
Hi folks,

I am getting this error.

"Cannot find bean org.apache.struts.taglib.html.BEAN in any scope"

I am trying something as follows:

  <action forward="/pages/count/New.jsp"
   input="/pages/count/List.jsp" path="/New" scope="request"/>


content of List.jsp is

  <html:link action="New.do">
     <html:img src="../images/new.gif" width="62" height="19" />
   </html:link>

New.jsp is absolutely blank:

<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>

<html>

<head>

<title>

New

</title>

</head>

Click on the New image of the List JSP gives me this error.

I would appreciate help in this regard.

I would like to know the best way to forward to a specific page on an image click.


 


---------------------------------
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search