Pages

Thursday, December 20, 2012

Which is a best webhosting for Drupal


I know web hosting is so unreliable these days. Its full of made up promises with fine prints.  Unlimited space - is a hype. It's a marketing gimmick. Don't fall for it!Sometimes it's  difficult to find good web hosts with great support.
So how do you find a  web host company which can best support your drupal website, Such that whenever there is a problem, someone can solve it quickly.
Drupal will need PHP and MySQL support This common setup is better known as LAMP(linux, apache, mysql, php) is themost economical and stable solution. In addition you would need a good user interface for control panel, like cpanel. First of all, lets check what are the additional features you would need in a drupal host compared to normal websites, these will be useful if you are planning for high end website
  1. memcache, it is a high-performance memory object caching system. It will  speed up database-driven websites by caching data and objects in RAM. This is very effective in managing the load on your database, which for most web applications including Drupal, is the biggest performance bottleneck and risk to scalability.
  2. APC, which stands for Alternative PHP Cache, is a free PHP extension that will optimize the performance of PHP applications by caching PHP code in a compiled state. Check if the host has this.
  3. When a proxy, like Squid, is configured as a reverse proxy it can act as a caching mechanism for web pages. Because the reverse proxy sits between the internet and the webserver, it can intercept all requests and respond to them by serving cached content. This reduces the load on the webserver (and the database).
  4. FastCGI and mod_php are two of the most commonly used approaches. Most people are using mod_phpbecause that is the default on nearly all Linux distributions. FastCGI is often used on shared hosts to provide additional security, but has performance hit.  So choose if you want better performance (mod_php) or most security ( FastCGI)
  5. Varnish is a HTTP accelerator that caches web pages for future use. Its mainly for anonymous users
  6. Apache Solr is a search platform that uses a variety of features to speed up complicated databases queries. While Solr can drastically reduce the amount of time required for queries in large pools of data, it should only be applied for sites where the increased memory usage doesn't outweigh the benefits.
  7. Security – A generic requirement is that it should support SFTP file transfers and SSL for secure data transfers.
In conclusion, if you are looking for shared hosting and something which is good for your pocket, then you may not get good performance, security or customer support. Having said that , there are good shared hosting providers for Drupal. If you are looking to host professional and high end sites, then its better you select from above list of features, in addition to the standard features provided by webhosting. Drupal is a powerful CMS and if the hardware or hosting supports it well then it can really do wonders for you. Fast websites are still in fashion and will continue to outsmart the slower alternatives.

Use CDN jQuery for your Drupal theme


Simple code to use jQuery from Google CDN. Change the version "1.8.0" to your preferred version.
You can also switch to use Microsoft CDN, or other sources by changing the jQuery path below.
/**
* Implements hook_js_alter().
*/
function YOUR_THEME_js_alter(&$js) {
  if (isset($js['misc/jquery.js'])) {
    $jquery_path ='http://ajax.googleapis.com/ajax/libs/jquery/1.8.0/jquery.min.js';
    $js['misc/jquery.js']['data'] = $jquery_path;
    $js['misc/jquery.js']['version'] = '1.8.0';
    $js['misc/jquery.js']['type'] = 'external';
  }
}
This code may conflict with jQuery Update module.

Thursday, October 11, 2012

Fusion Accelerator and Drupal 7


Moving into Drupal 7 territory

Fusion is making serious headway into Drupal 7! After many months of working with Drupal 7 and Skinr, the decision was made to create a skin tool for Fusion itself, and we brought the tool in house. We could not ask our customers to wait any longer.
Fusion Accelerator
Fusion themes are now dependent on the Fusion Accelerator module. Fusion Accelerator includes a fork of Skinr called Fusion Apply. It also includes other features such as a grid tool for themers to use to easily create new Fusion ready grids. The Fusion Apply Rules module allows you to quickly create rulesets for the application of your skins to different pages and regions of your site.
If you’re already using Fusion and Skinr, we’ve written some documentation on updating your current theme. You can see many of these items in our documentation here:Getting Started with Fusion Apply and here: Creating Fusion Apply Styles.
If you’re already using a Fusion sub-theme for Drupal 7, you should also see our general upgrade documentation here, and if you’re using Drupal 6 and want to move all the way to our lastest versions, then Converting Drupal 6 to Drupal 7 themes is the place to go.

Theme updates?

We’re working hard to update our themes as quickly as possible. We’ve got one all new premium theme for Drupal 7, and two updated themes, as well as updates for Fusion Core and Acquia Marina. If you already own a Fusion theme, you’ll receive an email when your theme is updated. Look for a post on our Drupal Commerce based themes, coming soon!

Anything else?

You bet! If you’re interested in responsive theming, have a look at Fusion’s development release on Drupal.org. That’s right, we’re adding responsive features into Fusion! We’re very excited to be doing this, so keep an eye on us for more information on this too!

Updating Drupal


Today I shall show you how to upgrade your Drupal web application to latest stable version.
It is strongly recommended that you always keep your Drupal site up to date with the very latest minor release available, to remove known security vulnerabilities and existing bugs.
How to find out that our Drupal site needed to be updated?
Well, it’s quite simple. Your Drupal installation is smart and notifies you about the new version available at Drupal.org. All you need to do is to check the status report of your Drupal application.
To check STARUS REPORT login as Super User ( the user uame you selected during installation).
Then go to Administer-Reports-Status report.
Status
If your Drupal installation is not upto date then you would notice some alerts like the following
Status Report
You can notice the current version of Drupal is 6.16 and Drupal is showing that it’s not secure to continue with this installation. Further, it is also indicating the version needed to installed, in this case the most recent version is 6.20.
Backing up the current installation
The first thing we need to do before patching Drupal is to take the site off-line. It’s a Drupal utility. You can find this utility under site configuration - site maintenance. Now select off-line button and save configuration. You have to login as a super-user to do so. This is a cool feature of Drupal which shows a message to the visitors that the site is currently under maintenance. For some reason if you need to log out of your Drupal site during patching you can always log back in. To do so write your domain name and then put /user (e.g. www.example.com/user).
It is very important backup the database because should anything go wrong with the database while you are patching Drupal or even modules you can always turn back to your old database.  There are several ways to back up the database; I am going to use the most common tool available i.e. phpmyadmin. So, you first have to login to your webhosting control panel.  Then go to phpmyadmin utility.
phpmyadmin
Select the database you wish to backup
database
(I am using the picture of a live site that is way I have hidden the name of the database for security reason.)
Click on the Export utility.
Export
Now, scroll down to the bottom and save the file out as a default SQL file
Save
Database save prompt
We have completed the second step. Now it’s time to backup our additional resources such as custom configuration file, contributed modules and themes, and site's uploaded files. If other files have modifications, such as .htaccess or robots.txt, back those up as well.
Drupal keeps all the custom user configuration and files in a directory called “sites”. So, if we simply copy this directory and keep it in a safe place we are good to go ahead and patch our Drupal installation.
We are done with the archiving of our Drupal site. It’s time to move forward and start the upgrading process.
1. Download the latest and stable Drupal version from Drupal.org. In our case it’s Drupal 6.20.
2. Unpack the new Drupal version in your local computer.
3. Fire up your favorite ftp client, I am using filezilla, and login to your ftp account.
4. Upload all the files and folders to your Drupal installation directory except for sites directory, .htaccess and robots.txt file. [This step is very critical so do it carefully.]
5. We have performed all necessary steps to upgrade our Drupal installation. Now it’s time to check whether our patching was successful or not.
6. To check that head over to the Reports-status report and examine.
New Status
7. You would notice that when status reports loads it recognize now that we have Drupal 6.20. That means we have upgraded our Drupal installation successfully.
8. Now run update_0.php by visiting e.g., http://www.example.com/update.php (replace  www.example.com with your Drupal installation's domain name and path). This step will update the core database schema to the new Drupal installation.
9. Drupal would prompt you now to follow these instruction of the above image. We have already done these during archiving of our installation. So, you can move forward and continue.
10. Last thing we would want to do is to take our site online. For that, we would go to site maintenance-select online and save configuration.
Well that’s all. You seem to have successfully updated your Drupal core.