-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest.php
More file actions
28 lines (19 loc) · 676 Bytes
/
test.php
File metadata and controls
28 lines (19 loc) · 676 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<?php
chdir(dirname(__FILE__));
require 'app/bootstrap.php';
require 'app/Mage.php';
Mage::setIsDeveloperMode(true);
ini_set('display_errors', 1);
umask(0);
$mageRunCode = isset($_SERVER['MAGE_RUN_CODE']) ? $_SERVER['MAGE_RUN_CODE'] : '';
$mageRunType = isset($_SERVER['MAGE_RUN_TYPE']) ? $_SERVER['MAGE_RUN_TYPE'] : 'store';
Mage::app();
/***********************************/
//If I need to run script as Admin:
//Mage::app()->setCurrentStore(Mage_Core_Model_App::ADMIN_STORE_ID);
try {
#Place your code here
} catch (Exception $exc) {
var_dump($exc->getMessage());
echo $exc->getTraceAsString();
}