Reorder..PHP/MYSQL

Firstly: A thankyou to all of you whove been answerign my post on other topics…ive been so busy, i WILL get round to answerign you!

http://www.zaidcrowe.co.uk/fyp/siteadmin/audio/gettracks.php

Im tryign to get this script to allow a user to set the playlist from a dB. Each track has a track number in the database. By pressing up they mvoe the track up in the play list and down down. Effectivly all this means is ‘swapping’ track numbers with either the track above or below:


<?
if (isset($_POST['up'])){
$tracknum = $_POST['tracknum'];
$base = $tracknum;
$prevTracknum = $base -=1;

include ("dbconnect.php");
$selectprev = "UPDATE tracks SET tracknum='$tracknum' WHERE tracknum='$prevTracknum'";
$runprev = mysql_query($selectprev);
$conn->close;


include ("dbconnect.php");
$selectcur = "UPDATE tracks SET tracknum='$prevTracknum' WHERE tracknum='$tracknum'";
$run = mysql_query($selectcur);
$conn->close;

 


}
?>



Ive tried all sorts of incarnations of the script so this could be well out im aware (the connect include has been altered and doesnt show the actual path to my db connect script).

Im sure this is such a simpel problem i just cannot get it working! All help muchly appreciated!