I'm trying to add animated gifs to my product pages through the admin. I can add them, but when I view them on the front end they just come through as the separate images. How can I fix this?
copy file from the path
app/code/core/Mage/Catalog/Model/Product/Image.php to
path : app/code/local/Mage/Catalog/Model/Product/Image.php (create folders if necessary)
Find the line public function getUrl() and replace the function with:
public function getUrl()
{
$baseDir = Mage::getBaseDir('media');
$file = ('gif' == strtolower(pathinfo($this->_baseFile, PATHINFO_EXTENSION))) ? $this->_baseFile : $this->_newFile;
$path = str_replace($baseDir . DS, "", $file);
return Mage::getBaseUrl('media') . str_replace(DS, '/', $path);
}
edit file on -> .\vendor\magento\module-catalog\Model\View\Asset\Image.php
on function getAbsolutePath($result) and private function getRelativePath($result)