/** * Magento Enterprise Edition * * NOTICE OF LICENSE * * This source file is subject to the Magento Enterprise Edition License * that is bundled with this package in the file LICENSE_EE.txt. * It is also available through the world-wide-web at this URL: * http://www.magentocommerce.com/license/enterprise-edition * If you did not receive a copy of the license and are unable to * obtain it through the world-wide-web, please send an email * to license@magentocommerce.com so we can send you a copy immediately. * * DISCLAIMER * * Do not edit or add to this file if you wish to upgrade Magento to newer * versions in the future. If you wish to customize Magento for your * needs please refer to http://www.magentocommerce.com for more information. * * @category Mage * @package Mage * @copyright Copyright (c) 2014 Magento Inc. (http://www.magentocommerce.com) * @license http://www.magentocommerce.com/license/enterprise-edition */ if (version_compare(phpversion(), '5.2.0', '<')===true) { echo '

Whoops, it looks like you have an invalid PHP version.

Magento supports PHP 5.2.0 or newer. Find out how to install Magento using PHP-CGI as a work-around.

'; exit; } /** * Error reporting */ error_reporting(E_ALL | E_STRICT); /** Redirecting District West to LA Times */ if(stristr($_SERVER['HTTP_HOST'],"districtwest.com")) { header('Location: http://store.latimes.com/gifts-and-apparel/local-makers-district-west.html'); die(); } /** * Compilation includes configuration file */ define('MAGENTO_ROOT', getcwd()); $compilerConfig = MAGENTO_ROOT . '/includes/config.php'; if (file_exists($compilerConfig)) { include $compilerConfig; } $mageFilename = MAGENTO_ROOT . '/app/Mage.php'; $maintenanceFile = 'maintenance.flag'; if (!file_exists($mageFilename)) { if (is_dir('downloader')) { header("Location: downloader"); } else { echo $mageFilename." was not found"; } exit; } if (file_exists($maintenanceFile)) { include_once dirname(__FILE__) . '/errors/503.php'; exit; } require_once $mageFilename; #Varien_Profiler::enable(); if (isset($_SERVER['MAGE_IS_DEVELOPER_MODE'])) { Mage::setIsDeveloperMode(true); } ini_set('display_errors', 1); umask(0); /* Store or website code */ $mageRunCode = isset($_SERVER['MAGE_RUN_CODE']) ? $_SERVER['MAGE_RUN_CODE'] : ''; /* Run store or run website */ $mageRunType = isset($_SERVER['MAGE_RUN_TYPE']) ? $_SERVER['MAGE_RUN_TYPE'] : 'store'; switch($_SERVER['HTTP_HOST']) { case 'store.baltimoresun.com': $mageRunCode = 'baktimore_sun'; $mageRunType = 'website'; break; case 'store.mcall.com': $mageRunCode = 'morning_call'; $mageRunType = 'website'; break; case 'www.districtwest.com': $mageRunCode = 'disctrict_west'; $mageRunType = 'website'; break; case 'districtwest.com': $mageRunCode = 'disctrict_west'; $mageRunType = 'website'; break; case 'store.latimes.com': $mageRunCode = 'la_times'; $mageRunType = 'website'; break; case 'store.courant.com': $mageRunCode = 'hartford_courant'; $mageRunType = 'website'; break; case 'store.orlandosentinel.com': $mageRunCode = 'orlando_sentinel'; $mageRunType = 'website'; break; case 'store.sun-sentinel.com': $mageRunCode = 'south_florida_sun'; $mageRunType = 'website'; break; case 'store.dailypress.com': $mageRunCode = 'newport_news'; $mageRunType = 'website'; break; case 'store.chicagotribune.com': $mageRunCode = 'chicago_tribune'; $mageRunType = 'website'; break; case 'store.redeyechicago.com': $mageRunCode = 'redeye'; $mageRunType = 'website'; break; case 'store.sandiegouniontribune.com': $mageRunCode = 'sandiego'; $mageRunType = 'website'; break; } Mage::run($mageRunCode, $mageRunType);