If you are puzzled as to why inline translate in Magento is not saving a particular translation, this could be your issue. Inline translate uses the table core_translation to store the translations. The fields that store the data are set to VARCHAR(255) fields. If your source string is longer than 255 characters, it will fail [...]
Archive: magento
If you are migrating from an old ecommerce package into Magento, you may well want to extend Magento's password hashing system so that it can understand the passwords that are hashed by the previous system and customers can log in using their old passwords without any hassle. You would start off by overriding the Mage_Core_Model_Encryption [...]
If you have written your own modules, and need to rearrange the order that your attributes or displayed in, or change anything else, you can use the following SQL statements to fix their order. First you need to get the attribute group that the attributes are under. This can be done by running the following [...]
If you are having performance issues with your Magento store and you are running on a dedicated or VPS server that you think should be up to the task of running your store properly but you continue to have performance problems then this post is for you. Having decent server specification is only the first [...]
So one of our customer's sites started throwing this error message immediately following an upgrade. Illegal scheme supplied, only alphanumeric characters are permitted Turns out 1.6.2.0 doesn't like anything other than a-z and 0-9 in the store run code and the customer in question had underscores (_) in the store run code. The simple fix [...]
If you are developing a Magento store and you would like a method you can call to completely clear everything out that might be cached or indexed etc then you will like this little snippet: PLAIN TEXT PHP: public function flushEverything() { Mage::app()->getCacheInstance()->flush(); Mage::getModel('core/design_package')->cleanMergedJsCss(); [...]
Ideal to drop into a helper, this is a simplified create category method. You need to specify the name, store_id and parent category id and can optionally set to active, anchor and change the display mode if you wish. PLAIN TEXT PHP: public function createCategory($name, $store_id, $parent_id, $active = 0, $anchor = 0, $display_mode='PRODUCTS') { [...]
As we have been working with the various versions of Magento its nice to see more and more use of DocBlock notation to help IDEs auto suggest and auto complete methods etc when working with objects. However the style is inconsistent and with a few subtle tweaks would be much, much better. Template Files, What [...]
Widely regarded as best practice, the use of automated tests to ensure the correct functioning of your web application is a really powerful and useful practice. For Magento it has historically been something that you would need to create yourself. Now Magento have released a comprehensive package of 1000 tests that you can download as [...]
If you are looking at your Layout XML when trying to debug missing blocks for example, you may see the attribute ignore="1" being assigned to chunks of XML. These are set when some module or other is using the remove syntax to remove a block. For example I have just had some issues with Fontis [...]