Help Needed Please

Started on the old forum in September 2007 · view the original in the archive · old links redirect here

5 replies · 665 views · started 19 years ago · 1 min read

2 participants
SpiderWap Lead · 622 posts #1

This is the page for my downloads right...

Nothing rong with it, it works fine... CODE ///////////////////////////////////Quintin's Downloads else if($action=="quintin_downloads") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// echo "<a href="downloads/pictures/index.php?action=main&sid=$sid">»Pictures</a> "; echo "<a href="downloads/anamations/index.php?action=main&sid=$sid">»Anamations</a> "; echo "<a href="downloads/mp3s/index.php?action=main&sid=$sid">»Mp3's</a> "; echo "<a href="downloads/afrikaanse_mp3s/index.php?action=main&sid=$sid">»Afrikaanse mp3's</a> "; echo "<a href="downloads/poly_ringtones/index.php?action=main&sid=$sid">»Poly ringtones</a> "; echo "<a href="downloads/afrikaanse_polys/index.php?action=main&sid=$sid">»Afrikaanse polys</a> "; echo "<a href="downloads/java_games/index.php?action=main&sid=$sid">»Java games</a> "; echo "<a href="downloads/my_pimped_mxits_(v3)/index.php?action=main&sid=$sid">»My pimped mxits</a> "; echo "<a href="downloads/afrikaanse_mxits/index.php?action=main&sid=$sid">»Afrikaanse mxits</a> "; echo "<a href="downloads/3gp_clips/index.php?action=main&sid=$sid">»3gp clips</a> "; echo "<a href="downloads/3gp_music_videos/index.php?action=main&sid=$sid">»3gp music videos</a> "; echo "<a href="downloads/afrikaanse_music_videos/index.php?action=main&sid=$sid">»Afrikaanse music videos</a> "; echo "<a href="downloads/funny_tones/index.php?action=main&sid=$sid">»Funny tones</a> "; ///////////////////////////////////////////////////// echo " ";

echo "

";

echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";

echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

But now, how do i get this page to work right with my script

CODE

<? header("Content-type: text/vnd.wap.wml"); echo "<?xml version=\"1.0\"?>";

echo "<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.1//EN\""." \"http://www.wapforum.org/DTD/wml_1.1.xml\">";

include("../wapbuddy_settings.php"); if (!isset($page)) {$page = 0;} $total = 0;

if(!($dp = opendir("./"))) die ("Cannot open ./"); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array); ?> <wml> <card id="card1" title="<? echo $conf["site_name"] ?>">

	<do type="option" label="Home"><go href="../index.php"/></do>
	<? echo "<a href=\"../index.php\">Home</a>

"; ?> <?

	if ($file_count > 0)
		{
		$first_record = $page * $conf["items_per_page"];
		$last_record = $first_record + $conf["items_per_page"];
		
		while (list($fileIndexValue, $file_name) = each ($file_array))
			{
			
			if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record))
				{
		
				echo "<a href=\"$file_name\">$file_name</a> (". round(filesize($file_name)/1024,1) . "kb)

"; $total = $total + filesize($file_name); } }

		if (($file_count > 0) AND ($page != 0))
			{
			// previous button
			$prev_page = $page -1;
			echo "

<a href="".$_SERVER["PHP_SELF"]."?page=$prev_page">Prev</a> "; }

		if (($file_count > 0) AND ($last_record < $file_count))
			{
			// next button
			$next_page = $page + 1;
			echo "

<a href="".$_SERVER["PHP_SELF"]."?page=$next_page">Next</a> "; } echo " Directory: $file_count "; if ($file_count == 1) {echo "file";} else {echo "files";}

		echo " (" . round($total/1024,1) . "kb)";
		echo "

<a href="../index.php">Home</a>"; } closedir($dp); ?>

</card> </wml>

Please, someone please help me, just want this page to work right with the script

GumSlone Administrator Principal · 1,690 posts #2

I hope this works, i have'nt tested it....

///////////////////////////////////Quintin's Downloads
else if($action=="files_downloads")
{
    addonline(getuid_sid($sid),"At Quintin's Downloads","");
    include ("wapbuddy_settings.php");
    echo "<card id=\"main\" title=\"Quintin's Downloads\">";
    echo "<p align=\"center\">";
    echo "<img src=\"images/quintin.gif\" alt=\"Downloads\"/>
";
    echo "[b]Quintin's Downloads[/b]";
    echo "</p>";
    echo "

[size="1"]";
////////////////////////////////////////////////////////////////////
$conf["items_per_page"] = 10;   //NUMBER OF ITEMS PER PAGE
$conf["directory_for_reading"] = './images';   //Directory you want to open
if (!isset($page)) {$page = 0;}
$total = 0;
if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] ."");
$file_array = array(); 
while ($file = readdir ($dp))
    {
    if(substr($file,0,1) != '.' and $file != "index.php")
        {
        $file_array[] =  $file;
        }
    }
$file_count = count ($file_array);
sort ($file_array);

        if ($file_count > 0)
            {
            $first_record = $page * $conf["items_per_page"];
            $last_record = $first_record + $conf["items_per_page"];
            
            while (list($fileIndexValue, $file_name) = each ($file_array))
                {
                
                if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record))
                    {
            
                    echo "<a href=\"$file_name\">$file_name</a> (". round(filesize($file_name)/1024,1) . "kb)
";
                    $total = $total + filesize($file_name);
                    }
                }
            
            if (($file_count > 0) AND ($page != 0))
                {
                // previous button
                $prev_page = $page -1;
                echo "
<a href=\"".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action\">Prev</a>
";
                }
            
            
            if (($file_count > 0) AND ($last_record < $file_count))
                {
                // next button
                $next_page = $page + 1;
                echo "
<a href=\"".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action\">Next</a>
";
                }
            echo "
Directory:
$file_count ";
            if ($file_count == 1)
                {echo "file";}
            else
                {echo "files";}
                
            echo " (" . round($total/1024,1) . "kb)";
            
            }
        closedir($dp);
/////////////////////////////////////////////////////
  echo "[/size]</p>";
    
    echo "<p align=\"center\">";
    
    echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
echo "Home</a>";
  echo "</p>";
    echo "</card>";
}

///////////////////////////////////

Advertise your mobile site for FREE with AdTwirl

External image (may be gone)

GumSlone Administrator Principal · 1,690 posts #4

Thank you m8, your code works, but im having one problem, it's kicking me out when selecting next page, if someone could maybe have a look at that? plz?

HI, i have edited the code, it should be ok now, try it again....

Advertise your mobile site for FREE with AdTwirl

External image (may be gone)

SpiderWap Lead · 622 posts #6

[codebox] ///////////////////////////////////Quintin's Downloads else if($action=="quintin_downloads") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// echo "<a href="index.php?action=pictures_downloads&sid=$sid">»Pictures</a> "; echo "<a href="index.php?action=anamations_downloads&sid=$sid">»Anamations</a> "; echo "<a href="index.php?action=mp3s_downloads&sid=$sid">»Mp3's</a> "; echo "<a href="index.php?action=afrikaanse_mp3s_downloads&sid=$sid">»Afrikaanse mp3's</a> "; echo "<a href="index.php?action=poly_downloads&sid=$sid">»Poly ringtones</a> "; echo "<a href="index.php?action=afrikaanse_polys&sid=$sid">»Afrikaanse polys</a> "; echo "<a href="index.php?action=java_games&sid=$sid">»Java games</a> "; echo "<a href="index.php?action=my_pimped_mxits&sid=$sid">»My pimped mxits</a> "; echo "<a href="index.php?action=afrikaanse_mxits&sid=$sid">»Afrikaanse mxits</a> "; echo "<a href="index.php?action=3gp_clips&sid=$sid">»3gp clips</a> "; echo "<a href="index.php?action=3gp_music_videos&sid=$sid">»3gp music videos</a> "; echo "<a href="index.php?action=afrikaanse_music_videos&sid=$sid">»Afrikaanse music videos</a> "; echo "<a href="index.php?action=funny_tones&sid=$sid">»Funny tones</a> "; ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////Afrikaanse Music Videos else if($action=="funny_tones") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/funny_tones'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <a href="../downloads/funny_tones/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

//////////////////////////////////Afrikaanse Music Videos else if($action=="afrikaanse_music_videos") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/afrikaanse_music_videos'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <a href="../downloads/afrikaanse_music_videos/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

//////////////////////////////////3gp Music Videos else if($action=="3gp_music_videos") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/3gp_music_videos'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <a href="../downloads/3gp_music_videos/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

//////////////////////////////////3gp Clips else if($action=="3gp_clips") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/3gp_clips'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <a href="../downloads/3gp_clips/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1;

echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

//////////////////////////////////Afrikaanse Mxits else if($action=="afrikaanse_mxits") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/afrikaanse_mxits'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <a href="../downloads/afrikaanse_mxits/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

//////////////////////////////////My Pimped Mxits else if($action=="my_pimped_mxits") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/my_pimped_mxits_(v3)'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <a href="../downloads/my_pimped_mxits_(v3)/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

//////////////////////////////////Java Games else if($action=="java_games") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/java_games'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <a href="../downloads/java_games/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

//////////////////////////////////Afrikaanse Polys else if($action=="afrikaanse_polys") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/afrikaanse_polys'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <a href="../downloads/afrikaanse_polys/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

//////////////////////////////////Poly Downloads else if($action=="poly_downloads") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/poly_downloads'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <a href="../downloads/poly_downloads/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

//////////////////////////////////Afrikaanse Mp3's else if($action=="afrikaanse_mp3s_downloads") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/afrikaanse_mp3_downloads'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <a href="../downloads/afrikaanse_mp3_downloads/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

//////////////////////////////////Anamations else if($action=="anamations_downloads") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/anamations'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <img src="../downloads/anamations/$file_name" alt="*"/>"; echo " <a href="../downloads/anamations/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

/////////////////////////////////// //////////////////////////////////Mp3's else if($action=="mp3s_downloads") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/mp3s'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <a href="../downloads/mp3s/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

//////////////////////////////////Pictures else if($action=="pictures_downloads") { addonline(getuid_sid($sid),"At Quintin's Downloads",""); include ("wapbuddy_settings.php"); echo "<card id="main" title="Quintin's Downloads">"; echo " "; echo "<img src="images/quintin.gif" alt="Downloads"/> "; echo "Quintin's Downloads"; echo " "; echo "

"; //////////////////////////////////////////////////////////////////// $conf["items_per_page"] = 10; //NUMBER OF ITEMS PER PAGE $conf["directory_for_reading"] = '../downloads/pictures'; //Directory you want to open if (!isset($page)) {$page = 0;} $total = 0; if(!($dp = opendir($conf["directory_for_reading"] ))) die ("Cannot open ".$conf["directory_for_reading"] .""); $file_array = array(); while ($file = readdir ($dp)) { if(substr($file,0,1) != '.' and $file != "index.php") { $file_array[] = $file; } } $file_count = count ($file_array); sort ($file_array);

if ($file_count > 0) { $first_record = $page * $conf["items_per_page"]; $last_record = $first_record + $conf["items_per_page"];

while (list($fileIndexValue, $file_name) = each ($file_array)) {

if (($fileIndexValue >= $first_record) AND ($fileIndexValue < $last_record)) { echo " <img src="../downloads/pictures/$file_name" alt="*"/>"; echo " <a href="../downloads/pictures/$file_name">$file_name</a> "; $total = $total + filesize($file_name); } }

if (($file_count > 0) AND ($page != 0)) { // previous button $prev_page = $page -1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$prev_page&sid=$sid&action=$action">Prev</a> "; }

if (($file_count > 0) AND ($last_record < $file_count)) { // next button $next_page = $page + 1; echo " <a href="".$_SERVER["PHP_SELF"]."?page=$next_page&sid=$sid&action=$action">Next</a> "; } } closedir($dp); ///////////////////////////////////////////////////// echo " ";

echo " ";

echo "<a href="index.php?action=quintin_downloads&sid=$sid">"; echo "Back</a> ";

echo "<a href="index.php?action=main&sid=$sid"><img src="images/home.gif" alt="*"/>"; echo "Home</a>"; echo " "; echo "</card>"; }

///////////////////////////////////

[/codebox]

Done!!! Thank you!!! Now just have to convert it to xhtml

Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close