掲示板
Whitespace in liferay html source
9年前 に Riley Pickerl によって更新されました。
Whitespace in liferay html source
Junior Member 投稿: 50 参加年月日: 13/01/10 最新の投稿
Hello,
Currently I have setup a portal using velocity templates.
When I view the html source of the page there is a ton of whitespace in it. Meaning there are multiple blank rows between each segment of html.
Ex. There are 50+ blank lines before the opening HTML attribute.
Has anyone come across this issue or how to fix it?
Thanks,
Riley
Currently I have setup a portal using velocity templates.
When I view the html source of the page there is a ton of whitespace in it. Meaning there are multiple blank rows between each segment of html.
Ex. There are 50+ blank lines before the opening HTML attribute.
Has anyone come across this issue or how to fix it?
Thanks,
Riley
9年前 に Olaf Kock によって更新されました。
RE: Whitespace in liferay html source (回答)
Liferay Legend 投稿: 6403 参加年月日: 08/09/23 最新の投稿
Do you see this when you're running Liferay in development mode, e.g. with portal-developer.properties being active? Then this behaviour would be expected. Note that Liferay IDE/DevStudio enable the development mode by default.
If you're running Liferay in production, the following settings should be the default:
If you're running Liferay in production, the following settings should be the default:
#
# The strip filter will remove blank lines from the outputted content. This
# will speed up page rendering for users that are on dial up.
#
com.liferay.portal.servlet.filters.strip.StripFilter=true
#
# Input a list of comma delimited MIME types that will have its content
# stripped by the strip filter.
#
strip.mime.types=text/html*,text/xml*
9年前 に Riley Pickerl によって更新されました。
RE: Whitespace in liferay html source
Junior Member 投稿: 50 参加年月日: 13/01/10 最新の投稿
Awesome, thanks Olaf!
I guess since this strips all the white space now all the source will be on one line?
I guess since this strips all the white space now all the source will be on one line?
9年前 に Olaf Kock によって更新されました。
RE: Whitespace in liferay html source
Liferay Legend 投稿: 6403 参加年月日: 08/09/23 最新の投稿
Almost. Look at the source on this messageboard post page. And then, note the secret workaround, compare the source of these two URLs: