- Direct download Magento extensions: http://freegento.com/ddl-magento-extension.php
- Delete all orders from database: http://www.codelogbook.com/remove-all-orders-from-magento-database/
- Magereverse http://www.magereverse.com/
<?xml version="1.0" encoding="UTF-8"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="customer_account_navigation">
<block class="Magento\Framework\View\Element\Html\Link\Current" ifconfig="helpdesk/frontend/is_active" name="customer-account-navigation-helpdesk-link">
<arguments>
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
include 'app/Mage.php'; | |
Mage::app(); | |
// clear cache | |
Mage::app()->removeCache('catalog_rules_dirty'); | |
// reindex prices | |
Mage::getModel('index/process')->load(2)->reindexEverything(); | |
/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action( 'save_post', 'my_save_post_function', 10, 3 ); | |
function my_save_post_function( $post_ID, $post, $update ) { | |
$fields=$_POST['fields']; | |
if(isset($_POST['fields']) && $_POST['fields']!=""){ | |
$fields= implode(array_values($fields)); | |
// unhook this function so it doesn't loop infinitely | |
remove_action('save_post', 'my_save_post_function'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Import Database in WAMP: | |
mysql -u username -p database_name < your_sql_file.sql | |
// Export Database in WAMP: | |
mysqldump -u username -p database_name > db_file.sql | |
mysqldump -u db_username -p --compress --disable-keys --quick db_name | gzip > db.sql.gz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$products = Mage::getModel('catalog/product') | |
->getCollection() | |
//->addAttributeToSelect('*') | |
->addAttributeToSelect(array('name', 'thumbnail', 'weight' ,'price','description')) | |
->joinField('qty', | |
'cataloginventory/stock_item', | |
'qty', | |
'product_id=entity_id', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
print '<pre>'; | |
$file = fopen("export_product-2016_11_29-06_05_42-30936353.csv","r"); | |
$count = 0; | |
$varientProduct = array(); | |
$variableProduct = array(); | |
$simpleProduct = array(); | |
$without_Parent_Id = array(); | |
$productArrays = array(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require_once ( "app/Mage.php" ); | |
umask(0); | |
// Initialize Magento | |
Mage::app(); | |
$category = Mage::getModel('catalog/category'); | |
$category->load('24'); // Category id you want to copy | |
$collection = $category->getProductCollection(); |
OlderNewer