Step by step learning: Redux-Saga

April 5, 2017

I hope, it will be useful for beginners in `redux-saga` that I come with a small doc.

Please visit:

Step by step learning: Webpack, React.js & Redux

March 10, 2017

For Webpack:

For React & Redux:

React & Redux Lifecycle:

React & Redux Lifecycle

React & Redux Lifecycle

Step by step learning with a small project: node.js, express.js & mongodb

January 4, 2017

– Please use to setup your environment.
– Please use for step by step learning.
– Please use to see the project.

FYI: I used ES6 instead of raw javascript.

Thanks and happy learning 🙂

How to show top selling products on home page in Megento

May 17, 2010

$visibility = array(

$storeId = Mage::app()->getStore()->getId();
$_productCollection = Mage::getResourceModel(‘reports/product_collection’)
->addAttributeToFilter(‘visibility’, $visibility)
->setOrder(‘ordered_qty’, ‘desc’);
<?php foreach ($_productCollection as $_product): ?>
<!– show as you want name, image, etc –>
<a href=”<?php echo $_product->getProductUrl() ?>” title=”<?php echo $this->htmlEscape($_product->getName()) ?>”><?php echo $this->htmlEscape($_product->getName()) ?></a><br />
<?php endforeach ?>

Setup Magento on IIS

May 17, 2010

Step 1: Create a new folder called magento under C:\Inetpub\wwwroot, then copy and put all the files into that folder.

Step 2: Right-click on the newly created magento folder and click on Properties. Then, click on the Security tab. Give full permission to this folder. See below.

Step 3: Please prepare the database now using the .sql file. If you need to change any database configuration settings, please open the C:\Inetpub\wwwroot\magento\app\etc\local.xml file for editing.

Step 4: Using any database editor, please open the database table core_config_data and change two path values

path = web/secure/base_url

value =


path = web/secure/base_url

value =

In both cases, the value should be changed.

Note: You should delete all the files and folders under C:\Inetpub\wwwroot\ magento \var\cache in order to prevent unwanted cache problems.  See below.

Step 5: This is the most important step for running a Magento project under IIS.

Please download ISAPI_Rewrite3_0073_Lite.msi from

See below.

Install this software.

IIS will be automatically restarted after installation.

Verify if the installation was successful by opening up the IIS Manager. Right-click on Web Sites and select Properties. You should now have a new tab if installation was successful. See the screenshot below for reference.

ISAPI Rewrite filter has been successfully installed, but we are not done yet. Your httpd.conf file should be empty, so we need to put some rewrite rules in it. The following lines are taken from the .htaccess file in the root of your Magento installation (that is, the website’s root folder), and put into the httpd.conf file.

So click on Edit, and then you have got a chance to add the following code.

RewriteEngine on

RewriteBase /magento/

RewriteRule .* – [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]

RewriteCond %{REQUEST_URI} !^/(media|skin|js)/

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

RewriteCond %{REQUEST_FILENAME} !-l

RewriteRule .* index.php [L]

See the screenshot below for reference.

Now press Apply (top-left corner of the editor).

You’re done configuring the ISAPI Rewrite filter and can now run the Magento project.

How to add FCKeditor in Symfony

March 10, 2010

1. Download sfWidgetFormTextareaFCKEditor.class.php.docx and save the code inside the doc as sfWidgetFormTextareaFCKEditor.class.php put this file to {Your Project Name}/lib folder.
2. Download FCKEditor (from and unpack it to {Your Project Name}/web/js/fckeditor
3. In the “configure()” method of your form class, configure the fields where you want to use FCKEditor:

$this->widgetSchema[‘address’] = new sfWidgetFormTextareaFCKEditor(
‘width’ => 750,
‘height’ => 350,
‘tool’ => ‘Default’, // name of a configured toolbar
‘config’=> ‘fckeditor/fckconfig.js’ // points to web/js/myfckconfig.js

4. You can customize the configuration for FCKEditor, found in {Your Project Name}/web/js/ fckeditor/fckconfig.js

JoomlaPack 2.2.1 : Failed Smart algorithm on JoomlapackCUBE

July 13, 2009

I was in a big problem that joomlaPack works well in Local but when it’s uploaded in godaddy hosting server, it’s not working anymore. It shows the following message in the log file:

Failed Smart algorithm on JoomlapackCUBEDomainDBBackup
CUBE :: Error occured in domain ‘PackDB
Could not open \home\content\b\e\u\beulaho\html\tmp/1eaffe96 for append, in DB dump.

I searched in google and found lots of solutions but none of them is working for me.

Then edited the following file

So, I just replaced all the DS by ‘//’ in the whole file.

Example, Replace
return $configuration->getTemporaryDirectory().DS.$fileName;
return $configuration->getTemporaryDirectory().‘\\’.$fileName;

That’s all. Special thanks to Riz for giving me Idea.