<?xml version="1.0" encoding="utf-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: Sortable (Drag &#038; Drop) Table Rows</title>
	<atom:link href="http://www.nerdydork.com/sortable-drag-drop-table-rows.html/feed" rel="self" type="application/rss+xml" />
	<link>http://www.nerdydork.com/sortable-drag-drop-table-rows.html</link>
	<description>Dustin Davis reviews... the internet.</description>
	<pubDate>Fri, 08 Aug 2008 18:51:33 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5.1</generator>
		<item>
		<title>By: Yogesh</title>
		<link>http://www.nerdydork.com/sortable-drag-drop-table-rows.html#comment-4290</link>
		<dc:creator>Yogesh</dc:creator>
		<pubDate>Thu, 05 Jun 2008 06:20:57 +0000</pubDate>
		<guid isPermaLink="false">http://www.nerdydork.com/sortable-drag-drop-table-rows.html#comment-4290</guid>
		<description>Hello Dustin,
Thanks for your reply n code.
I got it working... :)</description>
		<content:encoded><![CDATA[<p>Hello Dustin,<br />
Thanks for your reply n code.<br />
I got it working&#8230; <img src='http://www.nerdydork.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dustin</title>
		<link>http://www.nerdydork.com/sortable-drag-drop-table-rows.html#comment-4288</link>
		<dc:creator>Dustin</dc:creator>
		<pubDate>Tue, 03 Jun 2008 12:37:14 +0000</pubDate>
		<guid isPermaLink="false">http://www.nerdydork.com/sortable-drag-drop-table-rows.html#comment-4288</guid>
		<description>The PHP Snippet in this post is all the code I'm using to update the database.

Here it is with comments...

&lt;strong&gt;// create an array containing the new order passed in&lt;/strong&gt;
$order = split('id', $_GET['order']);
&lt;strong&gt;// drop the first item in the array since it is garbage&lt;/strong&gt;
array_shift($order);

&lt;strong&gt;// loop through each item in the order array&lt;/strong&gt;
foreach ($order as $val) {
 &#160; &#160; &lt;strong&gt;// create and execute query to update the "rank" or order of the host&lt;/strong&gt;
 &#160; &#160; $sql = “UPDATE hosts SET rank=”.++$rank.” WHERE id=$val;”;
 &#160; &#160; mysql_query($sql);
}</description>
		<content:encoded><![CDATA[<p>The PHP Snippet in this post is all the code I&#8217;m using to update the database.</p>
<p>Here it is with comments&#8230;</p>
<p><strong>// create an array containing the new order passed in</strong><br />
$order = split(&#8217;id&#8217;, $_GET['order']);<br />
<strong>// drop the first item in the array since it is garbage</strong><br />
array_shift($order);</p>
<p><strong>// loop through each item in the order array</strong><br />
foreach ($order as $val) {<br />
 &nbsp; &nbsp; <strong>// create and execute query to update the &#8220;rank&#8221; or order of the host</strong><br />
 &nbsp; &nbsp; $sql = “UPDATE hosts SET rank=”.++$rank.” WHERE id=$val;”;<br />
 &nbsp; &nbsp; mysql_query($sql);<br />
}</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: yogesh</title>
		<link>http://www.nerdydork.com/sortable-drag-drop-table-rows.html#comment-4287</link>
		<dc:creator>yogesh</dc:creator>
		<pubDate>Tue, 03 Jun 2008 10:14:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.nerdydork.com/sortable-drag-drop-table-rows.html#comment-4287</guid>
		<description>hello,
Its really great script to work on.
I m trying to include this into my project but i m not getting how to store sort order in database.
I m using this in cakephp.
Can you please explain with code?</description>
		<content:encoded><![CDATA[<p>hello,<br />
Its really great script to work on.<br />
I m trying to include this into my project but i m not getting how to store sort order in database.<br />
I m using this in cakephp.<br />
Can you please explain with code?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Brian</title>
		<link>http://www.nerdydork.com/sortable-drag-drop-table-rows.html#comment-3890</link>
		<dc:creator>Brian</dc:creator>
		<pubDate>Thu, 09 Aug 2007 19:05:27 +0000</pubDate>
		<guid isPermaLink="false">http://www.nerdydork.com/sortable-drag-drop-table-rows.html#comment-3890</guid>
		<description>Thanks for this, it was very helpful. I wish scriptaculous would release a better version that dealt with sorting tables...</description>
		<content:encoded><![CDATA[<p>Thanks for this, it was very helpful. I wish scriptaculous would release a better version that dealt with sorting tables&#8230;</p>
]]></content:encoded>
	</item>
</channel>
</rss>
