<?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>101 Interactive R&#38;D</title>
	<atom:link href="http://thinktank.101interactive.net/feed/" rel="self" type="application/rss+xml" />
	<link>http://thinktank.101interactive.net</link>
	<description>Just another 101interactive.net Blogs site</description>
	<lastBuildDate>Wed, 04 Aug 2010 22:52:55 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1</generator>
		<item>
		<title>Magento &#8211; Programmatically Add Entries to URL Rewrite Mgmnt Console</title>
		<link>http://thinktank.101interactive.net/magento-programmatically-add-entries-to-url-rewrite-mgmnt-console/</link>
		<comments>http://thinktank.101interactive.net/magento-programmatically-add-entries-to-url-rewrite-mgmnt-console/#comments</comments>
		<pubDate>Wed, 04 Aug 2010 19:39:14 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Lab]]></category>

		<guid isPermaLink="false">http://thinktank.101interactive.net/?p=23</guid>
		<description><![CDATA[Mage::getModel('core/url_rewrite') -&#62;setIsSystem(0) -&#62;setStoreId($storeId) -&#62;setOptions('RP') -&#62;setIdPath('index.php?cat=c' . $oscCategoryId . '_' . $this-&#62;strip($data['name']) . '.html') -&#62;setTargetPath($categoryModel-&#62;getUrlPath() . '.html') -&#62;setRequestPath('index.php?cat=c' . $oscCategoryId . '_' . $this-&#62;strip($data['name']) . '.html') -&#62;save();]]></description>
			<content:encoded><![CDATA[            <script type="text/javascript" src="http://thinktank.101interactive.net/wp-content/plugins/wordpress-code-snippet/scripts/shBrushPhp.js"></script>
<p><pre class="brush: php">Mage::getModel('core/url_rewrite')
	-&gt;setIsSystem(0)
	-&gt;setStoreId($storeId)   
	-&gt;setOptions('RP') 	
	-&gt;setIdPath('index.php?cat=c' . $oscCategoryId . '_' . $this-&gt;strip($data['name']) . '.html')
	-&gt;setTargetPath($categoryModel-&gt;getUrlPath() . '.html')
	-&gt;setRequestPath('index.php?cat=c' . $oscCategoryId . '_' . $this-&gt;strip($data['name']) . '.html')
	-&gt;save();</pre></p>
]]></content:encoded>
			<wfw:commentRss>http://thinktank.101interactive.net/magento-programmatically-add-entries-to-url-rewrite-mgmnt-console/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Oscommerce to Magento Product Import with URL Mapping for SEO</title>
		<link>http://thinktank.101interactive.net/oscommerce-to-magento-product-import-url-mapping/</link>
		<comments>http://thinktank.101interactive.net/oscommerce-to-magento-product-import-url-mapping/#comments</comments>
		<pubDate>Wed, 04 Aug 2010 19:17:39 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Lab]]></category>

		<guid isPermaLink="false">http://thinktank.101interactive.net/?p=8</guid>
		<description><![CDATA[Here is a brief writeup on how to import products and categories from an osCommerce based store and at the same time generate a RewriteMap to map your previous shops URL&#8217;s to your new ones using 301 redirects. Steps are &#8230; <a href="http://thinktank.101interactive.net/oscommerce-to-magento-product-import-url-mapping/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[            <script type="text/javascript" src="http://thinktank.101interactive.net/wp-content/plugins/wordpress-code-snippet/scripts/shBrushPhp.js"></script>
            <script type="text/javascript" src="http://thinktank.101interactive.net/wp-content/plugins/wordpress-code-snippet/scripts/shBrushXml.js"></script>
<p>Here is a brief writeup on how to import products and categories from an osCommerce based store and at the same time generate a RewriteMap to map your previous shops URL&#8217;s to your new ones using 301 redirects.  </p>
<p>Steps are as follows:</p>
<p>Use magento connect manager to install the Oscommerce Import plugin using extension key &#8216;magento-core/Mage_Oscommerce&#8217;.</p>
<p>As of this time, support for Magento 1.4.1.1 requires you to overwrite Run.php in the /magentoroot/app/code/core/Mage/Oscommerce/Block/Adminhtml/Import directory with the following file <a href='http://svn.magentocommerce.com/source/branches/1.4-trunk/app/code/core/Mage/Oscommerce/Block/Adminhtml/Import/Run.php' target="_blank">found here (rename to Run.php)</a> .</p>
<p>Upload and overwrite an updated version of Oscommerce.php to the /magentoroot/app/code/core/Mage/Oscommerce/Model dir.  Download copy of this file <a href='http://thinktank.101interactive.net/files/2010/08/Oscommerce.php_.txt'>here</a>.</p>
<p>Take note that there is some code that you will need to update to create the proper markup for the oscommerce url&#8217;s from your old store.  This will be store specific so what&#8217;s included is just a guideline of what needs to be done.</p>
<p>Be aware that this script will create a new Root category and store view under the website you select.  </p>
<p>Now import your products and categories by going to System -> Import/Export -> OsCommerce and setting up a profile and then running the profile.  More details can be found <a href="http://www.magentocommerce.com/wiki/import-export_and_data_manipulation/creating_an_oscommerce_import_profile" target="_blank">here</a>.</p>
<p>Mod Rewrite mods are as follows:</p>
<p>The script will use the mapped .txt file created by the importer script.  An example of the one that&#8217;s created by my import script can be found <a href='http://thinktank.101interactive.net/files/2010/08/rewritemap.txt' target="_blank">here</a>.</p>
<p><pre class="brush: xml">#place the following in vhost.conf or http.conf
#make sure the following is not inside the &lt;Directory /path/to/dir&gt;&lt;/Directory&gt; tags
&lt;IfModule mod_rewrite.c&gt;
    Options +FollowSymLinks
    RewriteEngine on
    RewriteMap osccat txt:/var/www/vhosts/rockstarenergyshop.com/subdomains/core/httpdocs/osc-to-magento-cat.txt
    RewriteMap oscprod txt:/var/www/vhosts/rockstarenergyshop.com/subdomains/core/httpdocs/osc-to-magento-prod.txt
&lt;/IfModule&gt;


#place the following in the magento .htaccess file right after the #RewriteBase /magento/ line

RewriteCond %{QUERY_STRING}  ^cat=(.*.html).*
RewriteRule ^index.php$ /${osccat:%1}? [R=301,L]
	
RewriteCond %{QUERY_STRING}  ^info=(.*.html).*
RewriteRule ^product_info.php$ /${oscprod:%1}? [R=301,L]</pre></p>
<div style="clear:both;"></div>
<p>References:</p>
<p>http://www.magentocommerce.com/boards/viewthread/43238/#t156277</p>
<p>http://corz.org/serv/tricks/htaccess2.php</p>
<p>http://www.magentocommerce.com/wiki/import-export_and_data_manipulation/creating_an_oscommerce_import_profile</p>
]]></content:encoded>
			<wfw:commentRss>http://thinktank.101interactive.net/oscommerce-to-magento-product-import-url-mapping/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

