Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-13309

eZmatrix datatype doesn't store text content properly when containing some special characters

    XMLWordPrintable

Details

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Medium Medium
    • 4.0.1, 4.1.0alpha1
    • 4.0.0, 4.0.1rc1
    • Misc
    • None
    • Operating System: GNU/Linux
      PHP Version: 5.2.5
      Database and version: MySQL 5
      Browser (and version): Firefox 2

    Description

      Storing some text containing some special characters (like "&") is not possible in an eZmatrix attribute.

      Indeed, it seems that the text content has just to be washed on attribute storing (because of XML), the simple attached patch, basically a htmlspecialchars, fixes the problem by transforming HTML values before its storage.

      Steps to reproduce
      • Edit a class and add an eZmatrix attribute to this class
      • Create an object of this class, then fill information
        In the eZmatrix attribute, type a text containing some special characters as can be "&".
        For an example, try to storie an urls containg get variables, it will end in a text like "http://www.somesite.com/page?var=yes&var2=no&var3=rulez"
      • Publish the content

      Reopen your content, you should then see that your string has been broken, only the text before the "&" has been kept, the rest has been lost.

      Attachments

        Activity

          People

            cyberwolf cyberwolf
            alexandre.nion alexandre.nion
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: