html:img unexpected behaviour....
I have the following code on a jsp page: onmouseover, onmouseout, etc doesn't work when it comes to swapping the image, but that's the least of my worries at the minute (although I'd greatly appreciate some light being shed on that one...) The big question is, in Netscape 7.1 the behaviour is as I'd expect when I click on the image (i.e. the "mode" is set to "stop" in my form)I verify this by printing debug from the equivalent action class. On Internet Explorer, however, the value for "mode" doesn't change (to "stop" when onclick is invoked... why?!?! regards Leticia - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: help about struts
This is where I started: Read Struts In Action (Published by Manning) book. http://www.manning.com/husted/index.html Resources: http://jakarta.apache.org/struts/ http://jakarta.apache.org/index.html -Original Message- From: EROL TEZCAN [mailto:[EMAIL PROTECTED] Sent: 11 March 2004 10:11 To: [EMAIL PROTECTED] Subject: help about struts Hi , I want to work with struts. But i dont know where will I start first? What I need for working with struts? Where should I start first? Can I work struts on Resin , or only Tomcat? Which files needed to work struts.? Please help me ? Erol Tezcan - Do you Yahoo!? Yahoo! Search - Find what youre looking for faster. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: html:link action - how to append query string
No!! But it worked! You're a star! I owe you a beer or a tea (if you're not a drinker) :) thanks :) -Original Message- From: Hubert Rabago [mailto:[EMAIL PROTECTED] Sent: 27 February 2004 16:52 To: Struts Users Mailing List Subject: RE: html:link action - how to append query string Have you tried ? --- Leticia Golubov <[EMAIL PROTECTED]> wrote: > I just don't understand why the 3rd option doesn't work for me... > > I've tried all possible variations of it but I just can't seem to be able > to > parse > <%value%> to the query string... does anybody know why? > > so doesn't work nor > does > > regards > > -Original Message- > From: Paul, R. Chip [mailto:[EMAIL PROTECTED] > Sent: 27 February 2004 15:59 > To: 'Struts Users Mailing List' > Subject: RE: html:link action - how to append query string > > > You have I think three choices, in preferred order: > > 1. Use the paramName, paramScope, and paramProperty attributes of > > (see > http://jakarta.apache.org/struts/userGuide/struts-html.html#link) > This may not work with the page scoped variable defined the way you've > done it, I don't know. > > 2. Use Struts-EL and add ${value} into your link string > > 3. > I think your core problem is to pass an variable without the param > attributes you need to contstuct and send a URL, not the name of an action? > > > > -Original Message- > From: Leticia Golubov [mailto:[EMAIL PROTECTED] > Sent: Friday, February 27, 2004 9:50 AM > To: Struts User Mailing List > Subject: html:link action - how to append query string > > > I have a simple question, for a change... :) > > Given > > <% String value="some Value" %> > > and > > > > how do I append the java var 'value' to the end of the action? > > If I hardcode it, it works and the behaviour is as expected, i.e.: > > > > Note I have tried the following and failed: > > Also searched on internet but didn't find anything as yet... > > regards > > NOTE: I don't want to use > in > this instance... > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > __ Do you Yahoo!? Get better spam protection with Yahoo! Mail. http://antispam.yahoo.com/tools - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: html:link action - how to append query string
I just don't understand why the 3rd option doesn't work for me... I've tried all possible variations of it but I just can't seem to be able to parse <%value%> to the query string... does anybody know why? so doesn't work nor does mailto:[EMAIL PROTECTED] Sent: 27 February 2004 15:59 To: 'Struts Users Mailing List' Subject: RE: html:link action - how to append query string You have I think three choices, in preferred order: 1. Use the paramName, paramScope, and paramProperty attributes of (see http://jakarta.apache.org/struts/userGuide/struts-html.html#link) This may not work with the page scoped variable defined the way you've done it, I don't know. 2. Use Struts-EL and add ${value} into your link string 3. mailto:[EMAIL PROTECTED] Sent: Friday, February 27, 2004 9:50 AM To: Struts User Mailing List Subject: html:link action - how to append query string I have a simple question, for a change... :) Given <% String value="some Value" %> and how do I append the java var 'value' to the end of the action? If I hardcode it, it works and the behaviour is as expected, i.e.: Note I have tried the following and failed: in this instance... - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: html:link action - how to append query string
Yes, I've been trying solution number 3, but that doesn't work at all. The browser doesn't like and renders the link incorrectly. I'm now trying solution 1, as suggested, as below: ... I've tried different permutations to set the value for the row property, but had no success... I read the link but that wasn't helpful at all. What I mean is, it's not clear to me how to set the value... In the case above, the row is not being set. -Original Message- From: Paul, R. Chip [mailto:[EMAIL PROTECTED] Sent: 27 February 2004 15:59 To: 'Struts Users Mailing List' Subject: RE: html:link action - how to append query string You have I think three choices, in preferred order: 1. Use the paramName, paramScope, and paramProperty attributes of (see http://jakarta.apache.org/struts/userGuide/struts-html.html#link) This may not work with the page scoped variable defined the way you've done it, I don't know. 2. Use Struts-EL and add ${value} into your link string 3. mailto:[EMAIL PROTECTED] Sent: Friday, February 27, 2004 9:50 AM To: Struts User Mailing List Subject: html:link action - how to append query string I have a simple question, for a change... :) Given <% String value="some Value" %> and how do I append the java var 'value' to the end of the action? If I hardcode it, it works and the behaviour is as expected, i.e.: Note I have tried the following and failed: in this instance... - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
html:link action - how to append query string
I have a simple question, for a change... :) Given <% String value="some Value" %> and how do I append the java var 'value' to the end of the action? If I hardcode it, it works and the behaviour is as expected, i.e.: Note I have tried the following and failed: in this instance... - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Why can't I name a form using html:form?
Thanks Mark, I stumbled upon the answer to my question by accident, yesterday, which made me quite happy (must get out more)... :) cheers -Original Message- From: Mark Lowe [mailto:[EMAIL PROTECTED] Sent: 24 February 2004 12:41 To: Struts Users Mailing List Subject: Re: Why can't I name a form using html:form? styleId will give you a hook if you need have a way of drilling to something. But i'm guessing what your needs are. On 24 Feb 2004, at 13:38, Mark Lowe wrote: > the name of the form will be whatever you called it in struts config. > There was a name attribute in 1.0 but this became deprecated and now > must have been removed. > > I imagine that something will be done in newer releases (perhaps > already) to support strict xhtml and thus do away with rendering > name="" and use id="" instead or as well as name="". > > If you're trying to drill to the form in javascript best use > > onclick="alert( this.form.elements['myproperty'].value )" .. > > I you look at the rendered html you'll see that the name attribute is > rendered. > > > On 24 Feb 2004, at 13:30, Leticia Golubov wrote: > >> This is really winding me up... >> >> why does work >> >> but > name="deleteForm" >> type="org.apache.struts.action.DynaActionForm" >> > >> doesn't? >> >> Why can't I name my forms? I've looked at the documentation and the >> 'name' >> field doesn't even seem to exist, which leads me to believe I can't >> name >> forms using the html:form tag?! >> >> Is this a bug in Struts or have I missed something fundamental here? >> >> regards >> >> Leticia >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: ActionForward and onLoad()
Thanks everyone for help and suggestions... Sadly enough I was thinking about this last night, and it took me ages to go to sleep!!! What you suggest, Wendy, is what I should (and wanted to) do, but I just don't know how to... Basically, my action form has 4 modes: ADD, EDIT, DELETE and DISPLAY (the difference between EDIT and DISPLAY being that edit updates the result set and display just sets the values to edit in the DynaActionForm). Adding and deleting and editing works (worked, until I started displaying the values for that row) fine. I have this show_data.jsp page controlling the actions, such that when I want to delete i set the MODE property as below: (deletion is done via checkboxes) or " /> (which is set when I open 'edit_data.jsp', which is where I'm having problems - I open it by clicking on hyperlink) or (which is set when I open 'add_data.jsp', this gets opened when new button is hit and that invokes the New() function) (so, when I invoke mydataAction the relevant action is taken based on MODE.) The problem (and is purely due to my lack of experience with Javascript, I believe) begins when I want to edit. To edit the user clicks on a hyperlink on the main page. So, I have in my show_data.jsp something like: function New() { window.open("/pages/new.jsp","new", "width=380px,height=300px").focus(); } function Delete() { for( n=0; document.forms[0].elements[n] != null; n++) { if( document.forms[0].elements[n].type == "checkbox" ) { if( document.forms[0].elements[n].checked == true ) { document.forms[0].submit(); } } } } function Edit(row) { // How I was trying to do it: //editUrl = "pages/edit_data.jsp?EditRow=" + row; //window.open(editUrl, "scope", "width=380px,height=300px").focus(); // How I was doing it before and am now trying to do again... <% request.setAttribute(DiscoConstants.MODE, DiscoConstants.DISPLAY); // Note that I would also like to 'request.setAttribute(Constants.ROW, row);' but that fails // Is it possible to do that at all? // that's why I ended up doing things the other way, I couldn't get it working this way... %> documents.forms[0].submit(); } Maybe this is too complicated to work out over email... :-/ Another thing I might be doing wrong: Is equivalent to <% request.setAttribute(DiscoConstants.MODE, DiscoConstants.EDIT); %> My instincts led me to believe they are, but they might not be at all... -Original Message- From: Wendy Smoak [mailto:[EMAIL PROTECTED] Sent: 24 February 2004 18:09 To: Struts Users Mailing List Subject: RE: ActionForward and onLoad() > From: Leticia Golubov [mailto:[EMAIL PROTECTED] > I have a jsp page which I need to retrieve some values at > onLoad time, i.e.: > > all getValues() does is submit the form on this page which > sets a bunch of bean values for me to retrieve further down this page... Are you letting people visit the JSP directly? If you make them go through the Action first, then you can set up the values in advance, and they will be there in the session (or request) when you get to the JSP. But I didn't really understand what you're trying to do. Is it like a list of catalog items, and clicking on one of them opens a smaller window with details? -- Wendy Smoak Application Systems Analyst, Sr. ASU IA Information Resources Management - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: ActionForward and onLoad()
Yep, that's exactly what I'm trying to do. However, when user clicks on the html link I want some values to be set via an Action class. Once they are set I want to then retrieve them... I was initially accessing the data directly in the jsp but that was getting ugly (even though it worked). I think I lost the flow of data somewhere maybe... Or maybe I should set those attributes in the parent window... :-/ Although that's what I tried to do in the first place and it didn't work... -Original Message- From: Wendy Smoak [mailto:[EMAIL PROTECTED] Sent: 24 February 2004 18:09 To: Struts Users Mailing List Subject: RE: ActionForward and onLoad() > From: Leticia Golubov [mailto:[EMAIL PROTECTED] > I have a jsp page which I need to retrieve some values at > onLoad time, i.e.: > > all getValues() does is submit the form on this page which > sets a bunch of bean values for me to retrieve further down this page... Are you letting people visit the JSP directly? If you make them go through the Action first, then you can set up the values in advance, and they will be there in the session (or request) when you get to the JSP. But I didn't really understand what you're trying to do. Is it like a list of catalog items, and clicking on one of them opens a smaller window with details? -- Wendy Smoak Application Systems Analyst, Sr. ASU IA Information Resources Management - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: ActionForward and onLoad()
maybe you are right... What I'm trying to do is: I have some data which I'm displaying on a jsp page. This particular bit of work relates to editing a value being displayed on a table. When I click on the i retrieve the row number which I'm trying to edit, pass it to the EditAction class, which then retrieves that row's data from the result set, and sets the attributes (as defined in struts-config.xml) which I want to display. this Action then sets the mapping.findForward to that same page, so that I can then, edit the row. Initially I was doing all the work in the jsp file, but there was a lot of source code in there, so I decided to set some attributes using an Action class and then forwarding to the same page to display those values, ready for editing. This, of course, is also more appropriate, as it's a bad idea to have lots of Java code in the jsp page, and I have generally been keeping the Data access stuff at the back end (in the action classes and the data access classes). Once those values are shown, the user can edit them, and clicking on the OK button triggers another submit, which this time will once again set the attributes (I'm using DynaActionForm as my form) and then the back end updates the result set. All of this worked, until I decided to use attributes to send the data 'the other way'. Does the data only flow one way? I've been experiment with this all day and it does seem to work (well, it does set/retrieve the data correctly), the only problem is avoiding the form being submited on and on... I think I do understand the MVC architecture, what I'm not very good at is Javascript... -Original Message- From: Paul McCulloch [mailto:[EMAIL PROTECTED] Sent: 24 February 2004 18:06 To: 'Struts Users Mailing List' Subject: RE: ActionForward and onLoad() I'm a bit confused by what you are trying to do. > I have a jsp page which I need to retrieve some values at > onLoad time, i.e.: > If you need to retrieve values then do that in the Action and put them somewhere (e.g. a request scope attribute) so that you can access them in your jsp. It *sounds* like you could do with reading up on the basics of MVC in a web environment.. Paul > -Original Message- > From: Leticia Golubov [mailto:[EMAIL PROTECTED] > Sent: 24 February 2004 17:37 > To: Struts Users Mailing List > Subject: RE: ActionForward and onLoad() > > > I've tried > > window.open(editUrl, "scope", > "width=380px,height=300px").document.forms[0].submit(); > > but that doesn't behave very well... > > > -Original Message- > From: Leticia Golubov [mailto:[EMAIL PROTECTED] > Sent: 24 February 2004 17:09 > To: Struts User Mailing List > Subject: ActionForward and onLoad() > > > Hello Gurus, > > I'm in a bit of a predicament, and my lack of expertise in > Javascript and > Struts isn't helping... :( > > I have a jsp page which I need to retrieve some values at > onLoad time, i.e.: > > > all getValues() does is submit the form on this page which > sets a bunch of > bean values for me to retrieve further down this page... > > The problem is, on the Action for this form, I need to > redisplay the same > page... As you can imagine I find myself in a never ending > onload loop using > this setup of mine... > > Assuming anyone can understand my description of this > situation, my question > is: how can I get a page to execute the onload first time but > not to do it > second time around? Basically, I would like the onload for > that window to > be called from the parent window, but I've no idea how to do > it... I've > tried doing below from the parent window: > > window.open(editUrl, "scope", > "width=380px,height=300px").onload(document.forms[0].submit()); > > but that didn't work, i'd imagine that submitted the current > window, not the > one about to be opened. > > thanks in advance > > Leticia > > > > > > > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > ** Axios Email Confidentiality Footer Privileged/Confidential Information may be contained in this message. If you are not the addressee indicated in this message (or responsible for delivery of the message to such person), you may not copy or deliver this message to anyone. In such case, you should destroy this message, and
RE: ActionForward and onLoad()
I've tried window.open(editUrl, "scope", "width=380px,height=300px").document.forms[0].submit(); but that doesn't behave very well... -----Original Message- From: Leticia Golubov [mailto:[EMAIL PROTECTED] Sent: 24 February 2004 17:09 To: Struts User Mailing List Subject: ActionForward and onLoad() Hello Gurus, I'm in a bit of a predicament, and my lack of expertise in Javascript and Struts isn't helping... :( I have a jsp page which I need to retrieve some values at onLoad time, i.e.: all getValues() does is submit the form on this page which sets a bunch of bean values for me to retrieve further down this page... The problem is, on the Action for this form, I need to redisplay the same page... As you can imagine I find myself in a never ending onload loop using this setup of mine... Assuming anyone can understand my description of this situation, my question is: how can I get a page to execute the onload first time but not to do it second time around? Basically, I would like the onload for that window to be called from the parent window, but I've no idea how to do it... I've tried doing below from the parent window: window.open(editUrl, "scope", "width=380px,height=300px").onload(document.forms[0].submit()); but that didn't work, i'd imagine that submitted the current window, not the one about to be opened. thanks in advance Leticia - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
ActionForward and onLoad()
Hello Gurus, I'm in a bit of a predicament, and my lack of expertise in Javascript and Struts isn't helping... :( I have a jsp page which I need to retrieve some values at onLoad time, i.e.: all getValues() does is submit the form on this page which sets a bunch of bean values for me to retrieve further down this page... The problem is, on the Action for this form, I need to redisplay the same page... As you can imagine I find myself in a never ending onload loop using this setup of mine... Assuming anyone can understand my description of this situation, my question is: how can I get a page to execute the onload first time but not to do it second time around? Basically, I would like the onload for that window to be called from the parent window, but I've no idea how to do it... I've tried doing below from the parent window: window.open(editUrl, "scope", "width=380px,height=300px").onload(document.forms[0].submit()); but that didn't work, i'd imagine that submitted the current window, not the one about to be opened. thanks in advance Leticia - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Why can't I name a form using html:form?
This is really winding me up... why does work but doesn't? Why can't I name my forms? I've looked at the documentation and the 'name' field doesn't even seem to exist, which leads me to believe I can't name forms using the html:form tag?! Is this a bug in Struts or have I missed something fundamental here? regards Leticia - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: accessing dynamic radio and check boxes
Hi, you probably worked out how to do this already, but if you haven't here is how I did it: to check check boxes with one click, use this Javascript function, or similar: function CheckAll( form_number ) { for( n=0; document.forms[form_number].elements[n] != null; n++) { if( document.forms[form_number].elements[n].type == "checkbox" ) { document.forms[form_number].elements[n].checked = true; } } } HTH Leticia -Original Message- From: Claire Suttle [mailto:[EMAIL PROTECTED] Sent: 19 January 2004 22:12 To: [EMAIL PROTECTED] Subject: accessing dynamic radio and check boxes Hi, I'm using dyna action forms on a couple of my pages, and I'd like to know how to access the checkboxes and radio buttons via javascript. I know I need document.forms[0].something...but I don't know what I need next. What I want to be able to do is set the first radio button as selected by default, and allow one clicking on one checkbox to set all check boxes as selected. If someone could tell me what I need to use to be able to access these objects, that'd be great! Thanks, Claire - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Value attribute of
Have you tried the indexed tag? indexed Valid only inside of logic:iterate tag. If true then name of the html tag will be rendered as "id[34].propertyName". Number in brackets will be generated for every iteration and taken from ancestor logic:iterate tag. [RT Expr] as per http://jakarta.apache.org/struts/userGuide/struts-html.html#checkbox -Original Message- From: Raman [mailto:[EMAIL PROTECTED] Sent: 19 December 2003 07:02 To: Struts Users Mailing List Subject: Value attribute of Delete here i want value to be my "id" value of table.. i have this string in and assign this as still it is not working and giving me error this may be simple issue.. but i have tried and couln't find solution.. Pls help. Raman Garg
RE: Radio button CHECKED ???
what if the actionForm is DynaActionForm? I have an html:radio tag and can't seem to select one! :( so the tags Enable Disable will show radio buttons but none of them will be checked... -Original Message- From: Christian Bollmeyer [mailto:[EMAIL PROTECTED] Sent: 21 January 2004 19:49 To: Struts Users Mailing List Subject: Re: Radio button CHECKED ??? Am Mittwoch, 21. Januar 2004 11:17 schrieb Mauricio T. Ferraz: > Help!! > I have a actionForm with a boolean property and set and get > and in my jsp > > > > The radio checked always is the second, where is "false". How I put > the first to be checked when de jsp is loaded? Check the ActionForm: what is "propertyName" initialized to there? I bet it is "false". > thanks HTH, -- Chris. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: html:form/Submit question....
Yes, fair enough, but I should be able to refer to the form by name, surely? Anyway, I got that working (and I am naming the form), thanks everyone for the suggestions and help! :) -Original Message- From: Eric Bariaux [mailto:[EMAIL PROTECTED] Sent: 19 January 2004 17:26 To: 'Struts Users Mailing List' Subject: RE: html:form/Submit question No you don't always need the name of the form. If you're 100% sure you always have one form, something like document.forms[0].submit should work fine. > -Original Message- > From: Leticia Golubov [mailto:[EMAIL PROTECTED] > Sent: Monday, January 19, 2004 5:36 PM > To: Struts Users Mailing List > Subject: RE: html:form/Submit question > > Also, when I just use the tag: action="/addNewScope"> > the page loads correctly, once I use: > type="org.apache.struts.action.DynaActionForm" enctype="text/html"> > I get error below... > > but, of course, I need to name the form, otherwise I can't call it from > javascript... > > > -Original Message- > From: Leticia Golubov [mailto:[EMAIL PROTECTED] > Sent: 19 January 2004 16:16 > To: Struts Users Mailing List > Subject: RE: html:form/Submit question > > > mmm, think I'm nearly there, but getting Error Report: > > org.apache.jasper.JasperException: Cannot find bean under name > org.apache.struts.taglib.html.BEAN > at > org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.ja va > :2 > 54) > at > org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295) > at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) > at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > > which is rather strange considering I have a very similar piece of code > somewhere which runs perfectly fine... :-0 > > Here's the code which should, in theory, submit the addNewScope action > when > image is clicked on: > type="org.apache.struts.action.DynaActionForm" enctype="text/html"> >href="javascript:void(0);" > > onMouseOver="SwapImage('ok','../../images/button_ok_over.png');" > > onMouseDown="SwapImage('ok','../../images/button_ok_click.png');" > onMouseOut="SwapImage('ok','../../images/button_ok.png');" > > onMouseUp="SwapImage('ok','../../images/button_ok_over.png');"> >width="42" > height="23"> > > > > Note that somewhere else in the same app (and directory) I have another > jsp > using a DynaActionForm, so my app should be able to access that dynamic > Action form. Mind you, it's not even getting that far. The page is not > even loading the form controls... Been racking my brains for last couple > of > hours on this one, I've given up now... > > Any clues welcomed > > -Original Message- > From: Thomas Cornet [mailto:[EMAIL PROTECTED] > Sent: 19 January 2004 12:13 > To: Struts Users Mailing List > Subject: Re: html:form/Submit question > > > > > What I understand from your message is that you want to have a 'dynamic' > image as a button. An image that changes when the cursor is on the button, > or not, which can't be achieved by HTML. The only solution I see is using > JavaScript. I don't see why you don't want to use javascript because you > use it to change the button's image. > > Make something like > > onclick='JavaScript:document.forms[0].submit();' > href='Javascrip:void(0);' > onMouseOver.> > > Like this, the form is submitted normally. > > Thomas > > At 12:19 19/01/2004, you wrote: > >I have a form and my plan is to set all the fields (using DynaActionForm) > >when an ok 'button' is pressed, the problem is, I'm not using a 'submit' > >action to submit it, but an image, the code I have at the moment is: > > > >. lots of other code here > >[] > > . more code here basically, I want the action in the form > > (addNewScope) to be submited when I do onclick (where the question marks > > are). I don't want to use Javascript, I want call the action... I have > > done this before using but this is not what I'm trying to achieve here. > I > > think I might be confused... :-/ regards Leticia > > - To > > unsubscribe, e-mail: [EMAIL PROTECTED] For > > additional commands, e-mail: [EMAIL PROTECTED] > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: html:form/Submit question....
Also, when I just use the tag: the page loads correctly, once I use: I get error below... but, of course, I need to name the form, otherwise I can't call it from javascript... -Original Message- From: Leticia Golubov [mailto:[EMAIL PROTECTED] Sent: 19 January 2004 16:16 To: Struts Users Mailing List Subject: RE: html:form/Submit question mmm, think I'm nearly there, but getting Error Report: org.apache.jasper.JasperException: Cannot find bean under name org.apache.struts.taglib.html.BEAN at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:2 54) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) which is rather strange considering I have a very similar piece of code somewhere which runs perfectly fine... :-0 Here's the code which should, in theory, submit the addNewScope action when image is clicked on: Note that somewhere else in the same app (and directory) I have another jsp using a DynaActionForm, so my app should be able to access that dynamic Action form. Mind you, it's not even getting that far. The page is not even loading the form controls... Been racking my brains for last couple of hours on this one, I've given up now... Any clues welcomed -Original Message- From: Thomas Cornet [mailto:[EMAIL PROTECTED] Sent: 19 January 2004 12:13 To: Struts Users Mailing List Subject: Re: html:form/Submit question What I understand from your message is that you want to have a 'dynamic' image as a button. An image that changes when the cursor is on the button, or not, which can't be achieved by HTML. The only solution I see is using JavaScript. I don't see why you don't want to use javascript because you use it to change the button's image. Make something like Like this, the form is submitted normally. Thomas At 12:19 19/01/2004, you wrote: >I have a form and my plan is to set all the fields (using DynaActionForm) >when an ok 'button' is pressed, the problem is, I'm not using a 'submit' >action to submit it, but an image, the code I have at the moment is: > >. lots of other code here >[] > . more code here basically, I want the action in the form > (addNewScope) to be submited when I do onclick (where the question marks > are). I don't want to use Javascript, I want call the action... I have > done this before using but this is not what I'm trying to achieve here. I > think I might be confused... :-/ regards Leticia > - To > unsubscribe, e-mail: [EMAIL PROTECTED] For > additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: html:form/Submit question....
mmm, think I'm nearly there, but getting Error Report: org.apache.jasper.JasperException: Cannot find bean under name org.apache.struts.taglib.html.BEAN at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:2 54) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) which is rather strange considering I have a very similar piece of code somewhere which runs perfectly fine... :-0 Here's the code which should, in theory, submit the addNewScope action when image is clicked on: Note that somewhere else in the same app (and directory) I have another jsp using a DynaActionForm, so my app should be able to access that dynamic Action form. Mind you, it's not even getting that far. The page is not even loading the form controls... Been racking my brains for last couple of hours on this one, I've given up now... Any clues welcomed -Original Message- From: Thomas Cornet [mailto:[EMAIL PROTECTED] Sent: 19 January 2004 12:13 To: Struts Users Mailing List Subject: Re: html:form/Submit question What I understand from your message is that you want to have a 'dynamic' image as a button. An image that changes when the cursor is on the button, or not, which can't be achieved by HTML. The only solution I see is using JavaScript. I don't see why you don't want to use javascript because you use it to change the button's image. Make something like Like this, the form is submitted normally. Thomas At 12:19 19/01/2004, you wrote: >I have a form and my plan is to set all the fields (using DynaActionForm) >when an ok 'button' is pressed, the problem is, I'm not using a 'submit' >action to submit it, but an image, the code I have at the moment is: > >. lots of other code here >[] > . more code here basically, I want the action in the form > (addNewScope) to be submited when I do onclick (where the question marks > are). I don't want to use Javascript, I want call the action... I have > done this before using but this is not what I'm trying to achieve here. I > think I might be confused... :-/ regards Leticia > - To > unsubscribe, e-mail: [EMAIL PROTECTED] For > additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: html:form/Submit question....
Hiya, Yes, that works, but the input tag doesn't seem to support the onMouseOver, etc... so if I associate an input action with my image as below: that does submit it correctly... but I can't seem to be able to use my javascript functions here as onMouseOver, etc are not supported by the input tag. Of course the other solution would be to submit the form from a javascript function but that's far less elegant than the current solution... Any suggestions? Andrew, thanks for pointing me in the right direction. :) -Original Message- From: Andrew Hill [mailto:[EMAIL PROTECTED] Sent: 19 January 2004 11:31 To: Struts Users Mailing List Subject: RE: html:form/Submit question JavaScript goes here. I don't want to use Javascript, Um. I think you might be getting a little confused. I think I might be confused... :-/ Yes, didnt I just say that? hehe sorry, couldnt resist ;-> Sounds like what your after is the http://webdesign.about.com/library/tags/bltags-inputimage.htm struts tag: http://jakarta.apache.org/struts/userGuide/struts-html.html#image You will still need javascript to do the mouseover effects of course, but it should degrade ok for users without js (they will still be able to click it to submit). hth Andrew -Original Message- From: Leticia Golubov [mailto:[EMAIL PROTECTED] Sent: Monday, 19 January 2004 19:20 To: Struts User Mailing List Subject: html:form/Submit question I have a form and my plan is to set all the fields (using DynaActionForm) when an ok 'button' is pressed, the problem is, I'm not using a 'submit' action to submit it, but an image, the code I have at the moment is: . lots of other code here . more code here basically, I want the action in the form (addNewScope) to be submited when I do onclick (where the question marks are). I don't want to use Javascript, I want call the action... I have done this before using but this is not what I'm trying to achieve here. I think I might be confused... :-/ regards Leticia - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
html:form/Submit question....
I have a form and my plan is to set all the fields (using DynaActionForm) when an ok 'button' is pressed, the problem is, I'm not using a 'submit' action to submit it, but an image, the code I have at the moment is: . lots of other code here . more code here basically, I want the action in the form (addNewScope) to be submited when I do onclick (where the question marks are). I don't want to use Javascript, I want call the action... I have done this before using but this is not what I'm trying to achieve here. I think I might be confused... :-/ regards Leticia - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: REQUEST_PROCESSOR - couldn't deserialize
ok, I'm not sure this is what your problem is, but the way I fixed it was to extend the class in question and implement java.io.Serializable. Might be worth a try? regards -Original Message- From: Gopalakrishnan, Jayesh [mailto:[EMAIL PROTECTED] Sent: 13 January 2004 21:31 To: Struts Users Mailing List Subject: RE: REQUEST_PROCESSOR - couldn't deserialize Yes, the offending class seems to be the Struts RequestProcessor. -Original Message----- From: Leticia Golubov [mailto:[EMAIL PROTECTED] Sent: Tuesday, January 13, 2004 2:26 AM To: Struts Users Mailing List Subject: RE: REQUEST_PROCESSOR - couldn't deserialize I've had a similar problem before when the offending class did not implement java.io.Serializable... regards Leticia -Original Message- From: Gopalakrishnan, Jayesh [mailto:[EMAIL PROTECTED] Sent: 12 January 2004 18:54 To: Struts Users Mailing List Subject: REQUEST_PROCESSOR - couldn't deserialize Has anybody encountered this exception...? <[ServletContext(id=158851062,name=stap-portal,context-path=/stap-portal)] could not deserialize the context attribute "org.apache.struts.action.REQUEST_PROCESSOR" java.io.NotSerializableException:org.apache.struts.tiles.TilesRequestProcess or at java.io.ObjectOutputStream.writeObject0(Ljava.lang.Object;Z)V(Unknown Source) at java.io.ObjectOutputStream.writeObject(Ljava.lang.Object;)V(Unknown Source) at weblogic.servlet.internal.AttributeWrapper.getObject(Z)Ljava.lang.Object;(At tributeWrapper.java:95) at weblogic.servlet.internal.AttributeWrapper.getObject()Ljava.lang.Object;(Att ributeWrapper.java:67) at weblogic.servlet.internal.WebAppServletContext.getAttribute(Ljava.lang.Strin g;)Ljava.lang.Object;(WebAppServletContext.java:637) at org.apache.struts.action.ActionServlet.getRequestProcessor(Lorg.apache.strut s.config.ModuleConfig;)Lorg.apache.struts.action.RequestProcessor;(ActionSer - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: REQUEST_PROCESSOR - couldn't deserialize
I've had a similar problem before when the offending class did not implement java.io.Serializable... regards Leticia -Original Message- From: Gopalakrishnan, Jayesh [mailto:[EMAIL PROTECTED] Sent: 12 January 2004 18:54 To: Struts Users Mailing List Subject: REQUEST_PROCESSOR - couldn't deserialize Has anybody encountered this exception...? <[ServletContext(id=158851062,name=stap-portal,context-path=/stap-portal)] could not deserialize the context attribute "org.apache.struts.action.REQUEST_PROCESSOR" java.io.NotSerializableException:org.apache.struts.tiles.TilesRequestProcess or at java.io.ObjectOutputStream.writeObject0(Ljava.lang.Object;Z)V(Unknown Source) at java.io.ObjectOutputStream.writeObject(Ljava.lang.Object;)V(Unknown Source) at weblogic.servlet.internal.AttributeWrapper.getObject(Z)Ljava.lang.Object;(At tributeWrapper.java:95) at weblogic.servlet.internal.AttributeWrapper.getObject()Ljava.lang.Object;(Att ributeWrapper.java:67) at weblogic.servlet.internal.WebAppServletContext.getAttribute(Ljava.lang.Strin g;)Ljava.lang.Object;(WebAppServletContext.java:637) at org.apache.struts.action.ActionServlet.getRequestProcessor(Lorg.apache.strut s.config.ModuleConfig;)Lorg.apache.struts.action.RequestProcessor;(ActionSer . This exception is intermittent, unpredictable so far. thx in advance -jayash - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
FW: Displaying same page after submiting a form
That works :) Interesting... thanks so much! -Original Message- From: Shishir K. Singh [mailto:[EMAIL PROTECTED] Sent: 12 January 2004 17:27 To: [EMAIL PROTECTED] Subject: RE: Displaying same page after submiting a form Don't think I got any. However, try out the And see if you still get the errors. If yes, send in the source (that you can view from the browser when the page is displayed). Shishir -Original Message- From: Leticia Golubov [mailto:[EMAIL PROTECTED] Sent: Monday, January 12, 2004 12:22 PM To: Struts Users Mailing List Subject: RE: Displaying same page after submiting a form Hiya, Find attached before and after screen shots... regards -Original Message- From: Shishir K. Singh [mailto:[EMAIL PROTECTED] Sent: 12 January 2004 17:00 To: Struts Users Mailing List Subject: RE: Displaying same page after submiting a form Hmmm..strange...can you send a screen shot of how the page looks before and after the submit. -Original Message- From: Leticia Golubov [mailto:[EMAIL PROTECTED] Sent: Monday, January 12, 2004 11:41 AM To: Struts Users Mailing List Subject: RE: Displaying same page after submiting a form That's what i did initially, but it caused the page to be displayed with errors (images missing, etc) even though the forwar path was exactly the same as the parameter path... i.e. parameter="/pages/disco/config_toolbar.jsp" forward name ="success" path="/pages/disco/config_toolbar.jsp" thanks -Original Message- From: Shishir K. Singh [mailto:[EMAIL PROTECTED] Sent: 12 January 2004 16:31 To: Struts Users Mailing List Subject: RE: Displaying same page after submiting a form I think you need to add the forward to your action definition In your action, when your forward to success or failure, your will be brought to the specific jsp that you want (in your case the same ) Shishir -Original Message- From: Leticia Golubov [mailto:[EMAIL PROTECTED] Sent: Monday, January 12, 2004 11:25 AM To: Struts User Mailing List Subject: Displaying same page after submiting a form I'm using the following code to submit an action in a .jsp file (config_toolbar.jsp): The action is found/executed, and, as a default I'm returning a findforward("success") at the end of the ActionForward method in my SaveAction.java class. in struts_config.xml I have the following defined: In the hope that config_toolbar.jsp will still be displayed instead of the blank page I get after I do a mouseClick on the button_toolbar_save.png image. I've tried setting the forward name to the config_toolbar.jsp, but that caused strange side effect (all images were missing, the page didn't display properly). So, essentiall, I want the same page to be displayed after the saveData action is executed. Does anyone know how to do this? p.s. I'm new to struts, so could (and I hope it is) be something very simple. regards Leticia :) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Displaying same page after submiting a form
Hiya, Find attached before and after screen shots... regards -Original Message- From: Shishir K. Singh [mailto:[EMAIL PROTECTED] Sent: 12 January 2004 17:00 To: Struts Users Mailing List Subject: RE: Displaying same page after submiting a form Hmmm..strange...can you send a screen shot of how the page looks before and after the submit. -Original Message- From: Leticia Golubov [mailto:[EMAIL PROTECTED] Sent: Monday, January 12, 2004 11:41 AM To: Struts Users Mailing List Subject: RE: Displaying same page after submiting a form That's what i did initially, but it caused the page to be displayed with errors (images missing, etc) even though the forwar path was exactly the same as the parameter path... i.e. parameter="/pages/disco/config_toolbar.jsp" forward name ="success" path="/pages/disco/config_toolbar.jsp" thanks -Original Message- From: Shishir K. Singh [mailto:[EMAIL PROTECTED] Sent: 12 January 2004 16:31 To: Struts Users Mailing List Subject: RE: Displaying same page after submiting a form I think you need to add the forward to your action definition In your action, when your forward to success or failure, your will be brought to the specific jsp that you want (in your case the same ) Shishir -Original Message- From: Leticia Golubov [mailto:[EMAIL PROTECTED] Sent: Monday, January 12, 2004 11:25 AM To: Struts User Mailing List Subject: Displaying same page after submiting a form I'm using the following code to submit an action in a .jsp file (config_toolbar.jsp): The action is found/executed, and, as a default I'm returning a findforward("success") at the end of the ActionForward method in my SaveAction.java class. in struts_config.xml I have the following defined: In the hope that config_toolbar.jsp will still be displayed instead of the blank page I get after I do a mouseClick on the button_toolbar_save.png image. I've tried setting the forward name to the config_toolbar.jsp, but that caused strange side effect (all images were missing, the page didn't display properly). So, essentiall, I want the same page to be displayed after the saveData action is executed. Does anyone know how to do this? p.s. I'm new to struts, so could (and I hope it is) be something very simple. regards Leticia :) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Displaying same page after submiting a form
That's what i did initially, but it caused the page to be displayed with errors (images missing, etc) even though the forwar path was exactly the same as the parameter path... i.e. parameter="/pages/disco/config_toolbar.jsp" forward name ="success" path="/pages/disco/config_toolbar.jsp" thanks -Original Message- From: Shishir K. Singh [mailto:[EMAIL PROTECTED] Sent: 12 January 2004 16:31 To: Struts Users Mailing List Subject: RE: Displaying same page after submiting a form I think you need to add the forward to your action definition In your action, when your forward to success or failure, your will be brought to the specific jsp that you want (in your case the same ) Shishir -Original Message- From: Leticia Golubov [mailto:[EMAIL PROTECTED] Sent: Monday, January 12, 2004 11:25 AM To: Struts User Mailing List Subject: Displaying same page after submiting a form I'm using the following code to submit an action in a .jsp file (config_toolbar.jsp): The action is found/executed, and, as a default I'm returning a findforward("success") at the end of the ActionForward method in my SaveAction.java class. in struts_config.xml I have the following defined: In the hope that config_toolbar.jsp will still be displayed instead of the blank page I get after I do a mouseClick on the button_toolbar_save.png image. I've tried setting the forward name to the config_toolbar.jsp, but that caused strange side effect (all images were missing, the page didn't display properly). So, essentiall, I want the same page to be displayed after the saveData action is executed. Does anyone know how to do this? p.s. I'm new to struts, so could (and I hope it is) be something very simple. regards Leticia :) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Displaying same page after submiting a form
I'm using the following code to submit an action in a .jsp file (config_toolbar.jsp): The action is found/executed, and, as a default I'm returning a findforward("success") at the end of the ActionForward method in my SaveAction.java class. in struts_config.xml I have the following defined: In the hope that config_toolbar.jsp will still be displayed instead of the blank page I get after I do a mouseClick on the button_toolbar_save.png image. I've tried setting the forward name to the config_toolbar.jsp, but that caused strange side effect (all images were missing, the page didn't display properly). So, essentiall, I want the same page to be displayed after the saveData action is executed. Does anyone know how to do this? p.s. I'm new to struts, so could (and I hope it is) be something very simple. regards Leticia :)