Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-3951

AjaxFallbackButton deteriorates ">" in value attribute.

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Duplicate
    • Affects Version/s: 1.4.17
    • Fix Version/s: None
    • Component/s: wicket
    • Labels:
      None

      Description

      Using ">" in attribute value is not forbidden by HTML neither XML.
      When used in value attrib, AjaxFallbackButton spoils it - it renders this:

      <input value="" ... type="button">>" />

      Longer snippets:
      HTML:

      <input type="button" wicket:id="prev" value="<< Prev day" />
      <input type="button" wicket:id="next" value="Next day >>" />

      Java:

      this.navigForm.add( new AjaxFallbackButton("prev", this.navigForm) {
      protected void onSubmit(AjaxRequestTarget target, Form<?> form) {
      }
      });

      this.navigForm.add( new AjaxFallbackButton("next", this.navigForm) {
      protected void onSubmit(AjaxRequestTarget target, Form<?> form) {
      }
      });

      Rendered HTML:

      <input value="<< Prev day" name="prev" id="prev4" onclick="var wcall=wicketSubmitFormById('navig1', '../?wicket:interface=:0:navig:prev::IActivePageBehaviorListener:0:1&wicket:ignoreIfNotActive=true', 'prev' ,function() { }.bind(this),function() { }.bind(this), function()

      {return Wicket.$$(this)&&Wicket.$$('navig1')}.bind(this));;; return false;" type="button">

      <input value="" next="" day="" name="next" id="next5" onclick="var wcall=wicketSubmitFormById('navig1', '../?wicket:interface=:0:navig:next::IActivePageBehaviorListener:0:1&wicket:ignoreIfNotActive=true', 'next' ,function() { }.bind(this),function() { }.bind(this), function() {return Wicket.$$(this)&&Wicket.$$('navig1')}

      .bind(this));;; return false;" type="button">>" />

        Attachments

        1. valueAttributeSpecialChars.txt
          3 kB
          Andrea Del Bene

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                pekarna Ondra Žižka
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: