Skip to content

Instantly share code, notes, and snippets.

@asifsomy
Forked from redesigned/functions.php
Last active August 29, 2015 14:27
Show Gist options
  • Select an option

  • Save asifsomy/908f6934ee416cf9a99c to your computer and use it in GitHub Desktop.

Select an option

Save asifsomy/908f6934ee416cf9a99c to your computer and use it in GitHub Desktop.

Revisions

  1. asifsomy revised this gist Aug 19, 2015. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion index.php
    Original file line number Diff line number Diff line change
    @@ -1,6 +1,6 @@
    /* ===================================== */
    /* Add This to Magento's /index.php file */
    if (strpos($_SERVER[REQUEST_URI],'admin') == false && strpos($_SERVER[REQUEST_URI],'media') == false) {
    if (strpos($_SERVER['REQUEST_URI'],'admin') == false && strpos($_SERVER['REQUEST_URI'],'media') == false) {
    define('WORDPRESS_ROOT', '/home/thegreet/thegreetingfarm.com/html/staging/');
    define('WORDPRESS_LOADER', WORDPRESS_ROOT.'wp-load.php');
    require_once(WORDPRESS_LOADER);
  2. @redesigned redesigned revised this gist Nov 5, 2014. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion index.php
    Original file line number Diff line number Diff line change
    @@ -1,6 +1,6 @@
    /* ===================================== */
    /* Add This to Magento's /index.php file */
    if (strpos($_SERVER[REQUEST_URI],'admin') !== false && strpos($_SERVER[REQUEST_URI],'media') !== false) {
    if (strpos($_SERVER[REQUEST_URI],'admin') == false && strpos($_SERVER[REQUEST_URI],'media') == false) {
    define('WORDPRESS_ROOT', '/home/thegreet/thegreetingfarm.com/html/staging/');
    define('WORDPRESS_LOADER', WORDPRESS_ROOT.'wp-load.php');
    require_once(WORDPRESS_LOADER);
  3. @redesigned redesigned revised this gist Nov 5, 2014. 1 changed file with 5 additions and 3 deletions.
    8 changes: 5 additions & 3 deletions index.php
    Original file line number Diff line number Diff line change
    @@ -1,6 +1,8 @@
    /* ===================================== */
    /* Add This to Magento's /index.php file */
    define('WORDPRESS_ROOT', '/Volumes/Storage/www/heartandsun/');
    define('WORDPRESS_LOADER', WORDPRESS_ROOT.'wp-load.php');
    require_once(WORDPRESS_LOADER);
    if (strpos($_SERVER[REQUEST_URI],'admin') !== false && strpos($_SERVER[REQUEST_URI],'media') !== false) {
    define('WORDPRESS_ROOT', '/home/thegreet/thegreetingfarm.com/html/staging/');
    define('WORDPRESS_LOADER', WORDPRESS_ROOT.'wp-load.php');
    require_once(WORDPRESS_LOADER);
    };
    /* ===================================== */
  4. @redesigned redesigned revised this gist Apr 22, 2014. 1 changed file with 0 additions and 14 deletions.
    14 changes: 0 additions & 14 deletions upgrade_table_drops.sql
    Original file line number Diff line number Diff line change
    @@ -1,14 +0,0 @@
    Truncate table dataflow_batch_export;
    Truncate table dataflow_batch_import;
    Truncate table log_customer;
    Truncate table log_quote;
    Truncate table log_summary;
    Truncate table log_summary_type;
    Truncate table log_url;
    Truncate table log_url_info;
    Truncate table log_visitor;
    Truncate table log_visitor_info;
    Truncate table log_visitor_online;
    Truncate table report_viewed_product_index;
    Truncate table report_compared_product_index;
    Truncate table report_event;
  5. @redesigned redesigned revised this gist Apr 22, 2014. 1 changed file with 14 additions and 0 deletions.
    14 changes: 14 additions & 0 deletions upgrade_table_drops.sql
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,14 @@
    Truncate table dataflow_batch_export;
    Truncate table dataflow_batch_import;
    Truncate table log_customer;
    Truncate table log_quote;
    Truncate table log_summary;
    Truncate table log_summary_type;
    Truncate table log_url;
    Truncate table log_url_info;
    Truncate table log_visitor;
    Truncate table log_visitor_info;
    Truncate table log_visitor_online;
    Truncate table report_viewed_product_index;
    Truncate table report_compared_product_index;
    Truncate table report_event;
  6. @redesigned redesigned renamed this gist Jul 16, 2013. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  7. @redesigned redesigned revised this gist Jul 16, 2013. No changes.
  8. @redesigned redesigned renamed this gist Jul 16, 2013. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  9. @redesigned redesigned renamed this gist Jul 16, 2013. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  10. @redesigned redesigned renamed this gist Jul 16, 2013. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  11. @redesigned redesigned revised this gist Jul 16, 2013. 1 changed file with 2 additions and 4 deletions.
    6 changes: 2 additions & 4 deletions functions
    Original file line number Diff line number Diff line change
    @@ -1,10 +1,8 @@
    /* ===================================== */
    /*
    /* ===================================== *//*
    // # Copy /app/code/core/Mage/Core/functions.php to /app/code/local/Mage/Core/functions.php
    // # and wrap the __() function in an if_exists to prevent conflicts between both platforms
    // # translator functions.
    */
    /* ===================================== */
    *//* ===================================== */
    if (!function_exists('__')) {
    function __() { return Mage::app()->getTranslator()->translate(func_get_args()); }
    };
  12. @redesigned redesigned revised this gist Jul 16, 2013. 1 changed file with 6 additions and 3 deletions.
    9 changes: 6 additions & 3 deletions functions
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,10 @@
    /* ===================================== *//*
    /* ===================================== */
    /*
    // # Copy /app/code/core/Mage/Core/functions.php to /app/code/local/Mage/Core/functions.php
    // # and wrap the __() function in an if_exists to prevent conflicts between both platforms translator functions.
    *//* =================================== */
    // # and wrap the __() function in an if_exists to prevent conflicts between both platforms
    // # translator functions.
    */
    /* ===================================== */
    if (!function_exists('__')) {
    function __() { return Mage::app()->getTranslator()->translate(func_get_args()); }
    };
  13. @redesigned redesigned revised this gist Jul 16, 2013. No changes.
  14. @redesigned redesigned revised this gist Jul 16, 2013. 1 changed file with 2 additions and 0 deletions.
    2 changes: 2 additions & 0 deletions functions
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,7 @@
    /* ===================================== *//*
    // # Copy /app/code/core/Mage/Core/functions.php to /app/code/local/Mage/Core/functions.php
    // # and wrap the __() function in an if_exists to prevent conflicts between both platforms translator functions.
    *//* =================================== */
    if (!function_exists('__')) {
    function __() { return Mage::app()->getTranslator()->translate(func_get_args()); }
    };
  15. @redesigned redesigned revised this gist Jul 16, 2013. 1 changed file with 2 additions and 1 deletion.
    3 changes: 2 additions & 1 deletion functions
    Original file line number Diff line number Diff line change
    @@ -1,4 +1,5 @@
    // # Copy /app/code/core/Mage/Core/functions.php to /app/code/local/Mage/Core/functions.php and wrap the __() function in an if_exists to prevent conflicts between both platforms translator functions.
    // # Copy /app/code/core/Mage/Core/functions.php to /app/code/local/Mage/Core/functions.php
    // # and wrap the __() function in an if_exists to prevent conflicts between both platforms translator functions.
    if (!function_exists('__')) {
    function __() { return Mage::app()->getTranslator()->translate(func_get_args()); }
    };
  16. @redesigned redesigned created this gist Jul 16, 2013.
    4 changes: 4 additions & 0 deletions functions
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,4 @@
    // # Copy /app/code/core/Mage/Core/functions.php to /app/code/local/Mage/Core/functions.php and wrap the __() function in an if_exists to prevent conflicts between both platforms translator functions.
    if (!function_exists('__')) {
    function __() { return Mage::app()->getTranslator()->translate(func_get_args()); }
    };
    10 changes: 10 additions & 0 deletions functions.php
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,10 @@
    /* ===================================== */
    /* Add This to Wordpress's /wp-content/yourtheme/functions.php file */
    define('MAGENTO_ROOT', '/Volumes/Storage/www/heartandsun/store/');
    define('MAGENTO_LOADER', MAGENTO_ROOT.'app/Mage.php');
    if (!class_exists('Mage')) {
    require_once(MAGENTO_LOADER);
    umask(0);
    Mage::app("default");
    };
    /* ===================================== */
    6 changes: 6 additions & 0 deletions index.php
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,6 @@
    /* ===================================== */
    /* Add This to Magento's /index.php file */
    define('WORDPRESS_ROOT', '/Volumes/Storage/www/heartandsun/');
    define('WORDPRESS_LOADER', WORDPRESS_ROOT.'wp-load.php');
    require_once(WORDPRESS_LOADER);
    /* ===================================== */