How To Free Up Disk Space On Windows 10

how to clean up hard drive - smartupworld.com

Free up Hard drives is a pretty famous topic.As their capacity increased a lot over time, yet somehow they always seem full ? This is even more bothering if you’re using a SSDs, which currently offers way less hard drive space than the others. If you’re looking for ways to …

Read More »

Magento 1x: How to filter Products by attribute & attribute set

You can follow the code : <?php ob_start(); ini_set('max_execution_time', 0); set_time_limit(0); ignore_user_abort(true); require_once '/chroot/home/powerme1/powermedicalsupplies.com/html/app/Mage.php'; Mage::app()->setCurrentStore(Mage_Core_Model_App::ADMIN_STORE_ID); $_write = Mage::getSingleton('core/resource')->getConnection('core_write'); $_read = Mage::getSingleton('core/resource')->getConnection('core_read'); $collection = Mage::getModel('catalog/product')->getCollection()->addAttributeToFilter('attribute_set_id',9)->addAttributeToFilter('brand', array('eq' => 1674)); foreach($collection as $_product): $_product = $_product->load($_product->getId()); echo $_product->getSku() . ' >>> ' . $_product->getUpc() .'<br>'; endforeach; echo '<hr />'; $collection = Mage::getModel('catalog/product')->getCollection()->addAttributeToFilter('attribute_set_id',9)->addAttributeToFilter('brand', array('eq' …

Read More »

Magento 1x: Create a controller & xml layout for the module

If you don’t know how to create a module then see this link. Create a Folder controllers in inside your module path: app\code\local\Trenza\Orderimage\ . Now create a IndexController.php and add bellow code in here. <?php /* * Copyright (c) 2015 www.trenzasoft.com */ class Trenza_Orderimage_IndexController extends Mage_Core_Controller_Front_Action { public function indexAction() { …

Read More »

Create a new table on for you module & connect with model

Go to phpmyadmin and select your magento database. Here go to sql and insert the bellow command. It create a table trz_orderimage which is your table. -- phpMyAdmin SQL Dump -- version 4.5.1 -- http://www.phpmyadmin.net -- -- Host: 127.0.0.1 -- Generation Time: Oct 27, 2017 at 07:59 AM -- Server …

Read More »

Create a new module on magento 1x

Create a magento 1x simple module:  Make sure magento admin panel  system/tools/compilation is disabled. Just need to create a new file on app\etc\modules Trenza_Orderimage.xml <?xml version="1.0"?> <config> <modules> <Trenza_Orderimage> <active>true</active> <codePool>local</codePool> </Trenza_Orderimage> </modules> </config> Here Trenza_Orderimage this is my module identity. Now go to app/code/local/ create a folder Trenza go inside trenza(package …

Read More »

Create a event observer after order submit Magento 1x

Create a event observer after order submit. Bellow code is need to add in your module path/etc/config.xml if you have already adminhtml tag then just ignore adminhtml tag. in bellow code Trenza_Prescription is the module name. and class is the class name of which trigger it do when observer event …

Read More »

Call PHTML from another PHTML Magento 1x

Call a phtml file from another phtml on magento 1x. Please follow the bellow steps there are several way you can call phtml files. When you want to add phtml on same module Then you need to follow this code. Use bellow code on your xml file. If you want …

Read More »

Magento 1x: How to select, insert, update, and delete data from custom table

If you have a custom table which has model Mage::getModel(‘mynews/mynews’); then you can easily insert , select , update & delete data from your table see bellow codes. INSERT DATA $data = array('title'=>'hello there','content'=>'how are you? i am fine over here.','status'=>1); $model = Mage::getModel('mynews/mynews')->setData($data); try { $insertId = $model->save()->getId(); echo …

Read More »