OFBiz
  1. OFBiz
  2. OFBIZ-534

Special characters such as double quote in Form Widget

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: framework
    • Labels:
      None

      Description

      I have entered "Ofbiz Test" <ofbiztest@ofbiz.org> to fromEmailAddress field in updateProductStoreEmail form and saved the data.
      Then i have recalled this form. But form doesn't shown properly. Because double quote character didn't convert to ";

      The form field datas must be convert to html string in ModelFormField.java.
      I want to make a patch for this bug.

      Does anybody has thought this?

      Regards,
      Ismail

        Activity

        Hide
        Ismail Cansiz added a comment -

        There is same problem in HtmlFormRenderer.java too. Field values should be convert to html syntax in renderTextField and renderHiddenField methods.

        Show
        Ismail Cansiz added a comment - There is same problem in HtmlFormRenderer.java too. Field values should be convert to html syntax in renderTextField and renderHiddenField methods.
        Hide
        Ismail Cansiz added a comment -

        I have a patch file to solution for this bug. I have tested and problem is solved for input text fields..
        The file is containing only one modification for renderTextField method.
        In the other methods such as renderTextAreaField may be require some modifications.

        Any thoughts?

        Thanks,
        Ismail

        Show
        Ismail Cansiz added a comment - I have a patch file to solution for this bug. I have tested and problem is solved for input text fields.. The file is containing only one modification for renderTextField method. In the other methods such as renderTextAreaField may be require some modifications. Any thoughts? Thanks, Ismail
        Hide
        Jacopo Cappellato added a comment -

        I think this is a good solution, can we commit this patch? Or are there any issues this could cause?

        Show
        Jacopo Cappellato added a comment - I think this is a good solution, can we commit this patch? Or are there any issues this could cause?
        Hide
        Christian Geisert added a comment -

        Yes, please commit

        I just tried the patch with current svn (495520) and still applies (Hunk #2 succeeded at 222 (offset -1 lines))

        (I noticed this problem when I tried to enter a product brand name with a double quote and this patch fixes it)

        Show
        Christian Geisert added a comment - Yes, please commit I just tried the patch with current svn (495520) and still applies (Hunk #2 succeeded at 222 (offset -1 lines)) (I noticed this problem when I tried to enter a product brand name with a double quote and this patch fixes it)
        Hide
        Jacques Le Roux added a comment -

        Sounds fine, I vote for

        Show
        Jacques Le Roux added a comment - Sounds fine, I vote for
        Hide
        Jacopo Cappellato added a comment -

        Thanks Ismail for the patch and to Jacques and Christian for the tests.
        I've committed it in rev. 514110
        To everyone: the patch should be ok, I've used it in my box for several days without problems, but since this is a change that will affect all forms and there could be side effects that I can't imagine at the moment, please help with tests and bug reports.

        Show
        Jacopo Cappellato added a comment - Thanks Ismail for the patch and to Jacques and Christian for the tests. I've committed it in rev. 514110 To everyone: the patch should be ok, I've used it in my box for several days without problems, but since this is a change that will affect all forms and there could be side effects that I can't imagine at the moment, please help with tests and bug reports.

          People

          • Assignee:
            Jacopo Cappellato
            Reporter:
            Ismail Cansiz
          • Votes:
            1 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development