This should work. Tests for an eventSubmit_doXXXX ending in .x or .y
and strips them if they exist.
--Kevin Kress ([EMAIL PROTECTED])
--------------------------------
--- ActionEvent.java Mon Nov 20 18:22:57 2000
+++ ActionEvent.java.new Mon Nov 20 18:23:37 2000
@@ -205,9 +205,17 @@
(fold.length()==0) ||
(! fold.equals(ParameterParser.URL_CASE_FOLDING_NONE)))
{
+ String tmp = input;
+
+ // Chop off suffixes (for image type)
+ if (input.endsWith(".x") || input.endsWith(".y"))
+ {
+ tmp = tmp.substring(0, input.length() - 2);
+ }
// Chop off the prefixes.
- String tmp = input.substring(BUTTON_LENGTH +
- METHOD_NAME_LENGTH);
+ tmp = tmp.substring(BUTTON_LENGTH +
+ METHOD_NAME_LENGTH);
+
return (METHOD_NAME_PREFIX +
firstLetterCaps(tmp));
}
Jon Stevens wrote:
>
> on 11/20/2000 5:44 PM, "Kevin Kress" <[EMAIL PROTECTED]> wrote:
>
> > I am trying to get an input of type image to work as an ActionEvent,
> > but it seems that the trailing .x and .y are confusing the ActionEvent.
> > I am curious if this has been discussed before. I realize there is a
> > trivial javascript solution, but I would prefer not to go down that
> > route. I am looking at making a patch for ActionEvent, but did not want
> > to proceed if this is something that has been discussed before.
> >
> > Thanks
> >
> > Kevin Kress
>
> If you can think of a patch that would solve this issue, then suggest it.
>
> Otherwise, javascript is your only other solution.
>
> -jon
>
> --
> twice of not very much is still a lot more than not very much
>
> ------------------------------------------------------------
> To subscribe: [EMAIL PROTECTED]
> To unsubscribe: [EMAIL PROTECTED]
> Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
> Problems?: [EMAIL PROTECTED]
------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?: [EMAIL PROTECTED]