How to force Liferay not to create compressed HTML?

I found that Differey was passing my JSP code in a somewhat "condensed" way - putting most of the text in a few very long lines.

This makes javascript debugging inconvenient.

Can I temporarily disable this feature?

+8
java html jsp liferay
source share
5 answers

HTML Minification is performed regardless of whether you are in developer mode or not, since HTML descriptions themselves can cause problems that you want to see in developer mode.

You can add the strip=0 parameter to the URL to prevent the cropped HTML page from being deleted.

To completely disable HTML-Stripping in your system.properties :

 com.liferay.filters.strip.StripFilter=false 

But as @BalusC said you should use a tool that does formatting when debugging. So you do not worry about it.

+10
source share

For others considering this post, if you just want to do it based on adhoc, you can add these parameters to the url:

/ web / guest / page js_fast_load = 0 &? Css_fast_load = 0 & lane = 0

Please note that this is for JS, CSS and HTML

+12
source share

There are two ways to do this. Copy the following into portal-ext.properties and restart the server

 javascript.fast.load=false 

or If you do not want to restart it, and only for temporary use, add the js_fast_load parameter to url and set its value to false.

For example, if you are on the page http://localhost:8080/web/guest/home , in which your portlet or javascript is present. Use this URL instead of http://localhost:8080/web/guest/home?js_fast_load=0

+5
source share

Liferay has a file called portal-developer.properties as a template in WEB-INF / classes. You can either reference this, or simply copy / paste the contents into your portal-ext.properties file.

It has several options to minimize html, js, css and others. You will kill boot time - that is, you really want only these options during development, but then it really helps.

By default, all files are also combined into one (for js, the other for css, etc.) - with development options you will receive a separate request for each file in each page request.

+1
source share

I just want to update the package name for Liferay 6.2 from @Fabian Barney's answer:

 com.liferay.portal.servlet.filters.strip.StripFilter=false 
+1
source share

All Articles