<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Asia Connect Technology JSC &#187; Magento Programming</title>
	<atom:link href="http://asia-connect.com.vn/tag/magento-programming/feed/" rel="self" type="application/rss+xml" />
	<link>http://asia-connect.com.vn</link>
	<description>The place for connecting you to the success</description>
	<lastBuildDate>Fri, 12 Mar 2010 03:49:02 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>Escape from EAV the Magento way</title>
		<link>http://asia-connect.com.vn/2009/10/escape-from-eav-the-magento-way/</link>
		<comments>http://asia-connect.com.vn/2009/10/escape-from-eav-the-magento-way/#comments</comments>
		<pubDate>Wed, 21 Oct 2009 02:49:50 +0000</pubDate>
		<dc:creator>lydh</dc:creator>
				<category><![CDATA[Magento Guide]]></category>
		<category><![CDATA[Magento How To]]></category>
		<category><![CDATA[Magento Programming]]></category>
		<category><![CDATA[Magento Tips]]></category>

		<guid isPermaLink="false">http://asia-connect.com.vn/?p=1035</guid>
		<description><![CDATA[

One of the differences between Magento eCommerce platform and lets say WordPress, when looked from developer point of view, is “avoid raw queries” approach. For a web application, Magento is massive system. His database, although not so massive but surely breathtaking with around 220 tables forces you to use “eye candy” EAV model to do even simple things.
For instance, if I were to tell you that I want you to retrieve 5 simple products from database that have price in the range of 200-600USD you would most likely spent 1-4 ...


Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/07/how-to-install-sample-data-for-magento/' rel='bookmark' title='Permanent Link: How to Install Sample Data for Magento?'>How to Install Sample Data for Magento?</a></li><li><a href='http://asia-connect.com.vn/2009/09/magento-mysql-database-diagram/' rel='bookmark' title='Permanent Link: Magento MySQL database diagram'>Magento MySQL database diagram</a></li><li><a href='http://asia-connect.com.vn/2009/07/improving-magento-speed-performance-with-mysql-query-cache/' rel='bookmark' title='Permanent Link: Improving Magento Speed &#038; Performance With MySQL Query Cache'>Improving Magento Speed &#038; Performance With MySQL Query Cache</a></li></ol>]]></description>
			<content:encoded><![CDATA[<h2></h2>
<p><img title="Escape from EAV the Magento way" src="http://inchoo.net/wp-content/uploads/2009/06/escape.jpg" alt="Escape from EAV the Magento way" width="585" /></p>
<p>One of the differences between <a rel="nofollow" href="http://www.magentocommerce.com" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.magentocommerce.com');"  class="alinks_links" onclick="return alinks_click(this);" title="Magento eCommerce"  style="padding-right: 13px; background: url(http://asia-connect.com.vn/wp-content/plugins/alinks/images/external.png) center right no-repeat;" rel="external">Magento</a> eCommerce platform and lets say WordPress, when looked from developer point of view, is “avoid raw queries” approach. For a web application, Magento is massive system. His database, although not so massive but surely breathtaking with around 220 tables forces you to use “eye candy” EAV model to do even simple things.</p>
<p>For instance, if I were to tell you that I want you to retrieve 5 simple products from database that have price in the range of 200-600USD you would most likely spent 1-4 hours trying to work out the query. In the end you would be lucky if you even get the query that wont break on next Magento upgrade. Let me just remind you on some of the things you need to be careful in example above.</p>
<p>Your query would have to take in consideration the at least the following states: is my product visibility such that it can be seen in Catalog and search result, is my product enabled or disabled, is is out of stock, which website and store view has it been assigned, is it assigned to only one category and that category is disabled by some chance, does it have special price assigned, does it have promotion rules assigned, does it have content (descriptions) for multilingual site assigned.</p>
<p>All of those and more are questions that one has to take into consideration when doing raw database queries. It makes no sense to create query that fetches product and all its appropriate info (price, quantity, description…) if that product is disabled or assigned to category that is disabled. For instance, if you need “featured” product functionality and you manually create raw query that extracts one “featured” product to lets say home page. There you create nice block holding all the necessary info of the product with a link for lets say “Add to cart” or “View product”. Clicking one of those two link would give you most likely 404 if the product is disable or any other condition that enables the product to be shown is disabled.</p>
<p>So basically, raw SQL queries in Magento are a “no no” for most of the time. Too much work and you never know what they will change in future upgrades. Which brings me to this new trend of theirs which I like to call “Escape from EAV”.</p>
<p><a rel="nofollow" title="The Soul is trying to escape from Hell // The Gates of Hell" href="http://en.wikipedia.org/wiki/The_Gates_of_Hell" onclick="javascript:pageTracker._trackPageview('/outbound/article/en.wikipedia.org');" target="_blank"><img title="Gates of Hell" src="http://inchoo.net/wp-content/uploads/2009/06/gates_of_hell.jpg" alt="Gates of Hell" width="310" height="324" /></a>EAV, also know as Entity Attribute Value was suppose to bee (or is) the next big thing in OOP. Anyhow, Magento and his way of EAV have two huge downfalls called LACK OF DOCUMENTATION and WHAT WILL THEY CHANGE IN NEXT UPGRADE. The other day I was working on a Magento shop that had 22 000 products. Almost all of them were simple products, just about 600 were grouped. The store was initially installed on Magento 1.2 version. Site was pretty much 95% complete from both graphic and development perspective. Anyhow, Magento version 1.3.1 was released and on client demand we decide to to upgrade. Important thing to keep in mind is that in version 1.3 Magento introduce “change in philosophy” concerning the EAV model.</p>
<p>Altough EAV sounds great (and really is great for most of the time), it can really slow things down with all those JOINS executed on database. So the Magento team decided to do a little flat tabling. Basically we now have massive data duplication in MySQL where data is taken from various tables and copied int one, the flat table. Flat tables were introduced for both Products and categories, in regards to various website and store views.</p>
<p>Basically Magento has the power to “on the fly” create tables and do the “magical” copying of data from various tables to the flat tables. I assume they were looking for a faster way to “assemble” Product objects in Magento which in turn should boost the speed of collection object i grew so found about. I can live with duplicated data in database, I mean I am not the one writing them down. But let me get back to real world scenario.</p>
<p>As I mentioned, store I have been working on had more than 20 000 products. Due to limitations of both MySQL and PHP failed to do Rebuilt that you can find in System &gt; Configuration &gt; Cache management. This failure caused corrupted data in database. This manifested with “empty” attributes (attributes not showing up in Layered navigation). I resolved the issue by “re saving” all of the 20 000 product with custom script I wrote. After that i noticed the data in flat tables got rebuild as well. This of course took several hours. Magento EAV model seems OK on paper, but with store that hold’s large number of products it simply does not work, at least not in way in which their collection objects are built. Changes introduced in form of flat tables in versions 1.3 should, to some extent, improve work with stores that have large numbers of products. However this improvement seems to come in form of “copy all data from scattered tables to single flat table”.</p>
<p>Solutions like these are nightmare when it comes to upgrading the store that already has large number of products in. System is expected to handle part of the job transparently but it failed, leaving the client with corrupted database.</p>
<p>So, a word of advice for upgrading an existing Magento store: NEVER do it on live site. Let professional developer transfer live site and database to his dev machine, or make a copy on some sub folder on live site. Magento’s extreme out of the box feature rich capabilities, open source philosophy and good marketing have made it extremely popular but be careful, free is such a a loose term.</p>
<p>I am really anxious to see the future path of EAV vs Flat model in Magento.</p>
<p style="text-align: right;"><em>By</em> <span>Branko Ajzele</span> <em>from <a rel="nofollow" href="http://inchoo.net/ecommerce/magento/escape-from-eav-the-magento-way/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');" target="_blank">Inchoo.net</a></em></p>


<p>Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/07/how-to-install-sample-data-for-magento/' rel='bookmark' title='Permanent Link: How to Install Sample Data for Magento?'>How to Install Sample Data for Magento?</a></li><li><a href='http://asia-connect.com.vn/2009/09/magento-mysql-database-diagram/' rel='bookmark' title='Permanent Link: Magento MySQL database diagram'>Magento MySQL database diagram</a></li><li><a href='http://asia-connect.com.vn/2009/07/improving-magento-speed-performance-with-mysql-query-cache/' rel='bookmark' title='Permanent Link: Improving Magento Speed &#038; Performance With MySQL Query Cache'>Improving Magento Speed &#038; Performance With MySQL Query Cache</a></li></ol></p>]]></content:encoded>
			<wfw:commentRss>http://asia-connect.com.vn/2009/10/escape-from-eav-the-magento-way/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Magento block caching</title>
		<link>http://asia-connect.com.vn/2009/10/magento-block-caching/</link>
		<comments>http://asia-connect.com.vn/2009/10/magento-block-caching/#comments</comments>
		<pubDate>Tue, 20 Oct 2009 01:48:05 +0000</pubDate>
		<dc:creator>lydh</dc:creator>
				<category><![CDATA[Magento Guide]]></category>
		<category><![CDATA[Magento Development]]></category>
		<category><![CDATA[Magento Programming]]></category>
		<category><![CDATA[Magento Tips]]></category>

		<guid isPermaLink="false">http://asia-connect.com.vn/?p=1026</guid>
		<description><![CDATA[Recently we were working on speeding up parts of client site which had usual problem of slow page loading caused by complicated configurable products. To solve the problem we were experimenting with extending core Magento caching capabilities.
Magento has built in predifined system of block output caching. Its block abstract has Zend_Cache caching capabilities that can be modified for your own needs. I’m showing here an example of caching whole product view block, however this is just a specific example of how things works, problems are different and requires different approach ...


Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/07/some-custom-blocks-to-help-you-show-products/' rel='bookmark' title='Permanent Link: Some custom Blocks to help you show products'>Some custom Blocks to help you show products</a></li><li><a href='http://asia-connect.com.vn/2009/07/top-3-solutions-when-your-magento-categories-are-not-displaying/' rel='bookmark' title='Permanent Link: Top 3 Solutions when your Magento Categories are not displaying'>Top 3 Solutions when your Magento Categories are not displaying</a></li><li><a href='http://asia-connect.com.vn/2009/09/bestseller-module-with-toolbar-%e2%80%93-magento-1-2-1/' rel='bookmark' title='Permanent Link: Bestseller module (with Toolbar!) – Magento 1.2.1'>Bestseller module (with Toolbar!) – Magento 1.2.1</a></li></ol>]]></description>
			<content:encoded><![CDATA[<p>Recently we were working on speeding up parts of client site which had usual problem of slow page loading caused by complicated configurable products. To solve the problem we were experimenting with extending core <a rel="nofollow" href="http://www.magentocommerce.com" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.magentocommerce.com');"  class="alinks_links" onclick="return alinks_click(this);" title="Magento eCommerce"  style="padding-right: 13px; background: url(http://asia-connect.com.vn/wp-content/plugins/alinks/images/external.png) center right no-repeat;" rel="external">Magento</a> caching capabilities.</p>
<p>Magento has built in predifined system of block output caching. Its block abstract has Zend_Cache caching capabilities that can be modified for your own needs. I’m showing here an example of caching whole product view block, however this is just a specific example of how things works, problems are different and requires different approach and solution.</p>
<p>I will start with some external reading and example itself. There is great article on Magento Wiki about this topic, along with category cache example on Magento forums.</p>
<p>With my Inchoo_BlockCaching.rar example module things should be little easier to understand.</p>
<p>Magento block caching depends of three things:<br />
cache_lifetime =&gt; cache lifetime in seconds<br />
cache_tags =&gt; cache type identifiers primarly used for deleting right cache at the right time<br />
cache_key =&gt; cache identyfier</p>
<p>You can simply inject this data into construtor of any Magento block</p>
<pre class="brush: php;">
protected function _construct()
{
$this-&gt;addData(array(
'cache_lifetime' =&gt; 3600,
'cache_tags'     =&gt; array(Mage_Catalog_Model_Product::CACHE_TAG),
'cache_key'      =&gt; $this-&gt;getProduct()-&gt;getId(),
));
}
</pre>
<p>or if you need some conditional approach like i did in this example define equivalent functions</p>
<pre class="brush: php;">
public function getCacheKey(){}
public function getCacheLifetime(){}
public function getCacheTags(){}
</pre>
<p style="text-align: right;"><em>By</em> <span>Ivan Weiler</span><em> from <a rel="nofollow" href="http://inchoo.net/ecommerce/magento/magento-block-caching/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');" target="_blank">Inchoo.net</a></em></p>
<pre style="text-align: left;"></pre>


<p>Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/07/some-custom-blocks-to-help-you-show-products/' rel='bookmark' title='Permanent Link: Some custom Blocks to help you show products'>Some custom Blocks to help you show products</a></li><li><a href='http://asia-connect.com.vn/2009/07/top-3-solutions-when-your-magento-categories-are-not-displaying/' rel='bookmark' title='Permanent Link: Top 3 Solutions when your Magento Categories are not displaying'>Top 3 Solutions when your Magento Categories are not displaying</a></li><li><a href='http://asia-connect.com.vn/2009/09/bestseller-module-with-toolbar-%e2%80%93-magento-1-2-1/' rel='bookmark' title='Permanent Link: Bestseller module (with Toolbar!) – Magento 1.2.1'>Bestseller module (with Toolbar!) – Magento 1.2.1</a></li></ol></p>]]></content:encoded>
			<wfw:commentRss>http://asia-connect.com.vn/2009/10/magento-block-caching/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>CoolDash – Blank Magento extension for building admin system configuration area</title>
		<link>http://asia-connect.com.vn/2009/10/cooldash-%e2%80%93-blank-magento-extension-for-building-admin-system-configuration-area/</link>
		<comments>http://asia-connect.com.vn/2009/10/cooldash-%e2%80%93-blank-magento-extension-for-building-admin-system-configuration-area/#comments</comments>
		<pubDate>Wed, 14 Oct 2009 03:29:50 +0000</pubDate>
		<dc:creator>lydh</dc:creator>
				<category><![CDATA[Magento Customization]]></category>
		<category><![CDATA[Magento Guide]]></category>
		<category><![CDATA[Magento Development]]></category>
		<category><![CDATA[Magento Programming]]></category>
		<category><![CDATA[Magento Tips]]></category>

		<guid isPermaLink="false">http://asia-connect.com.vn/?p=976</guid>
		<description><![CDATA[
In order to speed things up with building admin sections under System &#62; Configuration area in Magento I wrote a little blank extension. Hopefully its a step or two beyond “Hello world” level. I named the extension “CoolDash”, short from CoolDashboard. Name holds no special meaning, just something I popped out of my head. First thing you might notice when you open config.xmls and system.xml is the attribute naming. I intentionally used names like “somecooldashmodel2″. I found it extremely difficult, error prone and annoying to get around in scenarios where ...


Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/10/getting-started-with-building-admin-module-in-magento/' rel='bookmark' title='Permanent Link: Getting started with building Admin module in Magento'>Getting started with building Admin module in Magento</a></li><li><a href='http://asia-connect.com.vn/2009/09/access-denied-in-magento-admin/' rel='bookmark' title='Permanent Link: Access denied in Magento admin'>Access denied in Magento admin</a></li><li><a href='http://asia-connect.com.vn/2009/07/php-extension-error-while-installing-magento/' rel='bookmark' title='Permanent Link: PHP extension error while installing Magento'>PHP extension error while installing Magento</a></li></ol>]]></description>
			<content:encoded><![CDATA[<p><img title="CoolDash – Blank Magento extension for building admin system configuration area" src="http://inchoo.net/wp-content/uploads/2009/08/cooldash.jpg" alt="CoolDash – Blank Magento extension for building admin system configuration area" width="585" /></p>
<p>In order to speed things up with building admin sections under System &gt; Configuration area in <a rel="nofollow" href="http://www.magentocommerce.com" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.magentocommerce.com');"  class="alinks_links" onclick="return alinks_click(this);" title="Magento eCommerce"  style="padding-right: 13px; background: url(http://asia-connect.com.vn/wp-content/plugins/alinks/images/external.png) center right no-repeat;" rel="external">Magento</a> I wrote a little blank extension. Hopefully its a step or two beyond “Hello world” level. I named the extension “CoolDash”, short from CoolDashboard. Name holds no special meaning, just something I popped out of my head. First thing you might notice when you open config.xmls and system.xml is the attribute naming. I intentionally used names like “somecooldashmodel2″. I found it extremely difficult, error prone and annoying to get around in scenarios where different areas of config files use same names for attributes with different meaning, like “customer”, “catalog” and so on.</p>
<p>Hopefully my “funny” naming scheme in config files will give you a better overview on where everything goes. Below are few screenshots to see the result.</p>
<p><a href="http://inchoo.net/wp-content/uploads/2009/08/SystemConfAdminArea.png"  rel="nofollow"  onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');"  class="thickbox noicon" title="SystemConfAdminArea"><img title="SystemConfAdminArea" src="http://inchoo.net/wp-content/uploads/2009/08/SystemConfAdminArea-150x132.png" alt="SystemConfAdminArea" width="150" height="132" /></a></p>
<p><a rel="nofollow" href="http://inchoo.net/wp-content/uploads/2009/08/ActiveCodeline_CoolDash.zip" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');">Download ActiveCodeline_CoolDash</a>.<em>Blank extension for building “System &gt; Configuration” area of Magento admin interface</em>. Although built on Magento 1.4alpha, should work on Magento 1.3.</p>
<p>Hope it helps.</p>
<p style="text-align: right;"><span><em>By</em> Branko Ajzele <em>from <a rel="nofollow" href="http://inchoo.net/ecommerce/magento/cooldash-blank-magento-extension-for-building-admin-system-configuration-area/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');" target="_blank">Inchoo.net</a></em><br />
</span></p>


<p>Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/10/getting-started-with-building-admin-module-in-magento/' rel='bookmark' title='Permanent Link: Getting started with building Admin module in Magento'>Getting started with building Admin module in Magento</a></li><li><a href='http://asia-connect.com.vn/2009/09/access-denied-in-magento-admin/' rel='bookmark' title='Permanent Link: Access denied in Magento admin'>Access denied in Magento admin</a></li><li><a href='http://asia-connect.com.vn/2009/07/php-extension-error-while-installing-magento/' rel='bookmark' title='Permanent Link: PHP extension error while installing Magento'>PHP extension error while installing Magento</a></li></ol></p>]]></content:encoded>
			<wfw:commentRss>http://asia-connect.com.vn/2009/10/cooldash-%e2%80%93-blank-magento-extension-for-building-admin-system-configuration-area/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to make TinyMCE work with Magento CMS pages</title>
		<link>http://asia-connect.com.vn/2009/10/how-to-make-tinymce-work-with-magento-cms-pages/</link>
		<comments>http://asia-connect.com.vn/2009/10/how-to-make-tinymce-work-with-magento-cms-pages/#comments</comments>
		<pubDate>Mon, 12 Oct 2009 03:08:40 +0000</pubDate>
		<dc:creator>lydh</dc:creator>
				<category><![CDATA[Magento Customization]]></category>
		<category><![CDATA[Magento Guide]]></category>
		<category><![CDATA[Magento Development]]></category>
		<category><![CDATA[Magento How To]]></category>
		<category><![CDATA[Magento Programming]]></category>

		<guid isPermaLink="false">http://asia-connect.com.vn/?p=954</guid>
		<description><![CDATA[
Latest version of Magento, as of time of this writing, is 1.3.2.3. Latest, as well as previous versions come with “half-packed” support for TinyMCE editor. There are however few bugs and few steps that need to be handled in order to enable wysiwyg editing in CMS pages. Personally I am not that big of a fan of wysiwyg editors, mostly because I am developer and like to know what I write down.
However, most of the store owners are not developers or even not that much technically savvy people (not that ...


Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/07/how-to-add-dynamic-content-to-magento-static-blocks-and-pages/' rel='bookmark' title='Permanent Link: How to Add Dynamic Content to Magento Static Blocks and Pages?'>How to Add Dynamic Content to Magento Static Blocks and Pages?</a></li><li><a href='http://asia-connect.com.vn/2009/07/tips-for-creating-dynamic-category-landing-pages/' rel='bookmark' title='Permanent Link: Tips For Creating Dynamic Category Landing Pages'>Tips For Creating Dynamic Category Landing Pages</a></li><li><a href='http://asia-connect.com.vn/2009/09/how-to-fix-the-magento-out-of-stock-bug-version-1-1-x/' rel='bookmark' title='Permanent Link: How to fix the Magento Out of stock bug, version 1.1.x'>How to fix the Magento Out of stock bug, version 1.1.x</a></li></ol>]]></description>
			<content:encoded><![CDATA[<p><img title="How to make TinyMCE work with Magento CMS pages" src="http://inchoo.net/wp-content/uploads/2009/07/tinymce.png" alt="How to make TinyMCE work with Magento CMS pages" width="585" /></p>
<p>Latest version of <a rel="nofollow" href="http://www.magentocommerce.com" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.magentocommerce.com');"  class="alinks_links" onclick="return alinks_click(this);" title="Magento eCommerce"  style="padding-right: 13px; background: url(http://asia-connect.com.vn/wp-content/plugins/alinks/images/external.png) center right no-repeat;" rel="external">Magento</a>, as of time of this writing, is 1.3.2.3. Latest, as well as previous versions come with “half-packed” support for TinyMCE editor. There are however few bugs and few steps that need to be handled in order to enable <strong>wysiwyg</strong> editing in CMS pages. Personally I am not that big of a fan of <strong>wysiwyg</strong> editors, mostly because I am developer and like to know what I write down.</p>
<p>However, most of the store owners are not developers or even not that much technically savvy people (not that this is a bad thing) and they could use <strong>wysiwyg</strong> editors when adding, modifying content.</p>
<p>Here I will walk you trough few simple steps that will make you enable <strong>wysiwyg</strong> editing by using TinyMCE. You can see the screenshots of final result below.</p>
<p><a href="http://inchoo.net/wp-content/uploads/2009/07/TinyMCE.png"  rel="nofollow"  onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');"  class="thickbox noicon" title="TinyMCE"><img title="TinyMCE" src="http://inchoo.net/wp-content/uploads/2009/07/TinyMCE-150x110.png" alt="TinyMCE" width="150" height="110" /></a></p>
<p>Step 1: <a rel="nofollow" href="http://tinymce.moxiecode.com/download.php" onclick="javascript:pageTracker._trackPageview('/outbound/article/tinymce.moxiecode.com');">Download</a> and unpack TinyMCE to root /js folder. Two things to keep in mind here. Download regular version (not jQuery version) of TinyMCE. This is due to the fact that Magento uses Prototype, so we need to avoid conflicts. Second, watch out for unpack location. Your tiny_mce.js file should be accessible on js/tiny_mce/tiny_mce.js path.</p>
<p>Step 2: Open the app/code/core/Mage/Adminhtml/Block/Cms/Page/Edit/Tab/Main.php file. Locate the</p>
<pre class="brush: html;">
$fieldset-&gt;addField('content', 'editor', array(
'name'      =&gt; 'content',
'label'     =&gt; Mage::helper('cms')-&gt;__('Content'),
'title'     =&gt; Mage::helper('cms')-&gt;__('Content'),
'style'     =&gt; 'height:36em;',
'wysiwyg'   =&gt; false,
'required'  =&gt; true,
));
</pre>
<p>and change it to</p>
<pre class="brush: html;">
$fieldset-&gt;addField('content', 'editor', array(
'name'      =&gt; 'content',
'label'     =&gt; Mage::helper('cms')-&gt;__('Content'),
'title'     =&gt; Mage::helper('cms')-&gt;__('Content'),
'style'     =&gt; 'height:36em;',
'wysiwyg'   =&gt; true,
'theme' =&gt; 'advanced',
'required'  =&gt; true,
));
</pre>
<p>As you can see, here we changed on existing attribute (’wysiwyg’) value and added new attribute ‘theme’.</p>
<p>Step 3: Open the /lib/Varien/Data/Form/Element/Editor.php file and locate the method <em>getElementHtml()</em>. Here we change</p>
<pre class="brush: html;">
$html = '
&lt;textarea name=&quot;'.$this-&gt;getName().'&quot; title=&quot;'.$this-&gt;getTitle().'&quot; id=&quot;'.$this-&gt;getHtmlId().'&quot; '.$this-&gt;serialize($this-&gt;getHtmlAttributes()).' &gt;'.$this-&gt;getEscapedValue().'&lt;/textarea&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
//&lt; ![CDATA[
/* tinyMCE.init({
mode : &quot;exact&quot;,
theme : &quot;'.$this-&gt;getTheme().'&quot;,
elements : &quot;' . $element . '&quot;,
theme_advanced_toolbar_location : &quot;top&quot;,
theme_advanced_toolbar_align : &quot;left&quot;,
theme_advanced_path_location : &quot;bottom&quot;,
extended_valid_elements : &quot;a[name|href|target|title|onclick],img[class|src|border=0|alt|title|hspace|vsp
theme_advanced_resizing : &quot;false&quot;,
apply_source_formatting : &quot;true&quot;,
convert_urls : &quot;false&quot;,
force_br_newlines : &quot;true&quot;,
doctype : \'&lt; !DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&quot;&gt;\'
});*/
//]]&gt;
&lt;/script&gt;';
</pre>
<p>to</p>
<pre class="brush: html;">
$_storeBaseUrl = str_replace('index.php', '', Mage::getBaseUrl());

//Just to test retrieved url
//echo '$_storeBaseUrl: '.$_storeBaseUrl;

$html = '
&lt;textarea name=&quot;'.$this-&gt;getName().'&quot; title=&quot;'.$this-&gt;getTitle().'&quot; id=&quot;'.$this-&gt;getHtmlId().'&quot; '.$this-&gt;serialize($this-&gt;getHtmlAttributes()).' &gt;'.$this-&gt;getEscapedValue().'&lt;/textarea&gt;
&lt;script language=&quot;javascript&quot; type=&quot;text/javascript&quot; src=&quot;'.$_storeBaseUrl.'/js/tiny_mce/tiny_mce.js&quot;&gt;&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
//&lt; ![CDATA[
Event.observe(window, &quot;load&quot;, function() {
tinyMCE.init({
mode : &quot;exact&quot;,
theme : &quot;'.$this-&gt;getTheme().'&quot;,
elements : &quot;' . $element . '&quot;,
theme_advanced_toolbar_location : &quot;top&quot;,
theme_advanced_toolbar_align : &quot;left&quot;,
theme_advanced_path_location : &quot;bottom&quot;,
extended_valid_elements : &quot;a[name|href|target|title|onclick],img[class|src|border=0|alt|title|hspace|vsp
theme_advanced_resizing : &quot;false&quot;,
apply_source_formatting : &quot;true&quot;,
convert_urls : &quot;false&quot;,
force_br_newlines : &quot;true&quot;,
doctype : \'&lt; !DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&quot;&gt;\'
});
});

//]]&gt;
&lt;/script&gt;';
</pre>
<p>As you might noticed, I used $_storeBaseUrl in this other chunk of code to get the valid path to my TinyMCE javascript file. If you are using store that does not have url rewrites this is something that needs to be done because your javascript file would not be found if you go trough link like “http://store.local/index.php/js/tiny_mce/tiny_mce.js”. Then you would get TinyMCE shown on CMS page but it would be disabled.</p>
<p>As you can see, there were only three minor changes needed (download, modify, modify) to get the TinyMCE editor working.</p>
<p>Hope this helps. Cheers.</p>
<p style="text-align: right;"><em>By </em><span>Branko Ajzele</span> <em>from <a rel="nofollow" href="http://inchoo.net/ecommerce/magento/how-to-make-tinymce-work-with-magento-cms-pages/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');" target="_blank">Inchoo.net</a></em></p>


<p>Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/07/how-to-add-dynamic-content-to-magento-static-blocks-and-pages/' rel='bookmark' title='Permanent Link: How to Add Dynamic Content to Magento Static Blocks and Pages?'>How to Add Dynamic Content to Magento Static Blocks and Pages?</a></li><li><a href='http://asia-connect.com.vn/2009/07/tips-for-creating-dynamic-category-landing-pages/' rel='bookmark' title='Permanent Link: Tips For Creating Dynamic Category Landing Pages'>Tips For Creating Dynamic Category Landing Pages</a></li><li><a href='http://asia-connect.com.vn/2009/09/how-to-fix-the-magento-out-of-stock-bug-version-1-1-x/' rel='bookmark' title='Permanent Link: How to fix the Magento Out of stock bug, version 1.1.x'>How to fix the Magento Out of stock bug, version 1.1.x</a></li></ol></p>]]></content:encoded>
			<wfw:commentRss>http://asia-connect.com.vn/2009/10/how-to-make-tinymce-work-with-magento-cms-pages/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to use WordPress home page in Magento home page (CMS page)</title>
		<link>http://asia-connect.com.vn/2009/10/how-to-use-wordpress-home-page-in-magento-home-page-cms-page/</link>
		<comments>http://asia-connect.com.vn/2009/10/how-to-use-wordpress-home-page-in-magento-home-page-cms-page/#comments</comments>
		<pubDate>Mon, 12 Oct 2009 02:07:35 +0000</pubDate>
		<dc:creator>lydh</dc:creator>
				<category><![CDATA[Magento Customization]]></category>
		<category><![CDATA[Magento Guide]]></category>
		<category><![CDATA[Magento Development]]></category>
		<category><![CDATA[Magento How To]]></category>
		<category><![CDATA[Magento Programming]]></category>
		<category><![CDATA[Magento Tips]]></category>

		<guid isPermaLink="false">http://asia-connect.com.vn/?p=949</guid>
		<description><![CDATA[
Simple : ) -Ok, lets get down to business. This one is really, really simple, but powerful. In all it greatness Magento lacks the good content management solution (CMS features). Lot of people are heading down the road of integrating the WordPress and Magento. Probably everyone in web development has heard about WordPress. Personaly I like them, from Joomla, Drupal, Wordpress… But there is that little something that makes WordPress far more loving in the eyes of the client. Not to start a flame here, lets get back to the ...


Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/09/connect2mage-wordpress-plugin-for-easy-magento-database-connection/' rel='bookmark' title='Permanent Link: connect2MAGE | WordPress plugin for easy Magento database connection'>connect2MAGE | WordPress plugin for easy Magento database connection</a></li><li><a href='http://asia-connect.com.vn/2009/10/add-adwords-tracking-code-to-order-confirmation-page-in-magento/' rel='bookmark' title='Permanent Link: Add Adwords tracking code to order confirmation page in Magento'>Add Adwords tracking code to order confirmation page in Magento</a></li><li><a href='http://asia-connect.com.vn/2009/10/magento-custom-emails/' rel='bookmark' title='Permanent Link: Magento custom emails'>Magento custom emails</a></li></ol>]]></description>
			<content:encoded><![CDATA[<p><img title="How to use WordPress home page in Magento home page (CMS page)" src="http://inchoo.net/wp-content/uploads/2009/07/wordpress-magento-home.jpg" alt="How to use WordPress home page in Magento home page (CMS page)" width="585" /></p>
<p>Simple : ) -Ok, lets get down to business. This one is really, really simple, but powerful. In all it greatness <a rel="nofollow" href="http://www.magentocommerce.com" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.magentocommerce.com');"  class="alinks_links" onclick="return alinks_click(this);" title="Magento eCommerce"  style="padding-right: 13px; background: url(http://asia-connect.com.vn/wp-content/plugins/alinks/images/external.png) center right no-repeat;" rel="external">Magento</a> lacks the good content management solution (CMS features). Lot of people are heading down the road of integrating the <a rel="nofollow" title="Magento Development" href="http://inchoo.net/services/magento-development/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');">WordPress and Magento</a>. Probably everyone in web development has heard about WordPress. Personaly I like them, from Joomla, Drupal, Wordpress… But there is that little something that makes WordPress far more loving in the eyes of the client. Not to start a flame here, lets get back to the topic. Due to the lack of the proper content management in Magento those who use WordPress can easily manage the (home page <em>in this case</em>) content trough WordPress and make it accessible in Magento CMS page (that you can set to home page in Magento).</p>
<p><strong>When would you like to do so?</strong></p>
<p>Imagine you have Magento installed in root of your site and WordPress under some folder like /articles. By default WordPress is accessed via http://mysite.domain/articles and Magento is accessed trough http://mysite.domain. Our goal is to have WordPress Page (that we will title “<strong>home</strong>“) to be accessible on http://mysite.domain.</p>
<p><strong>Here are the necessary steps involved:</strong></p>
<ul>
<li>Create a WordPress page named “home” (under url like <em>http://mysite.domain/articles/wp-content</em>)</li>
<li>Create a file named <strong>cmswp_home.phtml</strong> under app/design/frontend/default/yourtheme_or_default_theme/template/<strong>inchoo</strong>/ folder</li>
<li>Create a Magento CMS page (if it already does not exist) name it anyway you want and then add <strong>{{block type=”core/template” template=”inchoo/cmswp_home.phtml”}}<br />
</strong> to its content</li>
<li>Set the newly created Magento CMS page as home page for Magento under Magento Admin System &gt; Configuration &gt; Web &gt; Default Pages &gt; CMS Home Page</li>
</ul>
<p>Below is the code you need to copy paste into the <strong>cmswp_home.phtml</strong> file mentioned in above steps.</p>
<pre class="brush: php;">
&lt; ?php

/**
* Pulls the content of post named 'home' from WordPress 'wp_posts' table
* @author Branko Ajzele
* @license GPL
*/

//Fetch database connection
$_conn = Mage::getSingleton('core/resource')-&gt;getConnection('core_write');

//Set query that retrieves the home page content
//THIS GOES IF YOU HAVE WORDPRESS AND MAGENTO IN SAME DATABSE
$_findHomePage = &quot;SELECT post_content FROM wp_posts WHERE post_name = 'home' AND post_status = 'publish' AND post_type = 'page'&quot;;

//Set default value of home page to null, then do a safe check just to be more user friendly
$_homePageContent = null;

try {
/*
//IF YOU HAVE WORDPRESS AND MAGENTO INSTALLED EACH IN ITS OWN DATABASE; THEN USE
$conf = array(
'host' =&gt; 'localhost',
'username' =&gt; 'wordpress_db_username',
'password' =&gt; 'wordpress_db_password',
'dbname' =&gt; 'wordpress_db_name'
);

$_resource = Mage::getSingleton('core/resource');
//Create new connection to new server and new databse
$_conn = $_resource-&gt;createConnection('place_some_free_random_resource_name_here', 'pdo_mysql', $conf);
*/

$_homePageContent = $_conn-&gt;fetchOne($_findHomePage);
}

catch (Exception $ex) {

//SEND EXCEPTION INFO TO ADMIN?

/*
* USE $emailSmtpConf, $transport and $mail-&gt;send($transport); in case you need to specify SMTP manualy
$emailSmtpConf = array(
'auth' =&gt; 'login',
'ssl' =&gt; 'tls',
'username' =&gt; 'some_email@gmail.com',
'password' =&gt; 'some_pass_here'
);

$transport = new Zend_Mail_Transport_Smtp('smtp.gmail.com', $emailSmtpConf);
*/

$_sendTo_email = 'ajzele@somemail.com';
$_sendFrom_email = 'branko.ajzele@somemail.com';

//Notify each item author about purchase
$mail = new Zend_Mail();
$mail-&gt;addTo($_sendTo_email, 'Branko Ajzele');
$mail-&gt;setFrom($_sendFrom_email, 'Branko Ajzele');
$mail-&gt;setSubject('Invalid HOME PAGE on site detected');
$mail-&gt;setBodyHtml('
&lt;h1&gt;Invalid HOME PAGE on site detected&lt;/h1&gt;
&lt;p&gt;There seem to be some issues with home page on your site. Please take a look at it.&lt;/p&gt;
&lt;p&gt;Could be that WordPress page has been disabled and this made the query for page return null.&lt;/p&gt;
');
try {
//Try to send email
//$mail-&gt;send($transport);
$mail-&gt;send();
}
catch (Exception $ex) {
//echo $ex-&gt;getMessage();
}

}

?&gt;

&lt; ?php if($_homePageContent): ?&gt;
&lt; ?php echo $_homePageContent ?&gt;
&lt; ?php else: ?&gt;
&lt;h1&gt;Home page unavailable&lt;/h1&gt;
&lt;p&gt;Seems like home page is unavailable at the moment. We apologize for the inconvenience.&lt;/p&gt;
&lt; ?php endif; ?&gt;
</pre>
<p>That’s it.</p>
<p>If you wish to have more control over what is outputted take a look $_findHomePage variable and the query behind it.</p>
<p>Hope you find this useful.</p>
<p>Cheers.</p>
<p style="text-align: right;"><em>By</em> <span>Branko Ajzele</span> <em>from <a rel="nofollow" href="http://inchoo.net/wordpress/how-to-use-wordpress-home-page-in-magento-home-page-cms-page/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');" target="_blank">Inchoo.net</a></em></p>


<p>Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/09/connect2mage-wordpress-plugin-for-easy-magento-database-connection/' rel='bookmark' title='Permanent Link: connect2MAGE | WordPress plugin for easy Magento database connection'>connect2MAGE | WordPress plugin for easy Magento database connection</a></li><li><a href='http://asia-connect.com.vn/2009/10/add-adwords-tracking-code-to-order-confirmation-page-in-magento/' rel='bookmark' title='Permanent Link: Add Adwords tracking code to order confirmation page in Magento'>Add Adwords tracking code to order confirmation page in Magento</a></li><li><a href='http://asia-connect.com.vn/2009/10/magento-custom-emails/' rel='bookmark' title='Permanent Link: Magento custom emails'>Magento custom emails</a></li></ol></p>]]></content:encoded>
			<wfw:commentRss>http://asia-connect.com.vn/2009/10/how-to-use-wordpress-home-page-in-magento-home-page-cms-page/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Remove SID query from Magento URLs</title>
		<link>http://asia-connect.com.vn/2009/10/remove-sid-query-from-magento-urls/</link>
		<comments>http://asia-connect.com.vn/2009/10/remove-sid-query-from-magento-urls/#comments</comments>
		<pubDate>Sat, 10 Oct 2009 02:27:40 +0000</pubDate>
		<dc:creator>lydh</dc:creator>
				<category><![CDATA[Magento Customization]]></category>
		<category><![CDATA[Magento Guide]]></category>
		<category><![CDATA[Magento How To]]></category>
		<category><![CDATA[Magento Programming]]></category>

		<guid isPermaLink="false">http://asia-connect.com.vn/?p=928</guid>
		<description><![CDATA[
Many people wonder why sometimes the SID part appears in their Magento URLs. This is when your URL has additional SID query usually at the end. Take a look at the image. The curiosity is that it does not appear always. What is the most common scenario it happens? You didn’t access the site with the same domain variant you entered as your “Base URL” in your System&#62; Configuration&#62; Web interface.
When you decide to launch the site, you have to decide whether you will market http://www.domain.com/ URL or http://domain.com/. This ...


Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/10/magento-duplicated-content-issues/' rel='bookmark' title='Permanent Link: Magento duplicated content issues'>Magento duplicated content issues</a></li><li><a href='http://asia-connect.com.vn/2009/10/internal-server-error-500-in-magento/' rel='bookmark' title='Permanent Link: Internal Server Error 500 in Magento'>Internal Server Error 500 in Magento</a></li><li><a href='http://asia-connect.com.vn/2009/10/manual-creation-of-google-sitemap-in-magento/' rel='bookmark' title='Permanent Link: Manual creation of Google Sitemap in Magento'>Manual creation of Google Sitemap in Magento</a></li></ol>]]></description>
			<content:encoded><![CDATA[<p><img title="Remove SID query from Magento URLs" src="http://inchoo.net/wp-content/uploads/2009/07/remove_sid.png" alt="Remove SID query from Magento URLs" width="585" /></p>
<p>Many people wonder why sometimes the SID part appears in their <a rel="nofollow" href="http://www.magentocommerce.com" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.magentocommerce.com');"  class="alinks_links" onclick="return alinks_click(this);" title="Magento eCommerce"  style="padding-right: 13px; background: url(http://asia-connect.com.vn/wp-content/plugins/alinks/images/external.png) center right no-repeat;" rel="external">Magento</a> URLs. This is when your URL has additional SID query usually at the end. Take a look at the image. The curiosity is that it does not appear always. What is the most common scenario it happens? You didn’t access the site with the same domain variant you entered as your “Base URL” in your System&gt; Configuration&gt; Web interface.</p>
<p>When you decide to launch the site, you have to decide whether you will market http://www.domain.com/ URL or http://domain.com/. This is an important decision and you shouldn’t change your mind quite often. Search engines usually treat those two URLs as a different sites and therefore the Page Rank potential can be split between those two URLs. So, think about whether you will use <strong>www</strong> or not and stick by this decision.</p>
<p>Once you decided, go to your System&gt; Configuration&gt; Web interface and enter the desired form to “Base URL” field. When you access the site you will notice that there are no “SID”s when the URL matches the value from “Base URL” field and they appear when it does not.</p>
<p>Now, we want the ability that the site redirects to proper URL once accessed. Someone can place a wrong link to some forum or blog. We don’t want those links to lead to improper URL and we don’t want SIDs to appear to those visitors. Most important: <strong>We don’t want that search engines index the URLs with SIDs</strong>.</p>
<p>The solution is simple. Go to your .htaccess fine and find the line that says</p>
<pre class="brush: html;">
RewriteEngine on
</pre>
<p>If you want to have www part:</p>
<pre class="brush: html;">
RewriteEngine on
RewriteCond %{HTTP_HOST} !^www\.yourdomain\.com$ [NC]
RewriteRule ^(.*)$ http://www.yourdomain.com/$1 [R=301,L]
</pre>
<p>If you don’t want to have www part:</p>
<pre class="brush: html;">
RewriteEngine on
RewriteCond %{HTTP_HOST} !^yourdomain\.com$ [NC]
RewriteRule ^(.*)$ http://yourdomain.com/$1 [R=301,L]
</pre>
<p>Btw. This is applicable and good to be set to every site, not just Magento ones. <img src="http://inchoo.net/wp-includes/images/smilies/icon_smile.gif" alt=":)" /></p>
<p style="text-align: right;"><em>By </em><span>Tomislav Bilic</span><em> from <a rel="nofollow" href="http://inchoo.net/tools/remove-sid-from-magento-urls/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');" target="_blank">Inchoo.net</a></em></p>


<p>Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/10/magento-duplicated-content-issues/' rel='bookmark' title='Permanent Link: Magento duplicated content issues'>Magento duplicated content issues</a></li><li><a href='http://asia-connect.com.vn/2009/10/internal-server-error-500-in-magento/' rel='bookmark' title='Permanent Link: Internal Server Error 500 in Magento'>Internal Server Error 500 in Magento</a></li><li><a href='http://asia-connect.com.vn/2009/10/manual-creation-of-google-sitemap-in-magento/' rel='bookmark' title='Permanent Link: Manual creation of Google Sitemap in Magento'>Manual creation of Google Sitemap in Magento</a></li></ol></p>]]></content:encoded>
			<wfw:commentRss>http://asia-connect.com.vn/2009/10/remove-sid-query-from-magento-urls/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Magento CMS syntax – part1</title>
		<link>http://asia-connect.com.vn/2009/10/magento-cms-syntax-%e2%80%93-part1/</link>
		<comments>http://asia-connect.com.vn/2009/10/magento-cms-syntax-%e2%80%93-part1/#comments</comments>
		<pubDate>Fri, 09 Oct 2009 01:56:59 +0000</pubDate>
		<dc:creator>lydh</dc:creator>
				<category><![CDATA[Magento Customization]]></category>
		<category><![CDATA[Magento Guide]]></category>
		<category><![CDATA[Magento Development]]></category>
		<category><![CDATA[Magento Programming]]></category>

		<guid isPermaLink="false">http://asia-connect.com.vn/?p=918</guid>
		<description><![CDATA[
Every Magento user noticed that there is special {{magentocode}} syntax available in cms pages and blocks. We traced a bit to find out which params are available and what exactly they do.
 
As strange as this may sound, processor class that gets called is Mage_Core_Model_Email_Template_Filter located at app/code/core/Mage/Core/Model/Email/Template/Filter.php .
There are also some interesting directives in superclass Varien_Filter_Template, but if i’m not mistaken, none of them can be used.
There are six replacement codes  that can be used and each triggers its equivalent Directive function:
skinDirective
mediaDirective
htmlescapeDirective
storeDirective
blockDirective
layoutDirective
I’ll start with easier and most commonly used ...


Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/07/some-custom-blocks-to-help-you-show-products/' rel='bookmark' title='Permanent Link: Some custom Blocks to help you show products'>Some custom Blocks to help you show products</a></li><li><a href='http://asia-connect.com.vn/2009/09/run-magento-code-outside-of-magento/' rel='bookmark' title='Permanent Link: Run Magento Code Outside of Magento'>Run Magento Code Outside of Magento</a></li><li><a href='http://asia-connect.com.vn/2009/10/how-to-make-tinymce-work-with-magento-cms-pages/' rel='bookmark' title='Permanent Link: How to make TinyMCE work with Magento CMS pages'>How to make TinyMCE work with Magento CMS pages</a></li></ol>]]></description>
			<content:encoded><![CDATA[<p><img title="Magento CMS syntax – part1" src="http://inchoo.net/wp-content/uploads/2009/06/magento-cms-syntax-1.jpg" alt="Magento CMS syntax – part1" width="585" /></p>
<p>Every <a rel="nofollow" href="http://www.magentocommerce.com" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.magentocommerce.com');"  class="alinks_links" onclick="return alinks_click(this);" title="Magento eCommerce"  style="padding-right: 13px; background: url(http://asia-connect.com.vn/wp-content/plugins/alinks/images/external.png) center right no-repeat;" rel="external">Magento</a> user noticed that there is special {{magentocode}} syntax available in cms pages and blocks. We traced a bit to find out which params are available and what exactly they do.</p>
<p><span id="more-2505"> </span></p>
<p>As strange as this may sound, processor class that gets called is Mage_Core_Model_Email_Template_Filter located at app/code/core/Mage/Core/Model/Email/Template/Filter.php .</p>
<p>There are also some interesting directives in superclass Varien_Filter_Template, but if i’m not mistaken, none of them can be used.</p>
<p>There are six replacement codes  that can be used and each triggers its equivalent Directive function:</p>
<p>skinDirective<br />
mediaDirective<br />
htmlescapeDirective<br />
storeDirective<br />
blockDirective<br />
layoutDirective</p>
<p>I’ll start with easier and most commonly used and continue with advanced ones in part two of this article.</p>
<p><strong>1. skinDirective</strong></p>
<p>Description: Used to retrieve path of skin folder and its files, theme fallback respected<br />
Example: {{skin url=’images/image.jpg’ _theme=’blank’}}<br />
Synonym: Mage::getDesign()-&gt;getSkinUrl($params['url'], $params)<br />
Params:<br />
url = empty or relative file path<br />
_theme = alternative theme, fallbacks if file not exist<br />
_package = alternative package<br />
_area = alternative area(frontend,adminhtml)<br />
_type, _default etc. = nothing useful, somebody please correct me if i’m wrong <img src="http://inchoo.net/wp-includes/images/smilies/icon_smile.gif" alt=":)" /></p>
<p><strong>2. mediaDirective</strong></p>
<p>Description: Used to retrieve path of root/media folder and its files<br />
Example: {{media url=’image.jpg’}}<br />
Synonym: Mage::getBaseUrl(’media’) . $params['url']<br />
Params:<br />
url = empty or relative file path</p>
<p><strong>3. htmlescapeDirective</strong></p>
<p>Description: Used to escape special html chars<br />
Example: {{htmlescape var=’&lt;a href=”www.<a rel="nofollow" href="http://inchoo.net/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');"  class="alinks_links" onclick="return alinks_click(this);" title="inchoo.net"  style="padding-right: 13px; background: url(http://asia-connect.com.vn/wp-content/plugins/alinks/images/external.png) center right no-repeat;" rel="external">inchoo.net</a>”&gt;inchoo&lt;/a&gt;&lt;b&gt;inchoo&lt;/b&gt;&lt;i&gt;inchoo&lt;/i&gt;’ allowed_tags=’b&#8217;}}<br />
Synonym: Mage::helper(’core’)-&gt;htmlEscape($params['var'], $params['allowed_tags'])<br />
Params:<br />
var = string to escape<br />
allowed_tags = comma-separated list of allowed tags</p>
<p><strong>4. storeDirective</strong></p>
<p>Description: Used to build magento routes and custom urls<br />
Example: {{store url=’customer/account’ _query_a=’8′}}<br />
Synonym: Mage::getUrl($params['url'], $params);<br />
Params:<br />
url = magento routers url<br />
direct_url = normal url, appended to baseurl<br />
_query_PARAMNAME = adds query param, for example _query_a=’8′ adds a=8 to url<br />
_fragment = adds fragment, for example #comments<br />
_escape = escapes “,’,&lt;,&gt;<br />
custom = if using magento route url param, every custom param added will be appended like /a/8/b/10</p>
<p>I probably missed something in this last one, but it’s very late and i’m tired of poking through Magento <img src="http://inchoo.net/wp-includes/images/smilies/icon_wink.gif" alt=";)" /></p>
<p>To be continued ..</p>
<p style="text-align: right;"><em>By</em> <span>Ivan Weiler</span> <em> from <a rel="nofollow" href="http://inchoo.net/ecommerce/magento/magento-cms-syntax-part1/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');" target="_blank">Inchoo.net</a></em></p>


<p>Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/07/some-custom-blocks-to-help-you-show-products/' rel='bookmark' title='Permanent Link: Some custom Blocks to help you show products'>Some custom Blocks to help you show products</a></li><li><a href='http://asia-connect.com.vn/2009/09/run-magento-code-outside-of-magento/' rel='bookmark' title='Permanent Link: Run Magento Code Outside of Magento'>Run Magento Code Outside of Magento</a></li><li><a href='http://asia-connect.com.vn/2009/10/how-to-make-tinymce-work-with-magento-cms-pages/' rel='bookmark' title='Permanent Link: How to make TinyMCE work with Magento CMS pages'>How to make TinyMCE work with Magento CMS pages</a></li></ol></p>]]></content:encoded>
			<wfw:commentRss>http://asia-connect.com.vn/2009/10/magento-cms-syntax-%e2%80%93-part1/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Magento FLIR</title>
		<link>http://asia-connect.com.vn/2009/10/magento-flir/</link>
		<comments>http://asia-connect.com.vn/2009/10/magento-flir/#comments</comments>
		<pubDate>Thu, 08 Oct 2009 04:13:38 +0000</pubDate>
		<dc:creator>lydh</dc:creator>
				<category><![CDATA[Magento Customization]]></category>
		<category><![CDATA[Magento Guide]]></category>
		<category><![CDATA[Magento Development]]></category>
		<category><![CDATA[Magento Programming]]></category>

		<guid isPermaLink="false">http://asia-connect.com.vn/?p=914</guid>
		<description><![CDATA[
Facelift Image Replacement (or FLIR, pronounced fleer) is an image replacement script that dynamically generates image representations of text on your web page in fonts that otherwise might not be visible to your visitors. Let’s see how it behaves in Magento.
 
1. Download FLIR from FLIR homepage. I was using latest 1.2 stable for this article because of simplicity, but if you try you’ll find out that 2.0 beta also works great but requires little more configuration.
2. Unpack FLIR content (cache,fonts,etc.) inside skin/frontend/default/default/facelift
I think it makes perfect sense to put ...


Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/04/using-jquery-in-magento/' rel='bookmark' title='Permanent Link: Using jQuery in Magento'>Using jQuery in Magento</a></li><li><a href='http://asia-connect.com.vn/2009/09/adding-and-removing-javascript-css-when-and-where-you-need-it/' rel='bookmark' title='Permanent Link: Adding and removing javascript / css when and where you need it'>Adding and removing javascript / css when and where you need it</a></li><li><a href='http://asia-connect.com.vn/2009/07/custom-category-images-listing-block-tutorial/' rel='bookmark' title='Permanent Link: Custom Category Images Listing Block Tutorial'>Custom Category Images Listing Block Tutorial</a></li></ol>]]></description>
			<content:encoded><![CDATA[<p><img title="Magento FLIR" src="http://inchoo.net/wp-content/uploads/2009/06/magento-flir.jpg" alt="Magento FLIR" width="585" /></p>
<p>Facelift Image Replacement (or FLIR, pronounced fleer) is an image replacement script that dynamically generates image representations of text on your web page in fonts that otherwise might not be visible to your visitors. Let’s see how it behaves in <a rel="nofollow" href="http://www.magentocommerce.com" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.magentocommerce.com');"  class="alinks_links" onclick="return alinks_click(this);" title="Magento eCommerce"  style="padding-right: 13px; background: url(http://asia-connect.com.vn/wp-content/plugins/alinks/images/external.png) center right no-repeat;" rel="external">Magento</a>.</p>
<p><span id="more-2481"> </span></p>
<p>1. Download FLIR from <a rel="nofollow" href="http://facelift.mawhorter.net/" onclick="javascript:pageTracker._trackPageview('/outbound/article/facelift.mawhorter.net');" target="_blank">FLIR homepage</a>. I was using latest 1.2 stable for this article because of simplicity, but if you try you’ll find out that 2.0 beta also works great but requires little more configuration.</p>
<p>2. Unpack FLIR content (cache,fonts,etc.) inside skin/frontend/default/default/facelift<br />
I think it makes perfect sense to put it into skin folder.</p>
<p>3. Open app/design/frontend/yourpackage/yourtheme/template/page/html/head.phtml and append</p>
<p>&lt;script language=”javascript” src=”&lt;?php echo $this-&gt;getSkinUrl(’facelift/flir.js’) ?&gt;”&gt;&lt;/script&gt;</p>
<p>&lt;script type=”text/javascript”&gt;<br />
document.observe(”dom:loaded”, function() {<br />
FLIR.init({ path: ‘&lt;?php echo $this-&gt;getSkinUrl(’facelift/’) ?&gt;’ }, new FLIRStyle({ mode: ‘wrap’ }) );<br />
FLIR.auto();<br />
});<br />
&lt;/script&gt;</p>
<p>If your php error reporting isn’t disabled add error_reporting(0); somewhere on top of config-flir.php. This is main config file from which you can define options and custom fonts, so examine it.</p>
<p>Refresh your Magento store and you <a rel="nofollow" href="http://inchoo.net/wp-content/uploads/2009/06/magento-flir-screenshot.jpg" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');" target="_blank">should see the result</a>.</p>
<p>flir.js can also be alternatively included from layout files inside head block<br />
&lt;reference name=”head”&gt;<br />
&lt;action method=”addItem”&gt;&lt;type&gt;skin_js&lt;/type&gt;&lt;name&gt;facelift/flir.js&lt;/name&gt;&lt;/action&gt;<br />
&lt;/reference&gt;</p>
<p>There is nice <a rel="nofollow" href="http://facelift.mawhorter.net/quick-start/" onclick="javascript:pageTracker._trackPageview('/outbound/article/facelift.mawhorter.net');" target="_blank">Quick Start Guide</a> and <a rel="nofollow" href="http://docs.facelift.mawhorter.net/" onclick="javascript:pageTracker._trackPageview('/outbound/article/docs.facelift.mawhorter.net');" target="_blank">Documentation</a> available from <a rel="nofollow" href="http://facelift.mawhorter.net/" onclick="javascript:pageTracker._trackPageview('/outbound/article/facelift.mawhorter.net');" target="_blank">FLIR homepage</a>, so i won’t go in details on some advanced FLIR settings, but here are few examples:</p>
<p>//pass selectors as comma separated list<br />
FLIR.auto(’h5,h4′);<br />
//pass an array of selectors<br />
FLIR.auto( [ 'h4', 'h5' ] );<br />
//replace manually with custom options<br />
FLIR.replace( ‘div.box h4′ , new FLIRStyle({ mode: ‘wrap’ , css: {’font-family’:&#8217;arial’} }) );<br />
//prototype way<br />
$$(’div.box h4′).each( function(el) { FLIR.replace(el);  } );</p>
<p>Cya.</p>
<p style="text-align: right;"><em>By </em><span>Ivan Weiler</span><em> from <a rel="nofollow" href="http://inchoo.net/ecommerce/magento/magento-flir/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');" target="_blank">Inchoo.net</a></em></p>


<p>Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/04/using-jquery-in-magento/' rel='bookmark' title='Permanent Link: Using jQuery in Magento'>Using jQuery in Magento</a></li><li><a href='http://asia-connect.com.vn/2009/09/adding-and-removing-javascript-css-when-and-where-you-need-it/' rel='bookmark' title='Permanent Link: Adding and removing javascript / css when and where you need it'>Adding and removing javascript / css when and where you need it</a></li><li><a href='http://asia-connect.com.vn/2009/07/custom-category-images-listing-block-tutorial/' rel='bookmark' title='Permanent Link: Custom Category Images Listing Block Tutorial'>Custom Category Images Listing Block Tutorial</a></li></ol></p>]]></content:encoded>
			<wfw:commentRss>http://asia-connect.com.vn/2009/10/magento-flir/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Programatically create Magento blocks and inject them into layout</title>
		<link>http://asia-connect.com.vn/2009/10/programatically-create-magento-blocks-and-inject-them-into-layout/</link>
		<comments>http://asia-connect.com.vn/2009/10/programatically-create-magento-blocks-and-inject-them-into-layout/#comments</comments>
		<pubDate>Thu, 08 Oct 2009 04:04:36 +0000</pubDate>
		<dc:creator>lydh</dc:creator>
				<category><![CDATA[Magento Customization]]></category>
		<category><![CDATA[Magento Guide]]></category>
		<category><![CDATA[Magento Development]]></category>
		<category><![CDATA[Magento Programming]]></category>

		<guid isPermaLink="false">http://asia-connect.com.vn/?p=911</guid>
		<description><![CDATA[
Imagine a scenario where you wish to simply create a view file like custom-note.phtml and show this view file on some new url inside the Magento store. One way to do this is to create a CMS page and call that block from within CMS page. But what if you wish to create and append this block to other areas of Magento layout that are inaccessible from CMS page interface form admin? What if I want to add new div element under the breadcrumbs and append new block under it?
magento ...


Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/07/how-to-add-dynamic-content-to-magento-static-blocks-and-pages/' rel='bookmark' title='Permanent Link: How to Add Dynamic Content to Magento Static Blocks and Pages?'>How to Add Dynamic Content to Magento Static Blocks and Pages?</a></li><li><a href='http://asia-connect.com.vn/2009/07/some-custom-blocks-to-help-you-show-products/' rel='bookmark' title='Permanent Link: Some custom Blocks to help you show products'>Some custom Blocks to help you show products</a></li><li><a href='http://asia-connect.com.vn/2009/09/create-a-new-magento-theme/' rel='bookmark' title='Permanent Link: Create a new Magento theme'>Create a new Magento theme</a></li></ol>]]></description>
			<content:encoded><![CDATA[<p><img title="Programatically create Magento blocks and inject them into layout" src="http://inchoo.net/wp-content/uploads/2009/06/blocks.jpg" alt="Programatically create Magento blocks and inject them into layout" width="585" /></p>
<p>Imagine a scenario where you wish to simply create a view file like custom-note.phtml and show this view file on some new url inside the <a rel="nofollow" href="http://www.magentocommerce.com" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.magentocommerce.com');"  class="alinks_links" onclick="return alinks_click(this);" title="Magento eCommerce"  style="padding-right: 13px; background: url(http://asia-connect.com.vn/wp-content/plugins/alinks/images/external.png) center right no-repeat;" rel="external">Magento</a> store. One way to do this is to create a CMS page and call that block from within CMS page. But what if you wish to create and append this block to other areas of Magento layout that are inaccessible from CMS page interface form admin? What if I want to add new div element under the breadcrumbs and append new block under it?</p>
<p>magento philosophy is to create block class under the /Block folder of your module, to create xml layout file under the theme /layouts folder (or to modify existing layout file) and so on. Anyway you turn it around you either need to have Block file or add/modify at least the entry to the layout files.</p>
<p>All this is OK if you are working on your own store so you have full control over the code. However, what if you are developing a module that will be used on different Magento stores. My prime concern when building a module is to keep the number of necessary module files to a minimum.</p>
<p>In code below, you will see how easy it is to call your Core/Template block to show on any area of Magento layout.</p>
<p>Extracted from app/code/local/ActiveCodeline/CustomOutputs/controllers/IndexController.php file.</p>
<pre class="brush: php;">
public function indexAction()
{
//Get current layout state
$this-&gt;loadLayout();

$block = $this-&gt;getLayout()-&gt;createBlock(
'Mage_Core_Block_Template',
'my_block_name_here',
array('template' =&gt; 'activecodeline/developer.phtml')
);

$this-&gt;getLayout()-&gt;getBlock('content')-&gt;append($block);

//Release layout stream... lol... sounds fancy
$this-&gt;renderLayout();
}
</pre>
<p>Most IMPORTANT thing to keep in mind here is the “error handling”. If you assign a “invalid” block to -&gt;append(), you will not (most likely) see an error but “nothing happend” situation.</p>
<p>Anyhow… hope the attached module (extension) will save you some headaches. I know it took me few hours of tracing and testing to get the grip of it.</p>
<p>Download <a rel="nofollow" href="http://inchoo.net/wp-content/uploads/2009/06/ActiveCodeline_CustomOutputs.zip" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');">ActiveCodeline_CustomOutputs</a> extension.</p>
<p>Cheers.</p>
<p style="text-align: right;"><em>By</em><span>Branko Ajzele</span> <em>from <a rel="nofollow" href="http://inchoo.net/ecommerce/magento/programatically-create-magento-blocks-and-inject-them-into-layout/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');" target="_blank">Inchoo.net</a></em></p>


<p>Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/07/how-to-add-dynamic-content-to-magento-static-blocks-and-pages/' rel='bookmark' title='Permanent Link: How to Add Dynamic Content to Magento Static Blocks and Pages?'>How to Add Dynamic Content to Magento Static Blocks and Pages?</a></li><li><a href='http://asia-connect.com.vn/2009/07/some-custom-blocks-to-help-you-show-products/' rel='bookmark' title='Permanent Link: Some custom Blocks to help you show products'>Some custom Blocks to help you show products</a></li><li><a href='http://asia-connect.com.vn/2009/09/create-a-new-magento-theme/' rel='bookmark' title='Permanent Link: Create a new Magento theme'>Create a new Magento theme</a></li></ol></p>]]></content:encoded>
			<wfw:commentRss>http://asia-connect.com.vn/2009/10/programatically-create-magento-blocks-and-inject-them-into-layout/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Magento custom emails</title>
		<link>http://asia-connect.com.vn/2009/10/magento-custom-emails/</link>
		<comments>http://asia-connect.com.vn/2009/10/magento-custom-emails/#comments</comments>
		<pubDate>Wed, 07 Oct 2009 02:42:25 +0000</pubDate>
		<dc:creator>lydh</dc:creator>
				<category><![CDATA[Magento Customization]]></category>
		<category><![CDATA[Magento Guide]]></category>
		<category><![CDATA[Magento How To]]></category>
		<category><![CDATA[Magento Programming]]></category>
		<category><![CDATA[Magento Tips]]></category>
		<category><![CDATA[Magento Tutorials]]></category>

		<guid isPermaLink="false">http://asia-connect.com.vn/?p=901</guid>
		<description><![CDATA[
Ever wanted to “just send the email” using the built in email features in Magento? Ever hit the wall trying to do something with Magento? OK, I know the answer to the other one, just had to ask  . Anyhow, sending the emails with Magento turned out to be a process of “just” a few hours of tracing Magento code.
I cant wait for smart comments like, “few hours, huh its so easy…”. Yea, thats the beauty of Magento… few hours of bashing your head against the wall while you ...


Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/10/custom-transactional-emails/' rel='bookmark' title='Permanent Link: Custom Transactional Emails'>Custom Transactional Emails</a></li><li><a href='http://asia-connect.com.vn/2009/09/custom-checkout-cart-%e2%80%93-how-to-send-email-after-successful-checkout/' rel='bookmark' title='Permanent Link: Custom checkout cart – How to send email after successful checkout'>Custom checkout cart – How to send email after successful checkout</a></li><li><a href='http://asia-connect.com.vn/2009/10/how-to-use-wordpress-home-page-in-magento-home-page-cms-page/' rel='bookmark' title='Permanent Link: How to use WordPress home page in Magento home page (CMS page)'>How to use WordPress home page in Magento home page (CMS page)</a></li></ol>]]></description>
			<content:encoded><![CDATA[<p><img title="Magento custom emails" src="http://inchoo.net/wp-content/uploads/2009/06/magento_custom_email.jpg" alt="Magento custom emails" width="585" /></p>
<p>Ever wanted to “just send the email” using the built in email features in <a rel="nofollow" href="http://www.magentocommerce.com" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.magentocommerce.com');"  class="alinks_links" onclick="return alinks_click(this);" title="Magento eCommerce"  style="padding-right: 13px; background: url(http://asia-connect.com.vn/wp-content/plugins/alinks/images/external.png) center right no-repeat;" rel="external">Magento</a>? Ever hit the wall trying to do something with Magento? OK, I know the answer to the other one, just had to ask <img src="http://inchoo.net/wp-includes/images/smilies/icon_smile.gif" alt=":)" /> . Anyhow, sending the emails with Magento turned out to be a process of “just” a few hours of tracing Magento code.</p>
<p>I cant wait for smart comments like, “few hours, huh its so easy…”. Yea, thats the beauty of Magento… few hours of bashing your head against the wall while you are sipping the 4th cup of coffee until the solution hits you. Interesting do, just when you get the hang of it, Magento gets you this “have you tried this” attitude <img src="http://inchoo.net/wp-includes/images/smilies/icon_smile.gif" alt=":)" /> .</p>
<p>What am I talking about? Scenario: I want to create email template named activecodeline_custom_email1.html, I want to pass few variables to it during runtime, I want to send emails programmaticaly. I dont want to create 56 lines of xml file just to call one template.</p>
<p>Here is how.</p>
<pre class="brush: html;">

...
/*
* Loads the html file named 'custom_email_template1.html' from
* app/locale/en_US/template/email/activecodeline_custom_email1.html
*/
$emailTemplate  = Mage::getModel('core/email_template')
-&gt;loadDefault('custom_email_template1');

//Create an array of variables to assign to template
$emailTemplateVariables = array();
$emailTemplateVariables['myvar1'] = 'Branko';
$emailTemplateVariables['myvar2'] = 'Ajzele';
$emailTemplateVariables['myvar3'] = 'ActiveCodeline';

/**
* The best part &lt;img src=&quot;http://<a rel="nofollow" href="http://inchoo.net/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');"  class="alinks_links" onclick="return alinks_click(this);" title="inchoo.net"  style="padding-right: 13px; background: url(http://asia-connect.com.vn/wp-content/plugins/alinks/images/external.png) center right no-repeat;" rel="external">inchoo.net</a>/wp-includes/images/smilies/icon_smile.gif&quot; alt=&quot;:)&quot;&gt;
* Opens the activecodeline_custom_email1.html, throws in the variable array
* and returns the 'parsed' content that you can use as body of email
*/
$processedTemplate = $emailTemplate-&gt;getProcessedTemplate($emailTemplateVariables);

/*
* Or you can send the email directly,
* note getProcessedTemplate is called inside send()
*/
$emailTemplate-&gt;send('john@someemail.com','John Doe', $emailTemplateVariables);
...
</pre>
<p>And here we go again, nothing without xml files <img src="http://inchoo.net/wp-includes/images/smilies/icon_smile.gif" alt=":)" /> -In order for above piece of code to work, you need to add an entry to your config.xml file like shown below.</p>
<pre class="brush: html;">
...
&lt;global&gt;
&lt;template&gt;
&lt;email&gt;
&lt;custom_email_template1 module=&quot;SampleModule1&quot;&gt;
&lt;label&gt;ActiveCodeline custom email module&lt;/label&gt;
&lt;file&gt;activecodeline_custom_email1.html&lt;/file&gt;
&lt;type&gt;html&lt;/type&gt;
&lt;/custom_email_template1&gt;
&lt;/email&gt;
&lt;/template&gt;
&lt;/global&gt;
...
</pre>
<p>And lets not forget the email template itself, app/locale/en_US/template/email/activecodeline_custom_email1.html.</p>
<pre class="brush: html;">
&lt;!--@subject ActiveCodeline custom email module @--&gt;

&lt;div&gt;
&lt;h1&gt;ActiveCodeline custom email example by Branko Ajzele&lt;/h1&gt;
&lt;p&gt;Hi there {{var myvar1}} {{var myvar2}} from {{var myvar3}}. This is just some example template to test custom email module.&lt;/p&gt;
&lt;/div&gt;
</pre>
<p>Hope this was helpful. Cheers.</p>
<p style="text-align: right;"><em>By</em> <span>Branko Ajzele</span> <em>from <a rel="nofollow" href="http://inchoo.net/ecommerce/magento/magento-custom-emails/" onclick="javascript:pageTracker._trackPageview('/outbound/article/inchoo.net');" target="_blank">Inchoo.net</a><br />
</em></p>


<p>Related posts:<ol><li><a href='http://asia-connect.com.vn/2009/10/custom-transactional-emails/' rel='bookmark' title='Permanent Link: Custom Transactional Emails'>Custom Transactional Emails</a></li><li><a href='http://asia-connect.com.vn/2009/09/custom-checkout-cart-%e2%80%93-how-to-send-email-after-successful-checkout/' rel='bookmark' title='Permanent Link: Custom checkout cart – How to send email after successful checkout'>Custom checkout cart – How to send email after successful checkout</a></li><li><a href='http://asia-connect.com.vn/2009/10/how-to-use-wordpress-home-page-in-magento-home-page-cms-page/' rel='bookmark' title='Permanent Link: How to use WordPress home page in Magento home page (CMS page)'>How to use WordPress home page in Magento home page (CMS page)</a></li></ol></p>]]></content:encoded>
			<wfw:commentRss>http://asia-connect.com.vn/2009/10/magento-custom-emails/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
