Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Liferay 6.x Portal Enterprise Intranets Cookbook

You're reading from   Liferay 6.x Portal Enterprise Intranets Cookbook Over 60 hands-on recipes to help you efficiently create complex and highly personalized enterprise intranet solutions with Liferay Portal 6.x CE

Arrow left icon
Product type Paperback
Published in May 2015
Publisher
ISBN-13 9781782164289
Length 300 pages
Edition 1st Edition
Languages
Arrow right icon
Toc

Table of Contents (14) Chapters Close

Preface 1. Installation and Basic Configuration 2. Authentication and Registration Process FREE CHAPTER 3. Working with a Liferay User / User Group / Organization 4. Liferay Site Configuration 5. Roles and Permissions 6. Documents and Media in Liferay 7. Working with Content 8. Search and Content Presentation Tools 9. Liferay Workflow Capability 10. Collaboration Tools 11. Quick Tricks and Advanced Knowledge 12. Basic Performance Tuning Index

Enabling JS and CSS minification


When your web page loads in a browser, the browser sends an HTTP request to the web server for the page in the URL. Then, as the HTML is delivered, the browser parses it and looks for additional requests for images, scripts, CSS, and so on. Every time it sees a request for a new element, it sends another HTTP request to the server. In order to decrease the number of additional requests, Liferay has the following ready-to-use mechanisms:

  • Minifier (compressor) that allows you to compress and minify your JavaScript and CSS files

  • Merging JavaScript files to reduce the number of HTTP requests using barebone.jsp and everything.jsp

  • Merging CSS files and images for faster loading

  • Enabling Gzip compression

How to do it…

To set Liferay's fast-load mechanisms, set the following properties in the portal-ext.properties file:

minifier.enabled=true
javascript.fast.load=true
theme.css.fast.load=true
theme.images.fast.load=true
layout.template.cache.enabled=true

Additionally, if...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image