Hey there,
I hope this is the right forum (after reading the "where to" I think this is right)..
Anyway, I am running a video website using a script. This script includes modules, which are basically PHP to show the video list and such.
Basically my videos are taken from the database and displayed by the date added. Using this code.. (I have ommitted some code from above hope this doesnt confuse people)..
What I want is my user to press a text link at the top of the page to order the videos in another way. Like below for example ..PHP Code:$db->query("SELECT * FROM `videos` WHERE `kategorie` = '" . $catid . "' " . $plist . " AND `status` = 'true' ORDER BY `kategorie`, `[B]added[/B]` DESC");
$count = $db->numRows();
$resV = $db->fetchAll();
if(isset($_GET['page']))
$output = displayVideos($resV,$_GET['page'],$thisurl);
else
$output = displayVideos($resV,1,$thisurl);
echo $output;
The problem I am having when trying to learn PHP is how to get the link to reload the page and replace that word with another, or switch to the second code?PHP Code:$db->query("SELECT * FROM `videos` WHERE `kategorie` = '" . $catid . "' " . $plist . " AND `status` = 'true' ORDER BY `kategorie`, `[B]visits[/B]` DESC");
$count = $db->numRows();
$resV = $db->fetchAll();
if(isset($_GET['page']))
$output = displayVideos($resV,$_GET['page'],$thisurl);
else
$output = displayVideos($resV,1,$thisurl);
echo $output;
Ive tried everything to my knowledge which is very limited.
Any help would be great
Dean





Bookmarks