You are here

function varbase_tweaks_init in Varbase: The Ultimate Drupal CMS Starter Kit (Bootstrap Ready) 7.2

Implements hook_init().

File

modules/custom/varbase_tweaks/varbase_tweaks.module, line 23
Applies some tweaks for a more usable and standardized Drupal site.

Code

function varbase_tweaks_init() {
  if (arg(0) == 'node' && arg(1) == NULL && variable_get('site_frontpage', 'node') != 'node') {
    drupal_goto('<front>', array(), 301);
  }
  drupal_add_css(drupal_get_path('module', 'varbase_tweaks') . '/varbase_tweaks.css');
  drupal_add_js(drupal_get_path('module', 'varbase_tweaks') . '/varbase_tweaks.js');
}