Tips
Drupal is one incredible technology which is getting better and better with each passing day. A number of websites are relying on the power of Drupal and benefitting from the immense utility that Drupal brings to the fore. However, no technology is fool-proof and even the much talked about and popular Drupal has had its share of problems. Many a time users have complained regarding slow page loads which deter them from accepting Drupal as a revolutionary technology.
Every Problem warrants a Solution and with this article coupled with my experience on Drupal optimization I would like to clear the air regarding problems faced using Drupal and would like to share some tips with all you Developers/Drupal Enthusiasts reading my article right now:
1. GZIP - In Drupal, pages are written to the cache in GZIP form. You need to configure your Apache server to automatically compress GZIP format files.
- E.g. Add the following line: AddOutputFilterByType DEFLATE text/css application/x-javascript to your .htaccess or httpd.conf files
2. JS files at the Bottom
As a Standard Practice all the browsers load everything in the <head> tag first. Since these days JS files are usually of very large sizes it is considered a wise action to place the JS right at the bottom of a page to achieve faster load time.
3. YSLOW
If you’re a developer it becomes that much important for you to equip yourself with a wonderful utility called YSLOW Firebug, which helps in analyzing a webpage and make a diagnosis on why your website is slow. YSLOW also gives out handy solutions to fix the flaws.
4. Scale down HTTP requests
By narrowing down comments and whitespace Drupal demonstrates its CSS compression utility. It is highly recommended to enable CSS and JS aggregation features available in Drupal which can be done by accessing admin/setting/performance inside your Drupal website.
5. Deploy CDN integration
URLs must be written in Drupal to serve the files from a Content Delivery Network (CDN). This CDN integration serves a great purpose and reduces load time especially for users who are far away from your server location.
6. Placing CSS at the Top
To ensure faster page loads, place the stylesheets to the document HEAD.
7. CSS Expressions must be Avoided!!
CSS expressions are calculated every time a user moves the mouse over the page, during page rendering, page scrolling and page resizing and for this very reason it makes good sense to avoid CSS expressions.
8. JS and CSS should be made external as far as possible
For faster page loads inline JS and CSS should be judiciously used.
9. Minimize DNS lookups
Widgets have become an integral element of many websites. Drupal allows the option of running as many widgets on your website as you may want. However, I would recommend all these widgets to be stored on your website or to your CDN. E.g. è install the Google Analytics Module while using Google analytics as it carries a feature to cache the .js files locally and updates it on a daily basis.
10. Avoid Redirects
As a practice avoid redirects as far as possible to ensure an optimal performance and great user experience working with Drupal.
11. ETags
ETags are used to accurately pin-point a file and investigate whether the file on the browser cache is matching with the file on the server. These are generated using inodes from the server they are being served. This is where the problem lies and it becomes s omuch important to disable ETags while using multiple servers to save on load time. To do this, Apache users can add the following line:
FileETag none
to your httpd:conf
or alternatively you can use a single server to serve files or use CDN (if possible).
12.
1.Enable caching for your Drupal.
2.Optimize your Drupal database.
3.Log in to your Drupal admin area and go to Site Configuration > Performance. Besides enabling cache, you should also enable Page compression, Optimize CSS files and Optimize JavaScript files.
4. If your Drupal is hosted on a dedicated solution, you can modify the global MySQL settings for better performance.
5.Check your website using this online tool. It will give you valuable information on what modifications can be made in order to improve its performance.
6.Disable/remove all modules/blocks you are not using.
That seems it. Try implementing the above suggestions and check out the difference. Drupal is designed to give an exciting experience to its users and should not be disregarded just because of some hiccups which every new technology goes through. For Problems there are Always Solutions. Explore them. Happy Drupal ing Guys !!!
分享到:
相关推荐
Intel® Integrated Performance Primitives How to Optimize Software Applications Using Intel® IPP by Stewart Taylor
an overview of how MySQL Cluster can be integrated with other MySQL storage engines, before summarizing additional resources that will enable you to optimize MySQL Cluster performance with your ...
本手册介绍了有关为英特尔微处理器优化代码所需的一切,包括奔腾,奔腾MMX,奔腾Pro,奔腾II,奔腾III,奔腾4,赛扬和至强。
C++ High Performance Boost and optimize the performance of your C++17 code_Code 源码 本资源转载自网络,如有侵权,请联系上传者或csdn删除 查看此书详细信息请在美国亚马逊官网搜索此书
Learn how to identify, prioritize, and analyze problems, and then—most importantly—how to optimize performance. Learn how to test web pages and understand the results Determine if you have ...
As you advance to Ruby performance expert, you’ll learn how profile your code, how to make sense out of profiler reports, and how to make optimization decisions based on them. You’ll make sure slow ...
How to Optimize MySQL: Indexes, Slow Queries, Configuration by Bruno Škvorc How to Read Big Files with PHP (Without Killing Your Server) by Chris Pitt WordPress Optimization by Tonino Jankov ...
If you are a .NET developer with an understanding of application development, but want to learn how to optimize the performance of your applications, this is the book for you. Basic knowledge of C# is...
在Simulink中优化控制系统参数是一项关键任务,它涉及到系统性能的提升、稳定性的保障以及设计效率的提高。MATLAB作为强大的数学计算软件,提供了丰富的工具箱,包括Simulink,来支持这一过程。...
C++ High Performance Boost and optimize the performance of your C++17 code 英文epub 本资源转载自网络,如有侵权,请联系上传者或csdn删除 查看此书详细信息请在美国亚马逊官网搜索此书
Chapter 2: From Data to Insights Chapter 3: Luis Madureira Part II: Defining Analytics in Social Media and Types of Analytics Tools Chapter 4: Analytics in Social Media Chapter 5: Dedicated vs. ...
As you advance to Ruby performance expert, you'll learn how profile your code, how to make sense out of profiler reports, and how to make optimization decisions based on them. You'll make sure slow ...
You will also learn how to optimize your game performance, how to add animation files and create texture atlas in Xcode 5, and how to build different particles. By the end of the book you will learn ...