Drupal Multi-site - Sharing the same code base

Here I dont want explain more! just simple steps:

1.Install Drupal with default setting:
Now your website is available at www.example.com

2.Create New subdomain, we call that "sub"

Duplicate commerce items when using attributes in taxonomy page

When products have multiple attributes, created multiple copies of the same product with different attribute and linked them to a content product display node.
By doing so, every single product of the attribute is showing once on category page. How do I remove the duplicates?

All Solutions:

Solution One:

upgrading to Drupal 7.36 May Cause Node Types to be disabled.

After updating to Drupal 7.36, many strange problems began to occur. If your content type is build by a module, may cause node types to be disabled.
you can fix this problem by following code into a custom module and enable it:

Increase Drupal admin shortcut links

Put this following line in your settings.php file. It is increase your shortcut link to 12.

Counter module url length problem

Module name : Counter
Version: 7.x-1.0-beta3

When content url path set to : blahlah/[node:title] and length is more than 255 the problem happened.

Getting the number of times an item is flagged

Insert following code where you want:

Show field or other text for only certain user role

You can use own role name.

Load user fields in node.tpl.php

If you want load user fields like full name of author in node.tpl.php use the function: user_load($user->uid) then print_r the resulting object you will see how to access the info you need.

How To Use Registry Rebuild With Drush in multisite

There are times in Drupal 7 when the registry gets hopelessly hosed and you need to rebuild the registry (a list of PHP classes and the files they go with). Sometimes, though, you can't do this regular cache-clear activity because some class is required when the system is trying to bootstrap. (such as moving modules folder to another folders / multisite things)

This is the preferred technique, and it should work with multisite installs.

Update Drupal site with Drush

Run following steps:

Checking update status:
Drush @prod pm-updatestatus

Run update:
Drush @prod pm-update

Clear all cache:
Drush @prod cc all