<?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>Toolbox Digital Services &#187; Magento</title>
	<atom:link href="http://toolboxdigital.com/category/magento/feed/" rel="self" type="application/rss+xml" />
	<link>http://toolboxdigital.com</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Thu, 05 Aug 2010 09:15:28 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.5</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>How to Delete Test Orders and Reset Counters in Magento</title>
		<link>http://toolboxdigital.com/2009/10/how-to-delete-test-orders-and-reset-counters-in-magento/</link>
		<comments>http://toolboxdigital.com/2009/10/how-to-delete-test-orders-and-reset-counters-in-magento/#comments</comments>
		<pubDate>Tue, 06 Oct 2009 13:30:45 +0000</pubDate>
		<dc:creator>Dan Luton</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://toolboxdigital.com/?p=113</guid>
		<description><![CDATA[You&#8217;d have thought there was a basic provision for this in Magento, but unfortunately this is not the case and, looking at this thread on the Magento forums, it&#8217;s not ...]]></description>
			<content:encoded><![CDATA[<p>You&#8217;d have thought there was a basic provision for this in Magento, but unfortunately this is not the case and, looking at <a href="http://www.magentocommerce.com/boards/viewthread/1680/">this thread</a> on the Magento forums, it&#8217;s not something that Varien are looking at correcting at any point in the near future.  The problem is that in-development stores need testing; to do that properly, you need to push test orders fully through the system, from invoice to completion.</p>

<p>So what happens when you want to launch the site and you&#8217;re stuck with dozens of undesirable test orders?  Well, read on to find out how&#8230;</p><span id="more-113"></span>

<p>The first thing you need to bear in mind is that, whilst this is possible using a load of MySQL queries, that kind of thing on a working site is pretty scary and risky if you&#8217;re not sure what you&#8217;re doing.  For this reason, I would recommend purchasing the Yireo extension <a href="https://www.yireo.com/software/delete-any-order">Delete Any Order</a> which will do the job for you.  It will also scan the database for orphaned sales data and remove, something which would take significant time by hand.</p>

<p>The extension costs a mere EUR20 and is worth it just for the piece of mind.  Whatever you choose, please ensure you <strong>backup your database first</strong>.</p>
<h3>Deleting the Orders</h3>
<p>Once you&#8217;ve purchased the extension, upload it to the root of your Magento site.</p>

<p>This will give you an additional option in System-&gt;Tools called &#8220;Delete Any Order&#8221;.  Select it to run the extension.</p>

<p>If you are preparing a store for launch and want to remove all orders and reset the sales reference numbers, select all orders and choose the &#8220;Delete&#8221; option from the drop-down menu (top-right).</p>
<h3>Reset the Counters</h3>
<p>You don&#8217;t really want your new store starting orders, invoices, shipment and credit memos from some random number do you?  Do the following to reset these counters to the default (1000001).</p>
<p>
1. Use PHPMyAdmin to view your database.<br/>
2. Click the &#8220;SQL&#8221; tab.<br/>
3. Paste the following query into the code entry window:</p>
<pre class="brush:text">TRUNCATE `eav_entity_store`;
ALTER TABLE `eav_entity_store` AUTO_INCREMENT=1;
SET FOREIGN_KEY_CHECKS=1;</pre>
<p>4. If all goes well, the system will display a message stating that the query was a success.</p>
<p>The next order placed will now use the default number to start.</p>

<p>I recommend testing these steps out on a test site rather than your live environment, if that&#8217;s possible &#8211; just so that you are comfortable with the steps before deploying on a live site.</p>]]></content:encoded>
			<wfw:commentRss>http://toolboxdigital.com/2009/10/how-to-delete-test-orders-and-reset-counters-in-magento/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Moving a Magento Installation</title>
		<link>http://toolboxdigital.com/2009/09/moving-a-magento-installation/</link>
		<comments>http://toolboxdigital.com/2009/09/moving-a-magento-installation/#comments</comments>
		<pubDate>Tue, 29 Sep 2009 16:10:47 +0000</pubDate>
		<dc:creator>Dan Luton</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://toolboxdigital.com/?p=85</guid>
		<description><![CDATA[If you&#8217;ve ever had to move a Magento site from one server/domain to another, you&#8217;ll already know how tricky it can be to get things working right afterwards.  The ...]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;ve ever had to move a <a href="http://www.magentocommerce.com" title="Magento">Magento</a> site from one server/domain to another, you&#8217;ll already know how tricky it can be to get things working right afterwards.  The following article describes the processes and steps involved to successfully move your Magento site to a new server/domain name, along with some possible solutions for further issues you may encounter.</p><span id="more-85"></span>

<p><img src="http://toolboxdigital.com/wp-content/uploads/2009/09/mage-ss1.jpg" alt="mage-ss1" title="mage-ss1" width="774" height="246" class="alignnone size-full wp-image-96" /></p>

<h3>1. Package up and/or download the site files</h3>

<p>I used my Control Panel&#8217;s &#8220;site backup&#8221; feature here for two reasons: a) you have less to download, and b) you can be sure you have all the files intact when you deploy the other end.&nbsp; If you don&#8217;t have this feature with your host, you can manually download the files &#8211; but be sure to check you have everything and that there were no errors during the downloading process!</p>

<p>Also, if you have shell access to the server, you can zip up the whole lot and download in one go &#8211; this will make it easier to deploy on the receiving end, and will ensure none of the files are corrupted and/or go astray during the upload.</p>

<p>Once I had my package downloaded, I deployed to the new server &#8211; again, if you can, upload the zip package and extract via the server.&nbsp; If you are unable to do this, extract the package locally and upload the files manually (cue: cup of tea).</p>

<h3>2. Take a backup of the original site&#8217;s database</h3>

<p>Using PHPMyAdmin, take a full backup of the site database that Magento was using.&nbsp; This should be in the form of a .sql file.&nbsp; Make sure you take a full backup of all the database tables.  If the database is particularly large, use compression on the export (built-in to PHPMyAdmin) which will help keep within the file upload limits.</p>

<h3>3. Import the SQL file into the new database</h3>

<p>Working in PHPMyAdmin on the target server, simply import the SQL file into an empty database (you may need to create one first).</p>

<h3>4. Update the live site URL data in the database</h3>

<p>This needs to be done in two places in the database.&nbsp; Using PHPMyAdmin, select the table named <strong>core_config_data</strong> and locate the following database rows:</p>

<p><strong>web/unsecure/base_url</strong><br/>
<strong>web/secure/base_url</strong></p>

<p>Note the text value for each entry &#8211; this corresponds to the root URL of the site.&nbsp; This should be confirmed as the data should reflect the current site&#8217;s root URL.&nbsp; To change, simply click the edit button for each of the two rows and input your new base URL value into the text box, saving when you&#8217;ve finished each one.</p>

<h3>5. Update local.xml with the new configuration details</h3>

<p>You can find your <strong>local.xml</strong> file in the <strong>app/etc</strong> directory.</p>

<p>Look through the file until you see the database connection information.&nbsp; If will look similar to the following:</p>

<pre class="brush:xml">
&lt;default_setup>
  &lt;connection>
     &lt;host>&lt;![CDATA[localhost]]&gt;&lt;/host>
     &lt;username>&lt;![CDATA[my_user]]&gt;&lt;/username>
     &lt;password>&lt;![CDATA[my_pass]]&gt;&lt;/password>
     &lt;dbname>&lt;![CDATA[my_database]]&gt;&lt;/dbname>
     &lt;active>1&lt;/active>
  &lt;/connection>
&lt;/default_setup>
</pre>

<p>Then change the values in the square brackets after the CDATA tags to your new database server settings, for example:</p>

<pre class="brush:xml">
&lt;username>&lt;![CDATA[mynewusername]]&gt;&lt;/username> 
</pre>

<p>Once done, save the file.</p>

<h3>6. Delete the cache data</h3>

<p>Simply locate your <strong>var</strong> folder and delete all content within.</p>

<p>You may also need to manually deploy the <em>.htaccess</em> file from the old site to the new site &#8211; so if your links do not work on the new server, make sure .htaccess is present and correct.</p>

<h3>Problem 1: MagentoConnect No Longer Works</h3>

<p>If you are planning to update Magento Core, any modules, or add new extensions to your Magento site, you will need to correct this since the Connect Manager (/downloader on the server) references the old site, and the links are hard-coded into the files, making it practically impossible to update manually.  There is also a real risk of accidentally updating files on the old server if running MagentoConnect (if the old site still exists).</p>

<p>The best way to sort this problem is this:</p>

<p><strong>1. Delete or Rename the /downloader directory</strong><br/>
Probably safer to rename this for the time being.  You will need to do this via FTP or your control panel file manager.</p>

<p><strong>2. Obtain a fresh copy of Magento</strong><br/>
The version number will need to be the same as the version you are running on your site.  Download the .zip file and extract locally to your computer.</p>

<p><strong>3. Upload the &#8220;clean&#8221; /downloader directory</strong><br/>
Once you have the extracted files from step 2, find the /downloader directory and upload it to your Magento installation.</p>

<p><strong>4. Run MagentoConnect and perform a core update</strong><br/>
You can leave this step for now if you prefer not to update your installation.  This will check all core modules and update as necessary, and will also add the missing list of core modules back into MagentoConnect.  Paste the following extension key into MagentoConnect Manager:</p>

<p><strong>magento-core/Mage_All_Latest</strong></p>

<p>You can also do this for any extensions you have installed, which will also add them back into the list.</p>

<h3>Problem 2: &#8220;Notice: Undefined index&#8221; Error when running the site</h3>
<p>This could be caused by an error during the MySQL import and is possibly related to auto-increments on certain rows in the database.</p>

<p>Try this and see if it fixes the problem:</p>

<p>1. Logon to PHPMyAdmin.<br/>
2. Locate the following tables: &#8220;core_store&#8221;, &#8220;core_store_group&#8221; &#038; &#8220;core_website&#8221;.<br/>
3. Note the &#8220;website_id&#8221; value for the admin code.  It should have a 0 (zero) value; if not, change it to zero and save.  Repeat this for all three tables.</p>]]></content:encoded>
			<wfw:commentRss>http://toolboxdigital.com/2009/09/moving-a-magento-installation/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
	</channel>
</rss>
