0

This question already has an answer here:

I have One wholesaler folder in magento root in which one index.php file in that file i found this code

/**
 * Compilation includes configuration file
 */
$compilerConfig = 'includes/config.php';
if (file_exists($compilerConfig)) {
    include $compilerConfig;
}

$mageFilename = '../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';

//Mage::run($mageRunCode, $mageRunType);

Mage::run('wholesale', $mageRunType);

I am Upgrading Magento version. My Issue is my site is redirecting on live site when I put Mage::run('wholesale', $mageRunType); instead of //Mage::run($mageRunCode, $mageRunType); in index.php.

Actually, i don't know actual use of $mageRunCode.

marked as duplicate by Teja Bhagavan Kollepara, Piyush, Mohit Kumar Arora, Shoaib Munir, Manashvi Birla May 21 at 5:34

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 1
    Your solution is here : magento.stackexchange.com/questions/71476/… – padhiyar gaurang Sep 5 '17 at 12:07
  • not working @padhiyargaurang – Jaimin Sep 5 '17 at 12:22
  • Hello, i am sure that your entries for web/secure/base_url and web/unsecure/base_url in table core_config_data is pointing to old url. Please remove cache also after this. Use like this select * from where path like '%web/%'; In that entries it will ponting to old url. – padhiyar gaurang Sep 5 '17 at 12:30
0

stoe For this : Actually, i don't know actual use of $mageRunCode.

$mageRunCode = 'your store code'

Magento need store code and store type to run. first param is store code and second ($mageRunType) is type of run website weather as store or webiste.

So $mageRunType is

1) store

or

2) website.

Not the answer you're looking for? Browse other questions tagged or ask your own question.