[Magento] How to place a product on sale or special in Magento?

When you go around some online shop, sometime you’ll see products with ribbon ‘Sales‘ or will see two price (1 for original price, 1 for new price) and something like that….

So how to do it in magento?

It’s very esay. I’ll explain step by step in this below:

1. Login to the Magento admin.
2. On the top menu go to ‘Catalog > Manage Products.
3. Click the product on the grid to edit.
4. On the left menu, click ‘Prices‘.
5. (If you only have one store skip this step) On the top left, select the appropriate Store from the drop down.
6. Enter the desired Sale price on the field ‘Special Price‘.
7. If applicable, assign a date range using the fields ‘Special Price From Date’ and ‘Special Price To Date‘.
8. Click Save.
9. On the top menu go to ‘System > Index Management‘.
10. Find “Product Prices” from the grid and hit ‘Reindex Data‘.
11. On the top menu go to ‘System > Cache Management‘.
12. Check the ‘Page Cache’ item, make sure the ‘Actions’ dropdown has a value of ‘Refresh‘, and click Submit.

That’s all.

[Magento] How to remove index.php from URLs?

Working with magento, sometime, you can see index.php appear in URLs of your website url. The index.php appears in your URLs because it is the file responsible for processing all requests to the system. In a URL such as http://example.com/index.php/template_group/template, the template_group/template segments are simply information passed to index.php and do not refer to actual files or folders in the server’s filesystem.

Actually, they are not good for SEO, bad for site structure and consistency, and then they’re even worse for a clean URL freak like me.

Let’s clean it…

1. Log-in to your Mangento administration area the go to ‘System -> Configuration -> Web‘.

2. Navigate to Unsecure’ and Secure’ tabs. Make sure the ‘Unsecure‘ and ‘Secure‘-‘Base Url‘ options have your domain name within it, and do not leave the forward slash off the end of the URL. Example: http://tofuandtomato.com/

3. While still on the ‘Web’ page, navigate to the ‘Search Engine Optimisation‘ tab and select ‘Yes‘ underneath the ‘Use Web Server Rewrites‘ option.

4. Navigate to ‘Secure‘ tab again (if not already on it) and select ‘Yes‘ on the ‘Use Secure URLs FrontEnd‘ option.

5. Now go to the root of Magento website folder and use this code for your .htaccess:

* If your Magento store is installed in root(public_html) , use this:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]

** If your Magento store is installed in a subfolder (public_html/shop), use this:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /shop/
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /shop/index.php [L]

Save the .htaccess and replace the original file (You need backup your original file before replacing).

6. Now go to ‘Cache Management‘ in Administration area to clear Cache.

You are done!

Let’s me know in the comments below if you use this or run into any issues.