Details

    • Branch Version/s:
      6.1.x
    • Backported to Branch:
      Committed
    • Story Points:
      3
    • Fix Priority:
      4
    • Similar Issues:
      Show 5 results 

      Description

      The asset publisher when added to a page displays the journal articles created, but in the summary page it shows the css values if used in the template of the particluar article.

      But it shows properly in the read more link

        Activity

        Hide
        Gaurav Jain added a comment -

        Being part of community verifier program, I tried reproducing this issue against Liferay 6.2.0 CE M4 tomcat bundle/MySql 5.5.17.

        And can reproduce it with the following steps:

        • Install a fresh lr bundle of above mentioned version
        • Create a structure "test-structure" with just one text field
        • Create a template "test-template" and associated it with "test-structure"
          kept content of template as following:
          <style type= "text/css">
          .testClass {display:block;}
          </syle>
          Hello World!
          
        • Create a web-content item with "test-structure"
        • Placed an asset publisher on a page; by default first item is the web-content created in above step
        • The abstract content shows like:
          .testClass {display:block;} Hello World!
          
        Show
        Gaurav Jain added a comment - Being part of community verifier program, I tried reproducing this issue against Liferay 6.2.0 CE M4 tomcat bundle/MySql 5.5.17. And can reproduce it with the following steps: Install a fresh lr bundle of above mentioned version Create a structure "test-structure" with just one text field Create a template "test-template" and associated it with "test-structure" kept content of template as following: <style type= "text/css" > .testClass {display:block;} </syle> Hello World! Create a web-content item with "test-structure" Placed an asset publisher on a page; by default first item is the web-content created in above step The abstract content shows like: .testClass {display:block;} Hello World!
        Hide
        Ginson Ren added a comment - - edited

        PASSED Manual Testing following the steps in Gaurav's comment.

        Reproduced on:
        Tomcat 7.0 + MySQL 5. Portal 6.1.20 EE GA2.

        The abstract content shows like: ".testClass

        {display:block;}

        Hello World!"

        Fixed on:
        Tomcat 7.0 + MySQL 5. Portal 6.1.x EE GIT ID: 9d7339569a8a7481878d1e6ce1a6084f551682c5.
        Tomcat 7.0 + MySQL 5. Portal 6.2.x GIT ID: f2daa5a19c7e94692261597d31fc51e28b4965c1.

        The abstract content only shows: "Hello World!"

        Show
        Ginson Ren added a comment - - edited PASSED Manual Testing following the steps in Gaurav's comment. Reproduced on: Tomcat 7.0 + MySQL 5. Portal 6.1.20 EE GA2. The abstract content shows like: ".testClass {display:block;} Hello World!" Fixed on: Tomcat 7.0 + MySQL 5. Portal 6.1.x EE GIT ID: 9d7339569a8a7481878d1e6ce1a6084f551682c5. Tomcat 7.0 + MySQL 5. Portal 6.2.x GIT ID: f2daa5a19c7e94692261597d31fc51e28b4965c1. The abstract content only shows: "Hello World!"
        Hide
        Eduardo Garcia added a comment -

        Hi Ginson,

        In the abstract view the HTML of the content is "cleaned":

        1. Javascript blocks are removed
        2. Style blocks are removed (this has been added to solve this issue)
        3. For any other html block (i.e <x>...</x>) the tags are removed and only the content between them is displayed.

        For example, if you use a template with this code (and therefore the web content has this html when rendered):

        <script>
        alert('Hola');
        </script>
        
        <style type= 'text/css'>
        .testClass {display:block;}
        </style>
        
        <p>Hello World!</p>
        

        The abstract in the Asset Publisher portlet will display only "Hello World!"

        In your case I'm afraid you're using an incorrect code for testing. Notice that the close tag of the style block is "syle" instead of "style". That makes the block being cleaned as any html tag (as described in case 3.) instead of a well-formed style block.

        Please try again with a well-formed style block (our use the example I provided above) and let me know the result.

        Thanks!

        Show
        Eduardo Garcia added a comment - Hi Ginson, In the abstract view the HTML of the content is "cleaned": 1. Javascript blocks are removed 2. Style blocks are removed (this has been added to solve this issue) 3. For any other html block (i.e <x>...</x>) the tags are removed and only the content between them is displayed. For example, if you use a template with this code (and therefore the web content has this html when rendered): <script> alert('Hola'); </script> <style type= 'text/css'> .testClass {display:block;} </style> <p>Hello World!</p> The abstract in the Asset Publisher portlet will display only "Hello World!" In your case I'm afraid you're using an incorrect code for testing. Notice that the close tag of the style block is "syle" instead of "style". That makes the block being cleaned as any html tag (as described in case 3.) instead of a well-formed style block . Please try again with a well-formed style block (our use the example I provided above) and let me know the result. Thanks!
        Hide
        Ginson Ren added a comment -

        Hi Eduardo,

        Thanks for your help, the problem is the "syle". I will pass this ticket and close it soon.

        Show
        Ginson Ren added a comment - Hi Eduardo, Thanks for your help, the problem is the "syle". I will pass this ticket and close it soon.

          People

          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:
              Days since last comment:
              1 year, 45 weeks, 3 days ago

              Development

                Structure Helper Panel