<?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>Solution Log &#124; Antonio David - NVNCBL &#187; Resources</title>
	<atom:link href="http://www.nvncbl.com/categories/resources/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.nvncbl.com</link>
	<description>A place to log my programming solutions for future reference</description>
	<lastBuildDate>Mon, 17 May 2010 21:39:17 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Magento &#8211; Add Custom Category Attributes</title>
		<link>http://www.nvncbl.com/2010/03/magento-add-custom-category-attributes/</link>
		<comments>http://www.nvncbl.com/2010/03/magento-add-custom-category-attributes/#comments</comments>
		<pubDate>Sun, 28 Mar 2010 02:54:58 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[Resources]]></category>
		<category><![CDATA[attribute]]></category>
		<category><![CDATA[category]]></category>
		<category><![CDATA[custom]]></category>
		<category><![CDATA[magento]]></category>
		<category><![CDATA[phpMyAdmin]]></category>

		<guid isPermaLink="false">http://www.nvncbl.com/?p=527</guid>
		<description><![CDATA[A client wanted to add a description to each of his product categories, such that the first built-in description would be above the product listing, and the second description would be below the product listing.  Rather than have them create static blocks for every category, it was obvious that I&#8217;d have to create a new [...]]]></description>
			<content:encoded><![CDATA[<p>A client wanted to add a description to each of his product categories, such that the first built-in description would be above the product listing, and the second description would be below the product listing.  Rather than have them create static blocks for every category, it was obvious that I&#8217;d have to create a new category attribute.</p>
<p>Fortunately, I stumbled upon one possible solution.  The method doesn&#8217;t involve creating a full-blown module, rather, just a few database modifications using phpMyAdmin.</p>
<p>Summarized, the process comes down to:</p>
<ol>
<li>Create a new row in the eav_attribute table, one that mimics a category&#8217;s meta-description attribute with everything being the same except for a unique identifier and a label.</li>
<li>Create a new row in the eav_entity_attribute table, to provide a sort order for your newly created attribute, following in the format footsteps of the existing rows.</li>
</ol>
<p>For the fully detailed procedure, see <a class="external" title="Create Custom Category Attributes with phpMyAdmin" href="http://www.knowmagento.com/2009/06/19/custom-category-attributes-with-phpmyadmin/">Create Custom Category Attributes with phpMyAdmin</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.nvncbl.com/2010/03/magento-add-custom-category-attributes/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Refresh Magento Cache Programmatically</title>
		<link>http://www.nvncbl.com/2010/03/refresh-magento-cache-programmatically/</link>
		<comments>http://www.nvncbl.com/2010/03/refresh-magento-cache-programmatically/#comments</comments>
		<pubDate>Sat, 06 Mar 2010 04:16:45 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[Resources]]></category>
		<category><![CDATA[automation]]></category>
		<category><![CDATA[cache]]></category>
		<category><![CDATA[catalog]]></category>
		<category><![CDATA[index]]></category>
		<category><![CDATA[inventory]]></category>
		<category><![CDATA[layered navigation]]></category>
		<category><![CDATA[magento]]></category>
		<category><![CDATA[rebuild]]></category>
		<category><![CDATA[refresh]]></category>
		<category><![CDATA[search]]></category>

		<guid isPermaLink="false">http://www.nvncbl.com/?p=488</guid>
		<description><![CDATA[When writing processes to automate some of Magento&#8217;s normally laborious tasks, perhaps for a product-import script, a mass attribute update script, category import, or inventory adjustment, keep in mind that you may have to refresh some kind of cache &#8212; especially when working with attributes.  If you are encountering quirks or inconsistencies with your [...]]]></description>
			<content:encoded><![CDATA[<p>When writing processes to automate some of Magento&#8217;s normally laborious tasks, perhaps for a product-import script, a mass attribute update script, category import, or inventory adjustment, keep in mind that you may have to refresh some kind of cache &#8212; especially when working with attributes.  If you are encountering quirks or inconsistencies with your data, try these:</p>
<ul>
<li>Rebuild Catalog Index

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">Mage<span style="color: #339933;">::</span><span style="color: #004000;">getSingleton</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'catalog/index'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">rebuild</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

</li>
<li>Rebuild Flat Catalog Product

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">Mage<span style="color: #339933;">::</span><span style="color: #004000;">getResourceModel</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'catalog/product_flat_indexer'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">rebuild</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

</li>
<li>Inventory Stock

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">Mage<span style="color: #339933;">::</span><span style="color: #004000;">getSingleton</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'cataloginventory/stock_status'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">rebuild</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

</li>
</ul>
<p>For more cache refreshes, such as:</p>
<ul>
<li>Catalog Rewrites</li>
<li>Layered Navigation Indices</li>
<li>Product Image</li>
<li>Search Index</li>
</ul>
<p>&#8230; please refer to the source of this knowledge <a class="external" title="Magento Refresh Cache" href="http://www.magentocommerce.com/boards/viewthread/43238/#t156277" target="_blank">http://www.magentocommerce.com/boards/viewthread/43238/#t156277</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.nvncbl.com/2010/03/refresh-magento-cache-programmatically/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Claiming this Blog on Technorati</title>
		<link>http://www.nvncbl.com/2009/09/claiming-this-blog-on-technorati/</link>
		<comments>http://www.nvncbl.com/2009/09/claiming-this-blog-on-technorati/#comments</comments>
		<pubDate>Mon, 07 Sep 2009 03:36:44 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[Resources]]></category>
		<category><![CDATA[technorati]]></category>

		<guid isPermaLink="false">http://www.nvncbl.com/?p=411</guid>
		<description><![CDATA[Here goes: wshkb4gy8m
So in order for me to &#8220;claim&#8221; this blog for submission on Technorati, I have to create a post with a certain jumbled string in it.  Technorati will then read the jumbled string and verify that I am indeed the owner of this site.
Technorati is a search engine for blogs.  I [...]]]></description>
			<content:encoded><![CDATA[<p>Here goes: wshkb4gy8m</p>
<p>So in order for me to &#8220;claim&#8221; this blog for submission on <a class="external" rel="nofollow" href="http://www.technorati.com/">Technorati</a>, I have to create a post with a certain jumbled string in it.  Technorati will then read the jumbled string and verify that I am indeed the owner of this site.</p>
<p>Technorati is a search engine for blogs.  I believe I&#8217;m jumping onto the bandwagon a little later than most people, but it&#8217;s better late than never.</p>
<p>Hopefully that works, otherwise I&#8217;m stuck with a useless post.</p>
<p><strong>[edit]</strong> &#8211; it worked.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nvncbl.com/2009/09/claiming-this-blog-on-technorati/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>mod_rewrite Reference</title>
		<link>http://www.nvncbl.com/2009/09/mod-rewrite-reference/</link>
		<comments>http://www.nvncbl.com/2009/09/mod-rewrite-reference/#comments</comments>
		<pubDate>Tue, 01 Sep 2009 19:06:39 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[Resources]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[mod_rewrite]]></category>

		<guid isPermaLink="false">http://www.nvncbl.com/?p=394</guid>
		<description><![CDATA[Having a reference for basic mod_rewrite examples on hand is always a good idea.  About once every two weeks, I have to set up a server&#8217;s URL rewrites, and because I don&#8217;t use it that often, I&#8217;m susceptible to forgetting its exact syntax.
The article outlines:

The basic mod_rewrite layout
Basic redirects
Handling no &#8216;www&#8217;
Blocking specific IP addresses
Stripping query [...]]]></description>
			<content:encoded><![CDATA[<p>Having a reference for <a class="external" href="http://www.noupe.com/php/10-mod_rewrite-rules-you-should-know.html">basic mod_rewrite examples</a> on hand is always a good idea.  About once every two weeks, I have to set up a server&#8217;s URL rewrites, and because I don&#8217;t use it that often, I&#8217;m susceptible to forgetting its exact syntax.</p>
<p><span id="more-394"></span>The article outlines:</p>
<ul>
<li>The basic mod_rewrite layout</li>
<li>Basic redirects</li>
<li>Handling no &#8216;www&#8217;</li>
<li>Blocking specific IP addresses</li>
<li>Stripping query strings</li>
<li>Hotlinking prevention</li>
<li>&#8230; and more</li>
</ul>
<p>Thanks to <a class="external" title="Cameron Chapman" href="http://cameronchapman.com/">Cameron Chapman</a> writing for <a class="external" title="Noupe" href="http://www.noupe.com/">Noupe</a>, and to <a class="external" href="http://twitter.com/RedstageMagento">@RedstageMagento</a> for spreading this through Twitter.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nvncbl.com/2009/09/mod-rewrite-reference/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Solution to Excel&#8217;s CSV Output Formats</title>
		<link>http://www.nvncbl.com/2009/08/solution-to-excels-csv-output-formats/</link>
		<comments>http://www.nvncbl.com/2009/08/solution-to-excels-csv-output-formats/#comments</comments>
		<pubDate>Fri, 14 Aug 2009 05:23:17 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[Resources]]></category>
		<category><![CDATA[csv]]></category>
		<category><![CDATA[excel]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[xml]]></category>

		<guid isPermaLink="false">http://www.nvncbl.com/?p=352</guid>
		<description><![CDATA[Recently I&#8217;ve had to import a client&#8217;s catalog data from Excel 2007 to the Magento eCommerce Platform.  The data in Excel was unsurprisingly in a format that was unsupported by Magento&#8217;s import methods.  Using code, I needed to parse Excel data into the format Magento required.  In PHP, I wasn&#8217;t aware of [...]]]></description>
			<content:encoded><![CDATA[<p>Recently I&#8217;ve had to import a client&#8217;s catalog data from Excel 2007 to the Magento eCommerce Platform.  The data in Excel was unsurprisingly in a format that was unsupported by Magento&#8217;s import methods.  Using code, I needed to parse Excel data into the format Magento required.  In PHP, I wasn&#8217;t aware of any way to interface with .xls or .xlsx files, so I tried exporting the data to flat-file CSV, where it could be easily manipulated using PHP&#8217;s native CSV functions.</p>
<p><span id="more-352"></span>Unfortunately, none of the three CSV formats that Excel outputs could be properly parsed as CSV.  For example, accepted CSV standards state that values should be:</p>
<pre>"value1","value2","escaped "" double quote", "value 3", "", "", "7th column"</pre>
<p>But in Excel&#8217;s version of CSV, that would look like:</p>
<pre>value1,value2,"escaped "" double quote",value 3,,,7th column
</pre>
<p>It&#8217;s terribly inconsistent in its use of double quotes, confusing the hell out of many CSV parsers.</p>
<p><strong>The Solution:</strong></p>
<p><a title="CSV to XML Converter" href="http://www.creativyst.com/Prod/15/" class="external">CSV to XML Converter</a> by <a title="Creativyst" href="http://www.creativyst.com/" class="external">Creativyst(R)</a>.  It takes in CSV garbage and returns immaculate and clean XML.  Then use your language-of-choice&#8217;s XML functions to work with the data.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nvncbl.com/2009/08/solution-to-excels-csv-output-formats/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Beginnings</title>
		<link>http://www.nvncbl.com/2008/12/beginnings/</link>
		<comments>http://www.nvncbl.com/2008/12/beginnings/#comments</comments>
		<pubDate>Wed, 17 Dec 2008 19:41:32 +0000</pubDate>
		<dc:creator>Antonio</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[Resources]]></category>
		<category><![CDATA[ajax]]></category>
		<category><![CDATA[redstage]]></category>
		<category><![CDATA[web 2.0]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.nvncbl.com/wordpress/?p=8</guid>
		<description><![CDATA[No &#8220;greetings readers&#8221; here, although anyone reading this is more than welcome.  The purpose of this blog is to serve as a utility for me to log my thoughts related to programming.  Often times when I&#8217;m working on a project, I&#8217;ll encounter an issue that I&#8217;ve encountered before.  The problem is that I don&#8217;t necessarily [...]]]></description>
			<content:encoded><![CDATA[<p>No &#8220;greetings readers&#8221; here, although anyone reading this is more than welcome.  The purpose of this blog is to serve as a utility for me to log my thoughts related to programming.  Often times when I&#8217;m working on a project, I&#8217;ll encounter an issue that I&#8217;ve encountered before.  The problem is that I don&#8217;t necessarily remember the solution, and I have to go through the whole process of &#8220;figuring it out&#8221; all over again. With this blog though, I&#8217;m hoping that I can (going forward) document my issues and solutions in case I return.</p>
<p>What kind of programming do I do now?  I&#8217;m heavily engaged in web development, predominantly the Web 2.0/AJAX practices.  I work for <a title="RedStage Networks" href="http://www.redstage.com" class="external">RedStage Networks</a>, based in Hoboken, NJ.  I&#8217;m glad to be part of a highly engaged and enthusiastic team, always working with cutting edge technology.</p>
<p>So if anyone ever reads this, then happy reading.  If not, then &#8220;memo-to-self&#8221;: tag, tag, tag, tag your posts.  How will you ever find solutions if you don&#8217;t tag your posts?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.nvncbl.com/2008/12/beginnings/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
