Instantly share code, notes, and snippets.

* Drush commands for quickly enabling & disabling modules based on
* nothing environment. This only includes modules and features but not themes.
* About the environment variable:
* When multiple versions of the site are used each defines its own environment to allow enabling or disabling specific
* modules. We define the environments variable in the site's configuration file settings.php (Drupal settings).
* It is also useful to have conditionals in your settings based on environment.
* Here's an example with development, staging and production environments:
View changeTypeAttr.js
/* id is the id tag of <input/> element
type is the type you want to change it to.
jQuery is required and assumed to be the jQuery variable */
function changeType(id, type) {
var x = jQuery("#"+id);
if(x.attr('type') == type)
return x; //That was easy.
try {
return x.attr('type', type); //Stupid IE security will not allow this
} catch(e) {