Category Archives: eCommerce

eCommerce web applications including but not limited to: Magento, OS Commerce, and Zen Cart.

Magento – Adding Image Rollerover Effects to Product Lists

What I’m trying to accomlish is adding a roller over effect to the images.  I want the image to pop up in another layer on rollover.

As always, with any editing of any files that currently already work, make a BACKUP!

I like to copy and paste the file, then rename it .backup

First I add the code to the css file:

Then I want to edit my template file:

Find the line (about line 100-105) that contains:

add the php signs around that and comment it out, then add my following lines:

The image resize function all depends on how you have manento setup and the cache, but this should work.  Feel free leave comments on how this works.

Removing All from Show All Per Page on Magento’s front end

.

Searching low and high, trying every search string i can think of in google. I’ve found nothing. Posting on Magento Commerce’s website i got a response with the answer. Here is the answer:

The file you are looking for is: Mage/Catalog/Block/Product/List/Toolbar.php

In this file at line 530 function getAvailableLimit()

public function getAvailableLimit()
{
if ($this->getCurrentMode() == 'list') {
if (isset($this->_availableLimit['list'])) {
return $this->_availableLimit['list'];
}
$perPageValues = (string)Mage::getStoreConfig('catalog/frontend/list_per_page_values');
$perPageValues = explode(',', $perPageValues);
$perPageValues = array_combine($perPageValues, $perPageValues);
return ($perPageValues /*+ array('all'=>$this->__('All'))*/);
}
elseif ($this->getCurrentMode() == 'grid') {
if (isset($this->_availableLimit['grid'])) {
return $this->_availableLimit['grid'];
}
$perPageValues = (string)Mage::getStoreConfig('catalog/frontend/grid_per_page_values');
$perPageValues = explode(',', $perPageValues);
$perPageValues = array_combine($perPageValues, $perPageValues);
return ($perPageValues /*+ array('all'=>$this->__('All'))*/);
}
return parent::getAvailableLimit();
}

as you can see the

return ($perPageValues /*+ array('all'=>$this->__('All'))*/);

I comment /*+ array(’all’=>$this->__(’All’))*/
now the “All” show anymore ….

Or course you should not change the core but sometime it’s easier then build an override
for it.

You should test it on a development store before !!!!
USE AT YOUR OWN RISK !!!!

Let me know if you have any problem

Your Magento folder does not have sufficient write permissions

.

Error: Please check for sufficient write file permissions

Your Magento folder does not have sufficient write permissions, which this web based downloader requires.

If you wish to proceed downloading Magento packages online, please set all Magento folders to have writable permission for the web server user (example: apache) and press the “Refresh” button to try again.
Refresh

To learn more about setting write permissions, please visit the Magento community site for further details.


Ever seen the above error message?  I have.  Solution’s I’ve found for this are as follows:

I installed magento through SSH as root.  Now the problem with this is all the folders magento creates is now owned by root, so apache or magento cannot change them.  Simple fix.  From what I read off of MagnetoCommerce.com is somebody changed the owner of the downloader folder.   I tried this, it didn’t fix my problem.  Feel free to try this way though.
chown apache downloader/ -hR

I took this a step further since I was still having the same problem.  I did this to the entire website directory

chown apache www/ -hR

Let me know if this works for you.

Moving OS Commerce from php4 to php5

I’m not sure if this fix is due to os commerce mods or just cause it’s needed when migrating a site from php 4 to php 5. After I switched the os commerce site to a new host i had many problems. A few hours and all can be fixed. This is just one of my problems. After moving the site the article link was bring up an error message:

Unknown column ‘a.authors_id’ in ‘on clause’

After google searching I found this fix which seems to work.

If anyone else finds this useful please post here and let me know.

Find the following variable in articles.php and change the query inside from:

$articles_all_query_raw = “select a.articles_id, a.articles_date_added, ad.articles_name, ad.articles_head_desc_tag, au.authors_id, au.authors_name, td.topics_id, td.topics_name from ” . TABLE_ARTICLES . ” a, ” . TABLE_ARTICLES_TO_TOPICS . ” a2t left join ” . TABLE_TOPICS_DESCRIPTION . ” td on a2t.topics_id = td.topics_id left join ” . TABLE_AUTHORS . ” au on a.authors_id = au.authors_id, ” . TABLE_ARTICLES_DESCRIPTION . ” ad where (a.articles_date_available IS NULL or to_days(a.articles_date_available) <= to_days(now())) and a.articles_id = a2t.articles_id and a.articles_status = ‘1’ and a.articles_id = ad.articles_id and ad.language_id = ‘” . (int)$languages_id . “‘ and td.language_id = ‘” . (int)$languages_id . “‘ order by a.articles_date_added desc, ad.articles_name”;

TO:

$articles_all_query_raw = “select a.articles_id, a.articles_date_added, ad.articles_name, ad.articles_head_desc_tag, au.authors_id, au.authors_name, td.topics_id, td.topics_name from ((” . TABLE_ARTICLES . ” a), ” . TABLE_ARTICLES_TO_TOPICS . ” a2t) left join ” . TABLE_TOPICS_DESCRIPTION . ” td on a2t.topics_id = td.topics_id left join ” . TABLE_AUTHORS . ” au on a.authors_id = au.authors_id, ” . TABLE_ARTICLES_DESCRIPTION . ” ad where (a.articles_date_available IS NULL or to_days(a.articles_date_available) <= to_days(now())) and a.articles_id = a2t.articles_id and a.articles_status = ‘1’ and a.articles_id = ad.articles_id and ad.language_id = ‘” . (int)$languages_id . “‘ and td.language_id = ‘” . (int)$languages_id . “‘ order by a.articles_date_added desc, ad.articles_name”;