Struts2+json question

2010-08-05 Thread red phoenix
I use struts2.1.8 and extjs3.2, I make a login page, if login failed,it will alert a message and it will still stay this login page; if it login success,it will go to another new page,such as main.jsp page My login page is follows: var win=new Ext.Window({ el:'hello-win', items:

Struts 2 + Spring 2 + JPA + AJAX question

2010-07-12 Thread red phoenix
I want to use Struts 2 + Spring 2 + JPA + AJAX,I find it as following url: http://struts.apache.org/2.1.8/docs/struts-2-spring-2-jpa-ajax.html When I try to download this code,like follows: Get the

How to get s:select id and name under struts2 action?

2010-03-22 Thread red phoenix
I have a jsp,it contains a s:select,like follows: s:select name=test list=#request.testList listKey=id listValue=tname size=6 cssClass=tbcell/ When this jsp submit,it will submit to a struts2 action,I want to know how to get all id and name of s:select and how to get selected id and name of

legend don't work under s:form of struts2

2010-03-13 Thread red phoenix
I want to use legend tag under struts2,I set legend css like follows: form{ padding:10px; margin:0 auto; } form#form legend { border:1px solid #e8e7e1; background:#fff url(../img/form_red.gif) repeat-x center left; color:#a43708; } following code can run well: h3 id=adduser style=width:100%;Add

struts2 show question

2009-04-20 Thread red phoenix
I have a table named mytable,it has two cols,col1 and col2,the data are col1 col2 --- John 24 Kate 18 hibernate xml file is follows: hibernate-mapping auto-import=false class name=mytable table=mytable id name=col1 column=col1 type=java.lang.String generator

How to set 'pager.offset' in struts2 action?

2009-03-09 Thread red phoenix
I use struts2 and Pager Taglib2.0, in jsp file,it has a parameter,like follows: input type=hidden name=pager.offset value=%= offset % when I run above code,it raise warning message: Warn: ParametersInterceptor - [setParameters]: Unexpected Exception caught setting 'pager.offset' on 'class

pager question in struts2+Pager Taglib2

2009-02-02 Thread red phoenix
I use struts2.0.14 and Pager Taglib2.0, I want to use Pager Taglib2.0 in struts2 In action file public String search() throws Exception{ System.out.println(call search); request.setAttribute(index,center); request.setAttribute(pageUrl,/test/search.action); return SUCCESS; }

How to decorate s:file button

2008-12-30 Thread red phoenix
My Struts is 2.0.14,I use s:file,like follows: s:file name=upload label=select file accept=text/*/ Then there is a upload button,but this button is not pretty.I have two question: 1) How to decorate this button,such as a image button? 2) when I click this button,how to check this upload file

Re: org.apache.struts2.dispatcher.StrutsRequestWrapper cannot be cast to org.apache.struts2.dispatcher.multipart.MultiPartRequestWrapper

2008-12-16 Thread red phoenix
puzzled with why raise above error. I don't find the different between my code and http://struts.apache.org/2.0.14/docs/how-do-we-upload-files.html. Where wrong with my code? On Tue, Dec 16, 2008 at 11:13 PM, Dave Newton newton.d...@yahoo.com wrote: --- On Tue, 12/16/08, red phoenix wrote

org.apache.struts2.dispatcher.StrutsRequestWrapper cannot be cast to org.apache.struts2.dispatcher.multipart.MultiPartRequestWrapper

2008-12-16 Thread red phoenix
I use struts2.0.14,I want to use upload function,my jsp file is follows: s:form enctype=multipart/form-data method=post s:file name=upload label=File accept=text/* cssStyle=width:260px/ ... s:form struts action is follows: public String uploadFile() throws Exception{ MultiPartRequestWrapper

Re: org.apache.struts2.dispatcher.StrutsRequestWrapper cannot be cast to org.apache.struts2.dispatcher.multipart.MultiPartRequestWrapper

2008-12-16 Thread red phoenix
are not the same machine. How to do it? An example is better. phoenix On Tue, Dec 16, 2008 at 11:32 PM, Dave Newton newton.d...@yahoo.com wrote: Use the *preferred* method, the interceptor. I haven't looked in to what caused the breaking change. Dave --- On Tue, 12/16/08, red phoenix rodphoe...@gmail.com

Re: org.apache.struts2.dispatcher.StrutsRequestWrapper cannot be cast to org.apache.struts2.dispatcher.multipart.MultiPartRequestWrapper

2008-12-16 Thread red phoenix
interceptor? phoenix On Tue, Dec 16, 2008 at 11:55 PM, Dave Newton newton.d...@yahoo.com wrote: --- On Tue, 12/16/08, red phoenix wrote: It says: Ensure that {{fileUpload }} Interceptor is included in the Action's stack. .*The default stack already includes {{fileUpload }}.* I don't know how

Unexpected Exception caught setting 'uploadFileContentType'

2008-12-14 Thread red phoenix
I want to upload a file in struts2,my jsp file is follows: html:html body s:form enctype=multipart/form-data method=post action=upload.action s:file id=uploadFile name=uploadFile accept=text/*/ input type=submit /s:form /body /html:html my action is follows: import java.io.File; private File

getOutputStream() has already been called for this response

2008-12-10 Thread red phoenix
I use struts2.0.11,I want to show a picture by struts action,like follows: public String showphoto() throws Exception{ response=ServletActionContext.getResponse(); response.setContentType(image/png); ... InputStream in = picture.getBinaryStream(); OutputStream out =

how to use pager tag in struts2?

2008-08-19 Thread red phoenix
I want to use Pager Tag Library2.0 in struts2,I set maxPageItems under struts2.0 action,like follows: request.setAttribute(maxPageItems,10); return SUCCESS; then I use maxPageItems in JSP page,like follows: pg:pager items=50 index=center maxPageItems=${request.maxPageItems}

struts2 s:select question

2008-03-02 Thread red phoenix
I use struts2.0.11, I use Hibernate to get data and put it into attribute in struts2 action,like follows: public String show() throws Exception{ request=ServletActionContext.getRequest(); List myList=this.getHibernateTemplate().find(from test.MyModel); request.setAttribute(myList,myList);

struts2 s:if and displaytag question

2008-02-19 Thread red phoenix
I use Struts2 and displaytag, In testList,there is a abc attribute,it contains data like english,france,when abc=english,I want to show En,else show Eu,my code is follows: display:table name=testList id=element size=6 display:column property=abc title=def s:if test= #element.abc=='english'

Warn: No configuration found for the specified action under struts2.0.11

2007-11-20 Thread red phoenix
I have some configure,and it runs well under struts2.0.9,but it raise warning under struts2.0.11,my files are follows: /*struts.xml*/ ?xml version=1.0 encoding=UTF-8 ? !DOCTYPE struts PUBLIC -//Apache Software Foundation//DTD Struts Configuration 2.0//EN

Error: ParametersInterceptor - [setParameters]

2007-09-26 Thread red phoenix
I use struts2.0.9 and displaytag,xwork-2.0.4.jar,when I click next page of displaytag,it will raise flowing warning: Warn: ParametersInterceptor - [setParameters]: Unexpected Exception caught setting 'd-1332698-p' on 'class Test.TestAction: Error setting expression 'd-1332698-p' with value

Warn: Parameters: Invalid chunk ignored

2007-09-23 Thread red phoenix
I use Tomcat6.0.14 and struts2,I have a jsp page,and there is a button in it,when I click this button,it will call Javascript,and redirect another page,my code is follows: ... functioin test(){ document.forms[0].action=a.do; document.forms[0].submit(); } ... s:form table tda

How to get directory information in struts2 action?

2007-08-19 Thread red phoenix
I want to know how to get directory information in struts2 action,when I run following action: http://localhost:8080/struts2-blank-2.0.9/example/HelloWorld.action I want to get the path value http://localhost:8080/struts2-blank-2.0.9 in HelloWorld.action,such as: public String execute() throws

Re: How to make initialize with struts2 action?

2007-08-16 Thread red phoenix
if this is what you are after though Why do you want to do this ? Leon red phoenix wrote: If I use no-argument constructor,how can i do to initialize some information? Thanks On 8/16/07, Rec Floyd [EMAIL PROTECTED] wrote: Hey,red.In my opinion, to use struts, you have to supply

Re: How to make initialize with struts2 action?

2007-08-16 Thread red phoenix
://struts.apache.org/2.x/docs/spring-plugin.html Nils-H On 8/16/07, red phoenix [EMAIL PROTECTED] wrote: I know your meaning,but the question I want to Initialize in struts action,not in common class,because I want to get WebApplicationContext in struts action,and then I will transfer WebApplicationContext

How to make initialize with struts2 action?

2007-08-15 Thread red phoenix
For general Java class,we can make construction function,like this: public class test{ String a; public test(String a){ this.a=a; } } I don't know if I can do it like above code under struts2 action,for some reason,I want to initialize some variable and assign some value to it,like

Re: How to make initialize with struts2 action?

2007-08-15 Thread red phoenix
If I use no-argument constructor,how can i do to initialize some information? Thanks On 8/16/07, Rec Floyd [EMAIL PROTECTED] wrote: Hey,red.In my opinion, to use struts, you have to supply a no-argument constructor.That is the point.

how to include struts by using jsp:include page

2007-07-11 Thread red phoenix
I want to use jsp:include to load my struts file,such as: jsp:include page=/a1.do / jsp:include page=/a2.do / but when I run this jsp file,http://localhost:8080/a.jsp,it raise error,it shows it can't find a1.do and a2.do,but when I write follows in IE, http://localhost:8080/a1.do, it

Re: how to include struts by using jsp:include page

2007-07-11 Thread red phoenix
,like follows: c:import url= http://localhost:8080/struts2-blank-2.0.8/example/HelloWorld.action/ I only want to use relative path,not absolute path,I don't know why raise above error,and how to correct it ? Thanks On 7/12/07, Michael Jouravlev [EMAIL PROTECTED] wrote: On 7/11/07, red phoenix

How to set attribute of s:textfield

2007-05-12 Thread red phoenix
I read document from struts2 and I know s:textfield has label,name,cssStyle,cssClass,so I use s:textfield as follows: s:textfield label=Your First Name name=Fname cssStyle=test cssClass=test I want to set label Your First Name as red color and font size is 6,but when I execute above code,I found

Struts2 character code question

2007-05-08 Thread red phoenix
I have set my all files with UTF-8 format,so I set URIEncoding parameter in server.xml in tomcat6.0.10,like follows: Connector port=8080 protocol=HTTP/1.1 maxThreads=150 connectionTimeout=2 redirectPort=8443 URIEncoding=UTF-8/ Then I write a JSP file like follows:

Re: Struts2 character code question

2007-05-08 Thread red phoenix
I tried follows in test.do: String name=request.getParameter(Name); System.out.println(new String(name.getBytes(UTF-8), gb2312)) it still show [EMAIL PROTECTED],Why? On 5/8/07, Christopher Schultz [EMAIL PROTECTED] wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Red, red phoenix wrote

Re: Struts2 character code question

2007-05-08 Thread red phoenix
and destroy the original message without making a copy. Thank you. - Original Message - From: red phoenix [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Tuesday, May 08, 2007 8:47 PM Subject: Re: Struts2 character code question I tried follows in test.do: String

Ajax can't receive Chinese code from action of struts2

2007-04-28 Thread red phoenix
when ajax receive information which include Chinese code from action of Struts2,ajax will show chinese code into confusion code,but if ajax receive information which include Chinese code from jsp, ajax will show correct Chinese code.I don't know why raise this error! How to correct it? My code

How to realize ajax in struts2

2007-04-24 Thread red phoenix
I want to use ajax within Struts to realize following function,there is a textfield an a submit button which use register a username in a JSP page,then you can put you name into textfield and click register button,then will call ajax to search name is exist,if exist,there will be a message behind

Could not load 'dojo.widget.html.Tooltip':last tried '__package__.js'

2007-04-23 Thread red phoenix
I want to use ajax in struts2,but when run my code like http://localhost:8080/test/index.html,it raise following Javascript error: Line:95 Char:1 Error:Could not load 'dojo.widget.html.Tooltip':last tried '__package__.js' Code:0

How to set filter in Struts2?

2007-04-19 Thread red phoenix
I want to set a filter,then I set different character code by this filter,such when a request from a1.action,I will set this character code is UTF-8,a request from a2.action,I will set this character code is ISO88591,and so on.I don't know how to realize above function in filter? Anybody could

Re: How to set filter in Struts2?

2007-04-19 Thread red phoenix
Would you give me a simple code for it? On 4/20/07, Drew Kutcharian [EMAIL PROTECTED] wrote: Can you use different filters/filter mappings for different URL patterns? Drew Kutcharian Venarc Inc. www.venarc.com - Original Message From: red phoenix [EMAIL PROTECTED] To: Struts

why Struts2 can't receive Jsp variable value by using Ajax1.2?

2007-02-09 Thread red phoenix
I have a text area and a text link in a jsp page,when I click this text link,I will call struts2 action by using ajax,like follows: /*-jsp page-*/ html script type=text/javascript var http = getHttpObject(); function getHttpObject(){ var xmlhttp = false; if(window.XMLHttpRequest){

How to use s:tree.. /

2007-01-24 Thread red phoenix
I want to use s:tree id=... rootNode=... nodeIdProperty=... nodeTitleProperty=... childCollectionProperty=... /,I read treeExampleDynamic.jsp of struts2 document,like follows: script function treeNodeSelected(nodeId) { dojo.io.bind({ url: s:url

java.io.WriteAbortedException

2006-12-25 Thread red phoenix
When I start tomcat6 and struts2,sometimes when I start tomcat,it will raise following error,but sometimes when I start tomcat6,it don't raise any error! I am puzzled with it for a very long time!!! Anyone could tell the reason and how to solve it? Error information is following: Exception

bean method don't make function in Struts2

2006-12-19 Thread red phoenix
I use struts2 s:bean,like follows: ---SimpleCounter--- package test; public class SimpleCounter{ String foo; public void setFoo(String foo){ System.out.println(set foo=+foo); this.foo=foo; } public String getFoo(){ System.out.println(get foo=+foo); return foo; } } ---test.jsp--- %@ taglib

Re: where to download struts2.0 examples files?

2006-12-19 Thread red phoenix
-Original Message- From: red phoenix [mailto:[EMAIL PROTECTED] Sent: 19. joulukuuta 2006 9:49 To: Struts Users Mailing List Subject: where to download struts2.0 examples files? In struts doc,I often see org.apache.struts2.example.*,I want to know where I can download the example fiels

s:if in Struts2

2006-12-18 Thread red phoenix
I put a String into a session,and I use s:if to determine the session if it is exist,if exist,show OK,if not exist,it shows error,but when I run it,it shows error,I don't know why don't show OK? How to correct to show OK? my code is follows: %@ page contentType=text/html; charset=UTF-8 % %@

bean:write in struts2

2006-12-18 Thread red phoenix
I want to change my code from struts1 to struts2,I use displaytag and bean:write to show following code,it can run well,bean:write name=element property=ID/ will show 1,2, %@ taglib uri=/struts-tags prefix=s % display:table name=testList export=false sort=external defaultsort=1 pagesize=2

where to download struts2.0 examples files?

2006-12-18 Thread red phoenix
In struts doc,I often see org.apache.struts2.example.*,I want to know where I can download the example fiels?

logic:present in struts2

2006-12-17 Thread red phoenix
I want to realize logic:present in Struts2,when session attribute is exist,it show login,if it is not exist,it shows not login,like follows: logic:present name=test login /logic:present logic:notPresent name=test not login /logic:notPresent I don't know how to use logic:present in

struts.i18n.encoding

2006-12-14 Thread red phoenix
I want to set other country language character set,I know I should set web.xml with struts.i18n.encoding=... but I don't know the value which struts.i18n.encoding permited,anyone could give me a character list of struts.i18n.encoding? Thanks

struts2 web.xml question

2006-12-13 Thread red phoenix
I have a filter configure question about struts2,i want to filter character code in web.xml file,I know how to configure it in struts 1.3, C:\tomcat\webapps\exercise\WEB-INF\web.xml ... filter filter-nameSet Character Encoding/filter-name

struts2.0 action question

2006-12-13 Thread red phoenix
I am puzzled with struts2.0 action file,my files are follows: configure file is follows action name=createRoom class=crudRoomAction method=create result name=read/chat/read.jsp/result result name=write/chat/write.jsp/result /action action file is follows: public String execute() throws

struts2.0 question

2006-12-11 Thread red phoenix
I have a question about Struts 2.0 Action,I find Action will extends ActionSupport,like follows: public class GetUpdatedHangmanAction extends ActionSupport implements SessionAware { private static final long serialVersionUID = 5506025785406043027L; . I am puzzled with variable

how to learn Struts 2

2006-12-04 Thread red phoenix
I am a newer of Struts 2,I find my application of Struts1 are can't run under Struts 2.I want to know Struts 2,but I don't know how to learn Struts2,would you give me some advice or material to learn? Thanks

org.apache.commons.validator not exist

2006-11-29 Thread red phoenix
I compile my Java file,but it raise error:org.apache.commons.validator not found,I guess I must lost a jar file,but I don't know which jar I lost,anyone could tell me which jar I need? Thanks.

How to realize print function

2006-11-01 Thread red phoenix
I want to realize print function in Struts,when click a button in jsp page,it will print part of screen information in Printer. I know javascript: window.print() can realize print function,but it don't fit me,because window.print() will print all screen information.I know another method,it will

Struts Encode question

2006-10-05 Thread red phoenix
I want to get a value from a JSP in Action,like follows: /*jsp*/ %@ page contentType=text/html;charset=gb2312 % html:text property=ex/ And I input a Chinese Word in ex area,then I get the ex value from a Action,like follows: /*Action*/ public ActionForward execute(ActionMapping

compile getDataSource error in Action

2006-09-28 Thread red phoenix
I use JDK1.6 and Struts1.3.5,I use Javac to compile a Action file,like follows: javac xxxAction.java but when I compile it,it raise follows error: xxxAction.java:31: Can't find symbol symbol: method getDataSource(javax.servlet.http.HttpServletRequest, java.lang.String) location: class xxxAction

Struts validation question

2006-07-04 Thread red phoenix
I want to use struts validation,when field is invalidate,my program can raise information,like follows: Username is required. Password is required. Phone Number is required. I know it's server-side validation,I want to use client-side validation,so I put some code in my JSP files: /html:form

[Default Bundle] Missing Field

2006-06-29 Thread red phoenix
I use JDK1.6,tomcat5.0.28,Struts1.2.9,I run Bundles Example Formhttp://localhost:8080/struts-examples/validator/viewBundleExamples.do of struts-examples.war,when I click Save button,I find the Field Address say [Other Bundle]Missing Field: Address(Other Bundle) Why raise above error? How to

Null Exception in ActionForm

2006-05-19 Thread red phoenix
I have two jsp file,such a.jsp and b.jsp,one Action file and one Form file,I want to from a.jsp to call Action file,and I set value of Form in Action file,and return to b.jsp,and show value in b.jsp,so I can modify this value in b.jsp my struts-config.xml is follows: form-beans form-bean

Download question

2006-04-05 Thread red phoenix
I want to realize download function in struts,and I will put some file url in JSP file,when click one of the file url,this file will be download.Dostruts or some taglib support download function? Thanks in advance

Is there a struts Taglib document?

2006-04-04 Thread red phoenix
Is there a struts taglib document about html:??,bean:???,logic:???,the chm file form is better. If you have it,please give it to me. Thanks!

Servlet action is not available

2006-04-03 Thread red phoenix
My Struts is 1.2.9,and tomcat is 5.5.15,and JDK is 1.5,I want to use Struts Datasource,my database is Microsoft Access 2000,and I have configured ODBC datasource in windows,when I run it, it raise follows error: type Status report message Servlet action is not available description The requested

Re: Servlet action is not available

2006-04-03 Thread red phoenix
javax.naming.NameNotFoundException: Name jdbc is not bound in this Context Why? Any idea will be appreciated! Best regards, On 4/4/06, Craig McClanahan [EMAIL PROTECTED] wrote: On 4/3/06, red phoenix [EMAIL PROTECTED] wrote: My Struts is 1.2.9,and tomcat is 5.5.15,and JDK is 1.5,I want

action not work

2006-04-03 Thread red phoenix
I have a submit button in A.jsp,and I want to submit to B.do from A.jsp,but when I click this submit button,it should submit to B.do and show some information on screen,but in fact it doesn't work,when I use http://localhost:8080/B.do, it can work.I don't know why it don't work from A.jsp to B.do?

How to configure Struts connection pool

2006-04-01 Thread red phoenix
I use struts-1.2.9,and want to configure a connection pool,so I configure struts-config.xml file struts-config data-source key=bb1 type=org.apache.commons.dbcp.BasicDataSource set-property property=driverClassName value= sun.jdbc.odbc.JdbcOdbcDriver / set-property property=url

Why struts can't use Tomcat5 connection pool?

2006-04-01 Thread red phoenix
I configure a connection pool in Tomcat5.5.12,like follows: Context path= docBase=/jsp-examples debug=5 reloadable=true crossContext=true Resource name=jdbc/bb1 auth=Container type=javax.sql.DataSource maxActive=100 maxIdle=30 maxWait=1 username=administrator password=123

Error while configure struts Datasource

2006-04-01 Thread red phoenix
I want to configure data source,I use Tomcat5.5.15 and struts-1.2.9,my database is Microsoft Access2000,my configure is follows: struts-config data-sources data-source type=org.apache.commons.dbcp.BasicDataSource set-property property=driverClassName

Re: How to configure Struts connection pool

2006-04-01 Thread red phoenix
this, DataSource db= getDataSource(request,key); This should work for you. Let me know if you still face any issues. Thanks, Tarun. On 4/1/06, red phoenix [EMAIL PROTECTED] wrote: I use struts-1.2.9,and want to configure a connection pool,so I configure struts-config.xml file

Re: migrate question from Struts 1.0.2 to Struts1.2.8

2006-02-28 Thread red phoenix
where error is my code? On 2/28/06, Laurie Harper [EMAIL PROTECTED] wrote: First things first: did you go through all the migration steps listed on the wiki for 1.0 - 1.2, 1.1 - 1.2.4, 1.2.4 - 1.2.7 and 1.2.7 - 1.2.8? L. red phoenix wrote: I have a simple Struts program,it can run well

Re: Cannot find ActionMappings or ActionFormBeans collection

2006-02-27 Thread red phoenix
for you! 2006/2/27, red phoenix [EMAIL PROTECTED]: I use Struts struts-1.2.8,when I execute my JSP file,it raise following error: javax.servlet.ServletException: Cannot find ActionMappings or ActionFormBeans collection org.apache.jasper.runtime.PageContextImpl.doHandlePageException

Cannot find message resources under key org.apache.struts.action.MESSAGE

2006-02-27 Thread red phoenix
I have configure my properties file,but when run,it raise error and say can't find message key,my files are follows: /*index.jsp*/ %@ taglib uri=http://struts.apache.org/tags-html; prefix=html % html:form method=post action=log .. html:errors property=logstime/ /html:form

Re: Cannot find ActionMappings or ActionFormBeans collection

2006-02-27 Thread red phoenix
=post action=/log try again? 2006/2/27, red phoenix [EMAIL PROTECTED]: I use html:form method=post action=log But it still raise same error. On 2/27/06, Denis Ling [EMAIL PROTECTED] wrote: html:form method=post action=log.do table ... /table /html:form You should

migrate question from Struts 1.0.2 to Struts1.2.8

2006-02-27 Thread red phoenix
I have a simple Struts program,it can run well in Struts1.0.2,then I migrate it to Struts1.2.8,this time I find index.jsp page shows well,but when I submit this page,it should redirect to show.jsp page and show something in it,but in fact it redirect an empty page,it show nothing,even no error in

Cannot find ActionMappings or ActionFormBeans collection

2006-02-26 Thread red phoenix
I use Struts struts-1.2.8,when I execute my JSP file,it raise following error: javax.servlet.ServletException: Cannot find ActionMappings or ActionFormBeans collection org.apache.jasper.runtime.PageContextImpl.doHandlePageException( PageContextImpl.java:858)

Re: html:errors question

2006-02-23 Thread red phoenix
; It should be name instead property Hope this will help Chandra -Original Message- From: red phoenix [mailto:[EMAIL PROTECTED] Sent: Thursday, February 23, 2006 12:48 PM To: Struts Users Mailing List Subject: html:errors question I have a JSP file,and I use html:errors in this page

Re: html:errors question

2006-02-23 Thread red phoenix
,and html:errors name=abc/ don't work. I am puzzled with it. On 2/23/06, Dave Newton [EMAIL PROTECTED] wrote: red phoenix wrote: I modify my code,like follows,this time it don't show any error,but when the content of text abc is '123',it's length isn't equals 10,so it should raise error

Re: html:errors question

2006-02-23 Thread red phoenix
taglib tld: %@ taglib uri=/WEB-INF/struts-html.tld prefix=html % then there shouldn't be any problem with the property attribute. If you're using a pre 1.0 version of struts I highly recommend you upgrade. Niall - Original Message - From: red phoenix [EMAIL PROTECTED] Sent

Re: html:errors question

2006-02-23 Thread red phoenix
See: http://www.niallp.pwp.blueyonder.co.uk/HelpTagsErrorsAndMessages.html Niall - Original Message - From: red phoenix [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Friday, February 24, 2006 2:30 AM Subject: Re: html:errors question Thanks Niall

html:errors question

2006-02-22 Thread red phoenix
I have a JSP file,and I use html:errors in this page,but it raise error,my code is follows: %@ taglib uri=/WEB-INF/struts-form.tld prefix=html % html head link rel=stylesheet href=style.css type=text/css /head html:errors/ html:form method=post action=log.do html:text property=abc /html:errors

Re: why my page can't redirect under Struts with Javascript?

2006-02-20 Thread red phoenix
I tried follows: function goURL(tmp){ document.forms[0].action=eval(/Log/log.do?action=First); document.forms[0].submit(); } and function goURL(tmp){ document.forms[0].action=eval(/log.do?action=First); document.forms[0].submit(); } My page also can't redirect! And I try function

Re: why my page can't redirect under Struts with Javascript?

2006-02-20 Thread red phoenix
PROTECTED] wrote: red phoenix wrote: I tried follows: function goURL(tmp){ document.forms[0].action=eval(/Log/log.do?action=First); document.forms[0].submit(); } and function goURL(tmp){ document.forms[0].action=eval(/log.do?action=First); document.forms[0].submit

why my page can't redirect under Struts with Javascript?

2006-02-19 Thread red phoenix
I use Javascript in Struts,like follows: script language=JavaScript function goURL(tmp){ alert(tmp); document.forms[0].action=/log.do?action=+eval(tmp); document.forms[0].submit(); } /script html:form method=post action=log.do html:link page=/log.do?action=FirstFirst Page/html:link html:select

Re: why my page can't redirect under Struts with Javascript?

2006-02-19 Thread red phoenix
: document.forms[0].action=/log.do?action=+eval(tmp); You'll need to prefix /log.do with your web context. Or you can use: html:rewrite page='/log.do' / in place of /log.do above. hope it helps. Saul - Original Message - From: red phoenix [EMAIL PROTECTED] To: user

Re: why my page can't redirect under Struts with Javascript?

2006-02-19 Thread red phoenix
with your web context. Or you can use: html:rewrite page='/log.do' / in place of /log.do above. hope it helps. Saul - Original Message - From: red phoenix [EMAIL PROTECTED] To: user@struts.apache.org Sent: Sunday, February 19, 2006 6:48 PM Subject: why my page can't redirect

Re: why my page can't redirect under Struts with Javascript?

2006-02-19 Thread red phoenix
it again with following manner. html:select property=pageID size=1 onchange=javascript:goURL( this.options[this.selectedIndex].value) option value=FirstFirst/option option value=SecondSecond/option option value=ThirdThird/option /html:select I hope it will work. On 2/20/06, red phoenix

Re: why my page can't redirect under Struts with Javascript?

2006-02-19 Thread red phoenix
= %=response.encodeURL(/Log/log.do)%; document.forms[0].action=url + ?action= + tmp; document.forms[0].submit(); } and try... On 2/20/06, red phoenix [EMAIL PROTECTED] wrote: I modify my Javascript like follows: function goURL(tmp){ document.forms[0].action=eval(/Log/log.do?action=First

Re: why my page can't redirect under Struts with Javascript?

2006-02-19 Thread red phoenix
can't redirect? On 2/20/06, raja sekar [EMAIL PROTECTED] wrote: try this function goURL(tmp){ var url = %=response.encodeURL(/Log/log.do)%; document.forms[0].action=url + ?action= + tmp; document.forms[0].submit(); } On 2/20/06, red phoenix [EMAIL PROTECTED] wrote: when I