Home » Liferay Portal » English » 3. Development

Combination View Flat View Tree View
Threads [ Previous | Next ]
Muhammed Shakir
$ and { is stripped in HTML
January 12, 2013 8:58 PM

Muhammed Shakir

Rank: Junior Member

Posts: 36

Join Date: February 25, 2009

Recent Posts

Hi Everyone,

Check the following code snippet :

2 <div id="cd">
3       <h5>Hello ${theTitle} </h5>
4 </div>
6    var ob2 = document.getElementById("cd");
7    alert(ob2.innerHTML);

Write the above code in .jsp of any portlet in Liferay 6.0 and prior. You will see that the complete innerHTML is shown in the alert i.e. <h5>Hello ${theTitle}</h5> Now write the same in Liferay 6.1 GA2. You will notice that the entire thing written in ${......} is stripped including the $ and brace brackets. The alert will print only <h5>Hello</h5>

I have checked the filter etc - but could not find anything. I will be grateful to any help or pointer towards the solution.

Thanks in Advance.
Jelmer Kuperus
RE: $ and { is stripped in HTML
January 13, 2013 1:02 AM

Jelmer Kuperus

Rank: Liferay Legend

Posts: 1192

Join Date: March 10, 2010

Recent Posts

Add the following jsp page directive add the top of your page :

1<%@ page isELIgnored="true" %>

Participate in the State of Liferay Community 2017. Help the community and even win some prizes!