How canI iGoogle-like Drag & Drop converting classes ASP

coachoutletulz

New Member
How can i use this code in ASP?.\[code\]<?php/* establish the mysql connection *//* require_once 'mysql_connect.php';$data = http://stackoverflow.com/questions/12045449/$_POST;foreach ($data as $row) { /* split up in segments */ $segments = explode(':', $row); /* define the column */ $column_id = $segments[0]; /* the blocks */ $blocks = explode(',', $segments[1]); /* we take each block */ foreach ($blocks as $order_id => $block_id) { /* check if the block is already present in the database */ $block_exists = mysql_fetch_row(mysql_query("SELECT * FROM blocks WHERE block_id = '{$block_id}'")); /* if not, we insert it */ if ($block_exists == FALSE) { /* mysql_query("INSERT INTO blocks (block_id, column_id, order_id) VALUES ('{$block_id}', '{$column_id}', {$order_id})"); */ echo date("h:i:s") . " - Moved block: <strong>{$block_id}</strong> to column: <strong>{$column_id}</strong> and updated rank to: <strong>{$order_id}</strong><br />"; } /* or else we update it */ else { /* mysql_query("UPDATE blocks SET block_id = '{$block_id}', column_id = '{$column_id}', order_id = {$order_id} WHERE unique_id = ".$block_exists[0]); */ echo date("h:i:s") . " - Moved block: <strong>{$block_id}</strong> to column: <strong>{$column_id}</strong> and updated rank to: <strong>{$order_id}</strong><br />"; } }}?>\[/code\]
 
Back
Top