Monthly Archives: March 2011

HTML Tags to Change the Location of Minified JS and CSS by WP-Minify WordPress Plugin

If your WordPress blog is loading lot many JavaScript and CSS files in the header area of the blog, it is recommended to use WP-Minify WordPress plugin. It will reduce the DNS lookup, JS and CSS sizes and will load your website much faster.

But the problem with WP-Minify is that it loads the minified JS and CSS at the top. That means, when you will see the HTML source of your blog page, you will find minified JS and CSS loading even before the title and description meta. It is totally fine with the users but in case you are serious about throwing title, description, keyword meta data at the top of the page for SEO purpose, then I would suggest you to use HTML tags.


The developer of WP-Minify plugin named Thaya has added html tags from the version 0.8.0. Here is the template tag of the plugin.

<!-- WP-Minify JS -->
<!-- WP-Minify CSS –>

Paste the above code in the HTML template file i.e. header.php to place the minified JS and CSS at a location as per your need. I would recommend to add them just below the normal CSS and JS call in the header section of the template file.

This way you can place minified JS and CSS on your blog to let them load as per your choice. This will give you more control on the object loading for your blog as well as will let you serve SEO related meta data at first to the search engines like Google and Yahoo.

Did you find this post helpful? Do you think minified JS and CSS placement is important?

Customization Guide for W3 Total Cache WordPress Plugin


To load your WordPress site pages faster, one should install caching plugin. There are lot many caching plugins available for self hosted WordPress, but the popular ones are W3 Total Cache, WP Super Cache and Hyper Cache. Here I will talk about the most downloaded and widely used W3 Total Cache plugin and will detail out the customization and features available in this plugin. By the end of this post, you would be able to understand the purpose and functioning of W3 Total Cache plugin. I am pretty sure that you will see change in your WordPress site’s load time after installing this kind of caching plugin and proper customization.

Install and Activate W3 Total Cache

Download the plugin from plugin repository and install on your WordPress site hosting server. Installation is as simple as other plugin installation. You just need to copy the unzipped folder into wp-content/plugins folder in your site’s root. Now go to the dashboard ==> plugins menu, and activate “W3 Total Cache”.

If plugin gets activated without any problem, its fine. In case you are getting error saying that some changes required in the wp-config.php file, then you need to find the wp-config.php file in the root folder of the site and make required changes over there. Or you can make the wp-config.php writable to let the plugin make changes automatically.

Plugin Activated, now Customization

Alright folks, W3 Total Cache is successfully activated. Here is the first screen of W3 Total Cache which can be accessible from the new menu section named “Performance” which you can find below the “Settings” menu on Dashboard. Go ahead and click on “General Settings” to take a look at the common settings (default” done for your WordPress site.

By default, you will see following caching enabled.

  • Page Cache
  • Minify
  • Database Cache
  • Object Cache
  • Browser Cache

They are enabled but not customized. You need to customize them as per your need. Other than above options, CDN (Content Delivery Network) option is also available in W3 Total Cache which can be customized to serve static contents like images, JavaScript etc. much faster from different network or sub-domain on your site.

Page Cache Customization

You can manage your site’s pages caching from this particular option available under “Performance” tab. You can exclude any specific page from caching or even exclude cookies from caching as well. Set the cache expire time on this page. Default values are fine for normal sites with up to 10,000 visits per day. If you are seeing huge traffic on your site, then you may choose to reduce the value from 3600 seconds to lower.

Prime cache is also available in W3 Total Cache on Page Cache page. You can select to create more than one set of cache files by changing the interval of prime cache. Provide the sitemap URL of your site to let W3 Total Cache create cache files as per sitemap.

Combine and Compress HTML, JS with Minify

It is an awesome and effective feature available in W3 Total Cache. You can remove the blank lines from your site’s HTML and combine many JS into one to load the page much much faster. This change will not affect the PHP code into your site’s template files. You may choose to check all the options available on Minify page under HTML, JS and CSS customization.

Note: Test your site in “Preview” mode before deploying the changes.

Database Cache and Object Cache

W3 Total Cache can serve the database from caching system as well. For objects and database cache, the default value is totally fine. If you want to exclude any page or directory, you can use these pages to add them.

Browser Cache to Gain good YSlow Score

Browser cache is very important in loading the site for more than one time. That means, if a visitor will come again to your site, he will find the pages loading much faster if your site’s browser cache is customized properly. Default options in browser cache section are good but you may choose to select each of them to have more faster site for users.

Content Delivery Network (CDN)

To serve the static pages much faster and to utilize the power of browser at max, you should use CDN. A browser can have more than 5 connections at a time and if you are using CDN, you can allow browser to load static files from other domains or sub-domain. This will make your site much faster. There are third party service available for CDN, for example MaxCDN or you can use Amazon S3 as CDN. You can also choose to serve from your hosting server by creating a sub-domain on your own domain. Create a sub-domain and point that to your site’s root folder. Now using that sub-domain as CDN, you can serve static content from there. Provide the URL of CDN in “Replace site’s hostname with” box. You can use more than one CDN to load from multiple sources.

User Agent Grouping

As W3 Total Cache can help your site caching files for mobile devices as well. If you are using any other plugin like MobilePress to serve mobile friendly pages, then W3 Total Cache can see the device user agent and find the type of device and does as per your instructions. You can group the devices or user agent in low end and high end devices and them either let the plugin redirect to some other pages or use caching for services like MobilePress.

W3 Total Cache is a nice plugin but it requires lot of CPU utilization. I would recommend to use W3 Total Cache on busy sites hosted on VPS or dedicated servers. If your site is hosted on shared hosting, use WP Super Cache.

Alright folks, this time I provided some details on the customization of W3 Total Cache plugin, wait for my take on WP Super Cache customization and benefits in few days.

Compare Self hosted WordPress and as Free Blogging Platform


Are you planning to start a blog? I would highly recommend WordPress as blogging platform for non techie as well as tech savvy people. Matt Mullenweg and few other folks created WordPress back in 2003 which is now the best CMS platform awarded by reputed organizations. WordPress comes in two different versions, one is available online at where you don’t need to worry about hosting, domains as your content will be hosted by Automattic (the parent company of WordPress) and even you will get a domain like The other version of WordPress is a complete package which you can download and install on your rented server and of course can make changes in the vanilla code of WordPress as per your need.

Whether you should choose self hosted WordPress package or hassle-free, we will try to help you in making this decision. – Advantages and Disadvantages

In this comparison post, first I will talk about which is already hosting more than 10 million websites. Here you just need to register yourself using the signup window and provide few details about your blog, sub-domain name choice etc. and your blog will be ready in no time. You can start blogging in less than 5 minutes. There are lot many theme templates available for free, you can choose any one of them for your blog and once selected, the theme will be visible on your blog. Isn’t it so easy to manage and start a blog without paying a single dollar? Of course it is as easy as buying a baby diaper from store.

wordpress-com-dashboardIn, you can browse other blogs hosted on the domain by using tag surfer and can have a community feeling as well. WordPress is also having a community platform named BuddyPress which is a dedicated platform for building community sites, but here you will get a feeling of being part of a huge platform and browse great articles by other users.

But as is managed by Automattic team, you get very less customization options. For example, you can’t edit the theme files to customize them as per your need. You can edit the CSS to change width, background color, fonts etc. but can’s add things directly into the code. You have widgets to use but then your selected theme should be widget ready. Your blog will be hosted on WordPress server, they are fast and reliable servers but still you don’t have caching feature to load your pages much faster than normal loading.

Self Hosted WordPress – A Complete Package

To overcome these restrictions, you can try self hosted WordPress package. You need to download the latest version of WordPress (currently it is WordPress 3.1) and move all the files and folders to your hosting server. Yes, you need a hosting server and own domain to start with self hosted WordPress. You can also install WordPress on sub-domain or just an IP. Once you complete the installation on server, you can install themes either from WordPress theme repository or by purchasing them from premium WP theme services.


Apart from custom themes and vanilla code customization, the major advantage of self hosted WordPress is the power of Plugins. You can add new features, options and new dimension in self hosted WordPress by installing plugins available on WordPress plugin directory. For example, if you want to add a featured posts slider on your customized theme in WordPress, install Smooth Slider from Plugin repository. You will find thousands of plugins i.e. extra piece of code for specific purpose in official plugin directory.

Installation and uninstallation of plugins in WordPress is really easy task. You can choose to download and install the plugin wither from WordPress dashboard or through FTP process. Just activate the plugin and you will find the new feature rolling on your site.

For managing self hosted WordPress, you should be ready to take few risks. For example, don’t worry much before trying a new plugin until it is hosted on official plugin repository. You may find some plugins very useful for your site and few may throw error. You should either have a developer in contact if you are not much familiar with PHP/HTML coding or CSS customization.

Purchasing domain on

As I told earlier, you get a sub-domain on for free while starting your blog over there. You can also choose to have a proper domain name as per your requirement hosted on, and for that you need to pay $17 per year. It is way more than the normal $10 for a dot com domain but they charge a premium for hosting the domain.

Final Words is no doubt a good option for those who don’t want so much customization in their theme layout, branding and adding something different in their site but just a simple blog. But I would recommend to have own self hosted WordPress setup as you will see no boundaries in future over there. You can create as many blog on single server as you want and customize that as per your need. Plugins and custom themes make this package more lucrative. If you are looking for a long term blogging and branding, you should opt for self hosted WordPress setup rather than You will get each and everything in self hosted WordPress setup what is there in .com free hosting, but in addition, you will get more flexibility, better customized look, self managed and securely backed up blog setup. By securely backed up, I mean the premium backup service launched by Automattic named “VaultPress” which is currently for self hosted WordPress blog only. In $15 per month, you can start automatic backup process for your blog and host the hourly back up files on WordPress server. You can restore any version at any point of time.

Note: I will discuss VaultPress in other post in detail. Currently I am using it for couple of my self hosted WordPress sites.