<?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>kieranbarnes &#187; Download</title>
	<atom:link href="http://bloke.org/tag/download/feed/" rel="self" type="application/rss+xml" />
	<link>http://bloke.org</link>
	<description>do you know where your towel is?</description>
	<lastBuildDate>Sat, 21 Aug 2010 12:03:59 +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>WP-O-Matic Bug Fixes Round Up</title>
		<link>http://bloke.org/php/wp-o-matic-bug-fixes-round-up/</link>
		<comments>http://bloke.org/php/wp-o-matic-bug-fixes-round-up/#comments</comments>
		<pubDate>Wed, 16 Jul 2008 14:02:22 +0000</pubDate>
		<dc:creator>Kieran</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[campaign id]]></category>
		<category><![CDATA[database error]]></category>
		<category><![CDATA[Download]]></category>
		<category><![CDATA[Duplicate]]></category>
		<category><![CDATA[getItemHash]]></category>
		<category><![CDATA[hash values]]></category>
		<category><![CDATA[mysql server]]></category>
		<category><![CDATA[sql errors]]></category>
		<category><![CDATA[sql syntax]]></category>
		<category><![CDATA[WP-O-Matic]]></category>

		<guid isPermaLink="false">http://bloke.org/?p=298</guid>
		<description><![CDATA[I've run into quite a few issues in the latest 1.0RC3-7 release of WP-O-Matic. Here's a round up of the bug fixes and addons you need to actually this potentially useful product useful!
Also, it includes a well known MySQL bug fix.

The well known MySQL bug fix is a fix for the following SQL errors,
WordPress database [...]


Related posts:<ol><li><a href='http://bloke.org/php/wordpress-wp-o-matic-duplicate-posts-fix/' rel='bookmark' title='Permanent Link: Wordpress WP-O-Matic Duplicate Posts Fix'>Wordpress WP-O-Matic Duplicate Posts Fix</a> <small>Got a problem with WP-O-Matic creating duplicate posts? Or just...</small></li>
<li><a href='http://bloke.org/php/wp-o-matic-fix-for-wordpress-25/' rel='bookmark' title='Permanent Link: WP-o-Matic fix for Wordpress 2.5'>WP-o-Matic fix for Wordpress 2.5</a> <small>WP-o-Matic makes autoblogging a easy by automatically creating posts from...</small></li>
<li><a href='http://bloke.org/php/cubecart-and-wordpress-integration/' rel='bookmark' title='Permanent Link: CubeCart and Wordpress Integration'>CubeCart and Wordpress Integration</a> <small>Following my 100% CubeCart orientated posts, here's another late night...</small></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>I've run into quite a few issues in the latest 1.0RC3-7 release of WP-O-Matic. Here's a round up of the bug fixes and addons you need to actually this potentially useful product useful!<br />
Also, it includes a well known MySQL bug fix.</p>
<p><span id="more-298"></span></p>
<p>The well known MySQL bug fix is a fix for the following SQL errors,</p>
<pre lang="sql">WordPress database error You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' feed_id = 1, hash = 178e9c301b4781e2c7248ed115802291995cd2b6'' at line 2 for query SELECT * FROM `wp_wpo_campaign_post` WHERE campaign_id = 1, feed_id = 1, hash = '178e9c301b4781e2c7248ed115802291995cd2b6'  made by isDuplicate</pre>
<p>And/Or</p>
<pre lang="sql">WordPress database error Unknown column 'hash' in 'field list' for query INSERT INTO wp_wpo_campaign_post (campaign_id, feed_id, , post_id, hash) VALUES ('1','1','4300','9b79457042fd10a210da6110ecfdbed0ed1d45c9') made by processItem</pre>
<p>The problem is that MySQL doesn't like the commas in the multiple where clauses. You need to edit wpomatic.php</p>
<p>Find the <em>isDuplicate() </em>function</p>
<pre lang="php"> function isDuplicate(&amp;$campaign, &amp;$feed, &amp;$item)
{
global $wpdb;
$hash = $this-&gt;getItemHash($item);
$row = $wpdb-&gt;get_row("SELECT * FROM `{$this-&gt;db['campaign_post']}`
WHERE campaign_id = {$campaign-&gt;id}, feed_id = {$feed-&gt;id}, hash = '$hash' ");
return !! $row;
}</pre>
<p>and replace with</p>
<pre lang="php"> function isDuplicate(&amp;$campaign, &amp;$feed, &amp;$item)
{
global $wpdb;
$hash = $this-&gt;getItemHash($item);
$row = $wpdb-&gt;get_row("SELECT * FROM `{$this-&gt;db['campaign_post']}`
WHERE campaign_id = {$campaign-&gt;id} and feed_id = {$feed-&gt;id} and hash = '$hash' ");
return !! $row;
}</pre>
<p>Here's the previous fixes.</p>
<p><a title="WP-O-Matic Cron Hangs" href="http://bloke.org/php/wp-o-matic-cron-hangs/">WP-O-Matic Cron Hangs</a></p>
<p><a title="WP-o-Matic Upgrade Fix" href="http://bloke.org/php/wp-o-matic-upgrade-fix/">WP-o-Matic Upgrade Fix</a></p>
<p><a title="http://bloke.org/php/wordpress-wp-o-matic-duplicate-posts-fix/" href="http://bloke.org/php/wordpress-wp-o-matic-duplicate-posts-fix/">Wordpress WP-O-Matic Duplicate Posts Fix</a></p>
<p><strong>This is my modified wpomatic.php file -&gt; </strong><a href="http://bloke.org/wp-content/uploads/2008/07/wpomaticphp.txt">Direct Download</a></p>


<p>Related posts:<ol><li><a href='http://bloke.org/php/wordpress-wp-o-matic-duplicate-posts-fix/' rel='bookmark' title='Permanent Link: Wordpress WP-O-Matic Duplicate Posts Fix'>Wordpress WP-O-Matic Duplicate Posts Fix</a> <small>Got a problem with WP-O-Matic creating duplicate posts? Or just...</small></li>
<li><a href='http://bloke.org/php/wp-o-matic-fix-for-wordpress-25/' rel='bookmark' title='Permanent Link: WP-o-Matic fix for Wordpress 2.5'>WP-o-Matic fix for Wordpress 2.5</a> <small>WP-o-Matic makes autoblogging a easy by automatically creating posts from...</small></li>
<li><a href='http://bloke.org/php/cubecart-and-wordpress-integration/' rel='bookmark' title='Permanent Link: CubeCart and Wordpress Integration'>CubeCart and Wordpress Integration</a> <small>Following my 100% CubeCart orientated posts, here's another late night...</small></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://bloke.org/php/wp-o-matic-bug-fixes-round-up/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
	</channel>
</rss>
