-download category-

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #31
    i got this uploader right with device uploader but when i try to download the file it dont wona it dnt do anything when i click on the file

    Comment


      #32
      downloads.php
      Code:
      <?php
      include("config.php");
      include("core.php");
      
      
      header("Content-type: text/html; charset=ISO-8859-1");
      echo "<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?>";
      echo "<!DOCTYPE html PUBLIC \"-//WAPFORUM//DTD XHTML Mobile 1.0//EN\"\"http://www.wapforum.org/DTD/xhtml-mobile10.dtd\">";
      echo "<html xmlns=\"http://www.w3.org/1999/xhtml\">";
      
      	echo "<head>";
      
      	echo "<title>pinoyaztig.net</title>";
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style/style.css\" />";
      	echo "</head>";
      
      	echo "<body>";
      connectdb();
      
      
      $action = $_GET["action"];
      $sid = $_GET["sid"];
      $page = $_GET["page"];
      $did = $_GET["did"];
      if($action != "")
      {
          if(islogged($sid)==false)
          {
            echo "<card id=\"main\" title=\"pinoyaztig.net\">";
            echo "<p align=\"center\">";
            echo "You are not logged in<br/>";
            echo "Or<br/>Your session has been expired<br/><br/>";
            echo "<a href=\"index.php\">Login</a>";
            echo "</p>";
            echo "</card>";
            echo "</wml>";
            exit();
          }
      }
      if(isbanned($uid))
          {
              echo "<card id=\"main\" title=\"pinoyaztig.net\">";
            echo "<p align=\"center\">";
            echo "<img src=\"http://coding-talk.com/images/notok.gif\" alt=\"x\"/><br/>";
            echo "You are <b>Banned</b><br/>";
            $banto = mysql_fetch_array(mysql_query("SELECT timeto FROM ibwf_penalties WHERE uid='".$uid."' AND penalty='1'"));
            $remain = $banto[0]- time();
            $rmsg = gettimemsg($remain);
            echo "Time to finish your penalty: $rmsg<br/><br/>";
            //echo "<a href=\"index.php\">Login</a>";
            echo "</p>";
            echo "</card>";
            echo "</wml>";
            exit();
          }
      
      //////////////////////////////////Buddies
      
      else if($action=="symbian")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"Symbian Application","");
          echo "<card id=\"main\" title=\"Symbian Application\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="1")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='1'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
            $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }
      
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=themes&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="java")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"Java Application","");
          echo "<card id=\"main\" title=\"Java Application\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="2")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='2'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
            $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }
      
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=themes&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="antivirus")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"Anti Vitus","");
          echo "<card id=\"main\" title=\"Anti Virus\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="3")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='3'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
            $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }
      
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=themes&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="themes")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"s40v2/s40v3 Themes","");
          echo "<card id=\"main\" title=\"s40v2/s40v3 Themes\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="4")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='4'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
            $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }
      
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=themes&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="themes1")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"s60/s60v3/Nseries-Themes","");
          echo "<card id=\"main\" title=\"s60/s60v3/Nseries-Themes\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="5")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='5'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
            $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }
      
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=themes&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="sethemes")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"SE Themes","");
          echo "<card id=\"main\" title=\"SE Themes\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="6")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='6'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
          if($who="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
      $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY did DESC LIMIT $limit_start, $items_per_page";
              }
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=apps&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="games1")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"s30/s40/s40v2 Games","");
          echo "<card id=\"main\" title=\"s30/s40/s40v2 Games\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="7")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='7'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
      $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY did DESC LIMIT $limit_start, $items_per_page";
              }
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=games1&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="games2")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"s60/s60v3 Games","");
          echo "<card id=\"main\" title=\"s60/s60v3 Games\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="8")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='8'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
      $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY did DESC LIMIT $limit_start, $items_per_page";
              }
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=games2&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="games3")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"Eseries/Ngage/Nseries Games","");
          echo "<card id=\"main\" title=\"s60/Ngage/Nseries Games\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="9")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='9'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
      $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY did DESC LIMIT $limit_start, $items_per_page";
              }
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=videos&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="segames")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"SE Games","");
          echo "<card id=\"main\" title=\"SE Games\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="10")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='10'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
      $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY did DESC LIMIT $limit_start, $items_per_page";
              }
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=audio&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="mp3")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"Full MP3","");
          echo "<card id=\"main\" title=\"Full MP3\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="11")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='11'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
      $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY did DESC LIMIT $limit_start, $items_per_page";
              }
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=wall&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="3gp")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"3GP Videos","");
          echo "<card id=\"main\" title=\"3GP Videos\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="12")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='12'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
      $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=others&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="scandal")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"Scandal","");
          echo "<card id=\"main\" title=\"Scandal\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="13")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='13'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
      $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY did DESC LIMIT $limit_start, $items_per_page";
              }
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=wall&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="gameboy")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"Gameboy Games","");
          echo "<card id=\"main\" title=\"Gameboy Games\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="14")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='14'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
      $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY did DESC LIMIT $limit_start, $items_per_page";
              }
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=wall&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="naruto")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"Naruto-Themes/Poly/MP3 ","");
          echo "<card id=\"main\" title=\"Naruto-Themes/Poly/MP3 \">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="15")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='15'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
      $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY did DESC LIMIT $limit_start, $items_per_page";
              }
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=wall&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      //////////////////////////////////Buddies
      
      else if($action=="poly")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"MP3/MIDI/WAV/POLY/AMR/RAR ($noi[0])","");
          echo "<card id=\"main\" title=\"MP3/MIDI/WAV/POLY/AMR/RAR ($noi[0])\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="16")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='16'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
      $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY did DESC LIMIT $limit_start, $items_per_page";
              }
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=wall&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      
      //////////////////////////////////Buddies
      
      else if($action=="logo")
      {
          $who = $_GET["who"];
          addonline(getuid_sid($sid),"Opera Software","");
          echo "<card id=\"main\" title=\"Opera Software\">";
          $uid = getuid_sid($sid);
      
      
      
          //////ALL LISTS SCRIPT <<
      
          if($page=="" || $page<=0)$page=1;
          if($did="17")
          {
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='17'"));
          }else{
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE uid='".$who."'"));
          }
          $num_items = $noi[0]; //changable
          $items_per_page= 10;
          $num_pages = ceil($num_items/$items_per_page);
          if(($page>$num_pages)&&$page!=1)$page= $num_pages;
          $limit_start = ($page-1)*$items_per_page;
      
          if($who!="")
          {
              $sql = "SELECT id, title, itemurl, did FROM ibwf_vault WHERE uid='".$who."' ORDER BY pudt DESC LIMIT $limit_start, $items_per_page";
              }else{
      $sql = "SELECT id, title, itemurl, uid, did FROM ibwf_vault WHERE did='".$did."' ORDER BY did DESC LIMIT $limit_start, $items_per_page";
              }
      
      
          echo "<p>";
          $items = mysql_query($sql);
          echo mysql_error();
          if(mysql_num_rows($items)>0)
          {
          while ($item = mysql_fetch_array($items))
          {
            $ext = getext($item[2]);
              $ime = getextimg($ext);
              $lnk = "<a href=\"downloads.php?action=download&amp;sid=$sid&amp;did=$item[0]\">$ime".htmlspecialchars($item[2])."</a>";
      
            if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">[x]</a>";
            }else{
              $delnk = "";
            }
            if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
              $byusr = "<br/>By: $ulnk";
            }
            echo "$lnk $byusr $delnk<br/>";
      
      
          }
          }
          echo "</p>";
          echo "<p align=\"center\">";
          if($page>1)
          {
            $ppage = $page-1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$ppage&amp;sid=$sid&amp;who=$who\">«PREV</a> ";
          }
          if($page<$num_pages)
          {
            $npage = $page+1;
            echo "<a href=\"downloads.php?action=$action&amp;page=$npage&amp;sid=$sid&amp;who=$who\">Next»</a>";
          }
          echo "<br/>$page/$num_pages<br/>";
          if($num_pages>2)
          {
            $rets = "Jump to page: <input name=\"pg\" format=\"*N\" size=\"3\"/>";
              $rets .= "<anchor>[GO]";
              $rets .= "<go href=\"downloads.php?type=send\" method=\"get\">";
              $rets .= "<postfield name=\"action\" value=\"$action\"/>";
              $rets .= "<postfield name=\"who\" value=\"$who\"/>";
              $rets .= "<postfield name=\"sid\" value=\"$sid\"/>";
              $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
              $rets .= "</go></anchor>";
      
              echo $rets;
          }
          echo "</p>";
        ////// UNTILL HERE >>
          echo "<p align=\"center\">";
          if($uid==$who && getplusses($uid)>25)
          {
          echo "<a href=\"up.php?action=wall&amp;sid=$sid\">";
      echo "Add Item</a><br/>";
      }
      if($who!="")
      {
      echo "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$who\">";
      $whonick = getnick_uid($who);
      echo "$whonick's Profile</a><br/>";
      }else{
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
      }
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
        echo "</p>";
          echo "</card>";
      }
      
      
      
      
      
      
      
      
      
      
      //////////////////////////////////Buddies
      
      else if($action=="download")
      {
          $did = $_GET["did"];
       $uid = getuid_sid($sid);
          addonline(getuid_sid($sid),"Downloading..","");
          echo "<card id=\"main\" title=\"Downloading...\">";
      echo "<p align=\"left\">";
          $uid = getuid_sid($sid);
      $item = mysql_fetch_array(mysql_query("SELECT id, title, itemurl, uid, did, downloads, pudt, filesize, mime, info FROM ibwf_vault WHERE id='".$did."'"));
      
             $name = "Name: $item[1]";
      $desc= "Description: $item[9]";
       $downloads = "Download Times: $item[5]";
              $filesize = "File Size: $item[7]";
       $mime = "File Type: $item[8]";
      $tmstamp = $item[6];
        $tmdt = date("d m Y - H:i:s", $tmstamp);
      $earns2 = "Download Cost: 5 plusses";
      
      
              $dateadded1 = "Date Added: $dateadded";
      
          if($who!="")
            {
              $byusr="";
            }else{
              $unick = getnick_uid($item[3]);
              $ulnk = "<a href=\"index.php?action=viewuser&amp;sid=$sid&amp;who=$item[3]\">$unick</a>";
      
            }
             echo "$name<br/>$desc<br/>$filesize<br/>$mime<br/>Date Uploaded: $tmdt<br/>$earns2<br/>$downloads<br/>Uploaded by by: $ulnk<br/>";
            echo "----<br/><a href=\"getnow.php?sid=$sid&amp;did=$item[0]\">Download now!</a><br/>";
      
        if(candelvl($uid, $item[0]))
            {
              $delnk = "<a href=\"genproc.php?action=delvlt&amp;sid=$sid&amp;did=$item[0]\">Delete</a><br/>";
            }else{
              $delnk = "";
            }
      echo "$delnk";
      echo "<a href=\"index.php?action=vault&amp;sid=$sid\">";
      echo "Downloads</a><br/>";
          echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
      
        echo "</p>";
          echo "</card>";
      }
      ?>
      
      </HTML>
      getnow.php
      Code:
      <?php
      include("core.php");
      include("config.php");
      connectdb();
      $sid = $_GET["sid"];
      $did = $_GET["did"];
      $agent = $_SERVER['HTTP_USER_AGENT'];
      $uid = getuid_sid($sid);
      if (eregi("mozilla", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("anonymouse.org", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("winwap", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("gecko", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("omniweb", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("msie", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("konqueror", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("safari", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("netpositive", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("lynx", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("elinks", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("links", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("w3m", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("webtv", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("amaya", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("ibrowse", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("icab", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("crazy browser", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      if (eregi("internet browser", $agent))
       {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error Browser</title>";
            echo "<p align=\"center\">";
            echo "Your browser is not a mobile phone<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
      }
      $uid = getuid_sid($sid);
       if(islogged($sid)==false)
          {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      	echo "<body>";
            echo "<title>Session error</title>";
            echo "<p align=\"center\">";
            echo "You are not logged in<br/>";
            echo "Or<br/>Your session has been expired<br/><br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
          }
      $tid = getfile($did);
        if($tid==0)
          {
      echo "<head>";
      
      	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      	echo "<body>";
            echo "<title>Error File</title>";
            echo "<p align=\"center\">";
            echo "File has been deleted or not in our database.<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
          }
      $res = mysql_fetch_array(mysql_query("SELECT itemurl, title, id, mime FROM ibwf_vault WHERE id='".$did."'"));
      if (file_exists("./pkfiles/".$res[0])) {
      	$fh = fopen ("./pkfiles/".$res[0],r);
      	$thisline= explode('|', fgets($fh));
      		$validdownload=$thisline;
      	fclose($fh);
      }
      if($validdownload==0) 
      {
      echo "<head>";	
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style.css\" />";
      	echo "</head>";
      
      
      	echo "<body>";
            echo "<title>Error file</title>";
            echo "<p align=\"center\">";
            echo "File has been deleted or not in our database.<br/>";
            echo "<a href=\"index.php\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
          }
      mysql_query("UPDATE ibwf_vault SET downloads=downloads+'1' WHERE id='".$did."'");
      $res = mysql_fetch_array(mysql_query("SELECT itemurl, title, id, mime, uid FROM ibwf_vault WHERE id='".$did."'"));
      $res2 = $res[0];
      mysql_query("UPDATE ibwf_users SET plusses=plusses+'5' WHERE id='".$res[4]."'");
      mysql_query("UPDATE ibwf_users SET plusses=plusses-'5' WHERE id='".$uid."'");
      header("Location: http://wap.net.ph/pkfiles/$res2");
      ?>
      genproc.php
      Code:
      else if($action=="addvlt")
      {
      
      if(!getplusses(getuid_sid($sid))>25)
          {
            echo "<title>pinoykindat.net</title>";
            echo "<p align=\"center\">";
            echo "Only the user of 25+ plusses can add a vault item<br/><br/>";
            echo "<a href=\"index.php?action=main&amp;sid=$sid\">Home</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
          }
        $viname = $_POST["viname"];
        $vilink = $_POST["vilink"];
      $videsc = $_POST["videsc"];
        $did = $_POST["did"];
       //$qut = $_POST["qut"];
      
       $fname= array_reverse(explode("/",$vilink));
        addonline(getuid_sid($sid),"Adding A Vault Item","index.php?action=main");
      
      error_reporting(0);
       if(strlen($viname)<5)
      {
            echo "<title>pinoykindat.net</title>";
            echo "<p align=\"center\">";
              echo "5 minimum letters for the title!";
        echo "<br/><a href=\"index.php?action=main&amp;sid=$sid\">";
        echo "Main menu</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
          }
       if(strlen($vilink)<5)
      {
            echo "<title>pinoykindat.net</title>";
            echo "<p align=\"center\">";
              echo "5 minimum letters for the link!";
        echo "<br/><a href=\"index.php?action=main&amp;sid=$sid\">";
        echo "Main menu</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
          }
       if(strlen($videsc)<5)
      {
            echo "<title>pinoykindat.net</title>";
            echo "<p align=\"center\">";
              echo "5 minimum letters for the description!";
        echo "<br/><a href=\"index.php?action=main&amp;sid=$sid\">";
        echo "Main menu</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
          }
      if(spacesin($vilink))
      {
            echo "<card id=\"main\" title=\"Error adding\">";
            echo "<p align=\"center\">";
            echo "No space input!<br/>";
            echo "<a href=\"index.php?action=main&amp;sid=$sid\">Main menu</a>";
            echo "</p>";
            echo "</body>";
            echo "</html>";
            exit();
          }
      $fname= array_reverse(explode("/",$vilink));
      
      if (!eregi("\.(mid|gif|bmp|mid|midi|3gp|mp3|mp4|wav|mpn|nth|mpc|jar|jad|jpeg|jpg|sis|mmf|amr|thm|png|wbmp|rar|zip)$",$fname[0]))
      {
      echo "<card id=\"main\" title=\"Error adding\">";
            echo "<p align=\"center\">";
      echo "<b>Unsuported File extention!</b><br/>";
      echo "<a href=\"index.php?action=main&amp;sid=$sid\">Main menu</a>";
                        echo "</p></card></wml>";
      			exit();
      			}
      echo "<title>pinoykindat.net</title>";
            echo "<p align=\"center\">";
            $crdate = time();
            //$uid = getuid_sid($sid);
      
         $res = false;
      
      $defaultDest = "$dir";
      $slash       = "/";
      
      $dest        = "./pkfiles/";
       $fname= array_reverse(explode("/",$vilink));
      $ds = array($dest, $slash, $fname[0]);
      		$ds = implode("", $ds);
        if (!copy($vilink, $ds))
      {
       echo "Dead link is not allowed!(<br/>"; 
      }else{       
        $fname= array_reverse(explode("/",$vilink));
      $ext = getext($fname[0]);
              $mime = getextfile($ext);
      $fname= array_reverse(explode("/",$vilink));
         $filesize = filesize($ds);
      $filesize = $filesize / 1048576;
      $fsize = 0;
      $fsizetxt = "";
        if ($filesize < 1)
        {
           $fsize = round($filesize*1024,0);
           $fsizetxt = "".$fsize."KB";
          $check1 = "KB";
        }else{
           $fsize = round($filesize,2);
           $fsizetxt = "".$fsize." MB";
      $check1 = "MB";
        }
        $res = mysql_query("INSERT INTO ibwf_vault SET uid='".$uid."', title='".mysql_escape_string($viname)."', pudt='".$crdate."', did='".$did."', info='".$videsc."',filesize='".$fsizetxt."', mime='".$mime."', itemurl='".$fname[0]."'");
       if($res)
            {
      mysql_query("UPDATE ibwf_users SET plusses=plusses-'5' WHERE id='".$uid."'");
       echo "File added successfully!";
            }else{
              
            }
      }
            echo "<br/><br/>";
            echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
      echo "Main menu</a>";
            echo "</p>";
            echo "</body>";
      
      }
      else if($action=="delvlt")
      {
          $vid = $_GET["vid"];
        addonline(getuid_sid($sid),"Deleting Vault Item","");
        echo "<p align=\"center\">";
        $itemowner = mysql_fetch_array(mysql_query("SELECT uid FROM ibwf_vault WHERE id='".$vid."'"));
        if(ismod(getuid_sid($sid))||getuid_sid($sid)==$itemowner[0])
        {
          $res = mysql_query("DELETE FROM ibwf_vault WHERE id='".$vid."'");
          if($res)
              {
                  echo "<img src=\"../images/ok.gif\" alt=\"o\"/>Item Deleted From Vault<br/>";
              }else{
                echo "<img src=\"../images/notok.gif\" alt=\"x\"/>Database Error!<br/>";
              }
        }else{
          echo "<img src=\"../images/notok.gif\" alt=\"X\"/>You can't delete this item";
        }
        echo "<br/><br/>";
        echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../images/home.gif\" alt=\"*\"/>";
      echo "Home</a>";
        echo "</p></body>";
      }
      usage main page
      Code:
      $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault"));
          echo "<a href=\"index.php?action=vault&amp;sid=$sid\">Downloads($noi[0])</a><br/>";
      index.php
      Code:
      //////////////////////////////////vaultren
      
      else if($action=="vault")
      {
          addonline(getuid_sid($sid),"Downloads!","index.php?action=$action");
        
          echo "<p align=\"left\">";
          echo "Select Category:<br/>";
       $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='1'"));
          echo "<a href=\"downloads.php?action=symbian&amp;sid=$sid\">Symbian Software($noi[0])</a><br/>";
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='2'"));
          echo "<a href=\"downloads.php?action=java&amp;sid=$sid\">Java Software($noi[0])</a><br/>";
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='3'"));
          echo "<a href=\"downloads.php?action=anti&amp;sid=$sid\">Anti Virus($noi[0])</a><br/>";
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='4'"));
          echo "<a href=\"downloads.php?action=themes&amp;sid=$sid\">s40v2/s40v3-Themes ($noi[0])</a><br/>";
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='5'"));
          echo "<a href=\"downloads.php?action=themes1&amp;sid=$sid\">s60/s60v3/Nseries-Themes ($noi[0])</a><br/>";
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='6'"));
          echo "<a href=\"downloads.php?action=sethemes&amp;sid=$sid\">Sony Ericsson-Themes ($noi[0])</a><br/>";
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='7'"));
          echo "<a href=\"downloads.php?action=games1&amp;sid=$sid\"> s30/s40/s40v2-Games($noi[0])</a><br/>";
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='8'"));
          echo "<a href=\"downloads.php?action=games2&amp;sid=$sid\">s60/s60v3-Games($noi[0])</a><br/>";
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='9'"));
          echo "<a href=\"downloads.php?action=games3&amp;sid=$sid\">Nseries/Eseries/Ngage-Games($noi[0])</a><br/>";
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='10'"));
          echo "<a href=\"downloads.php?action=segames&amp;sid=$sid\">Sony Ericsson-Games($noi[0])</a><br/>";
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='11'"));
          echo "<a href=\"downloads.php?action=mp3&amp;sid=$sid\">Full MP3 ($noi[0])</a><br/>";
           $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='12'"));
          echo "<a href=\"downloads.php?action=3gp&amp;sid=$sid\">3GP Videos ($noi[0])</a><br/>";
          $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='13'"));
          echo "<a href=\"downloads.php?action=scandal&amp;sid=$sid\">Scandal ($noi[0])</a><br/>";
       
         $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='14'"));
          echo "<a href=\"downloads.php?action=gameboy&amp;sid=$sid\">Gameboy-Games ($noi[0])</a><br/>";
         
       $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='15'"));
          echo "<a href=\"downloads.php?action=naruto&amp;sid=$sid\">Naruto-Themes/Poly/MP3 ($noi[0])</a><br/>";
          
      $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='16'"));
          echo "<a href=\"downloads.php?action=poly&amp;sid=$sid\">MP3/MIDI/WAV/POLY/AMR/RAR ($noi[0])</a><br/>";
            
      $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE did='17'"));
          echo "<a href=\"downloads.php?action=logo&amp;sid=$sid\">Opera Software ($noi[0])</a>";
      
          echo "</p>";
          echo "<p align=\"center\">";
          echo "<a href=\"http://wap.net.ph/upload.php?sid=$sid&amp;ver=html\">Upload via Phone/PC</a><br/>";
           echo "<a href=\"index.php?action=addvlt&amp;sid=$sid\">";
          echo "Add vault via URL</a><br/>";
           echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
          echo "Main menu</a>";
          
          echo "</p>";
          echo "</body>";
      }
      upload.php
      Code:
      <?php
      
      
      include("core.php");
      include("config.php");
      
      
      header("Content-type: text/html; charset=ISO-8859-1");
      echo "<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?>";
      echo "<!DOCTYPE html PUBLIC \"-//WAPFORUM//DTD XHTML Mobile 1.0//EN\"\"http://www.wapforum.org/DTD/xhtml-mobile10.dtd\">";
      echo "<html xmlns=\"http://www.w3.org/1999/xhtml\">";
      
      	echo "<head>";
      
      	echo "<link rel=\"StyleSheet\" type=\"text/css\" href=\"style/style.css\" />";
      	echo "</head>";
      
      	echo "<body>";
      
      connectdb();
      $did = $_POST["did"];
      
      $sid = $_GET["sid"];
      $ver = $_GET["ver"];
      $did = $_POST["did"];
      $file = $_POST["file"];
      $uid = getuid_sid($sid);
      if((islogged($sid)==false)||($uid==0))
          {
              
            echo "<p align=\"center\">";
            echo "You are not logged in<br/>";
            echo "Or Your session has been expired<br/><br/>";
            echo "<a href=\"index.php\">Login</a>";
            echo "</p>";
            exit();
          }
      echo "<p align=\"left\">";
      echo "<title>PINOY AZTIG SA UPLOADER</title>";
      
      // Upload Directory [ No trailing slash.. ]. CHMOD it to 777. 
      $uploaddir = ".";
      
      // No. of File Upload fields.
      $fields = 5;
      
      // File accept filter: Set 1 for ON, 0 for OFF.
      $acceptfilter = 0;
      // Acceptable File Types [ If Filter is set.. ]:
      $acceptabletypes = array("image/jpeg", "image/pjpeg", "image/JPEG", "image/JPG","image/jpg","image/PJPEG","image/GIF","image/gif");
      
      // File size limit: Set 1 for ON, 0 for OFF.
      $limitsize = 1;
      // Maximum File size [ In KB.. ]:
      $maxsize = 5555;
      
      // Over-Writing: Set 1 to ALLOW, 0 to DISALLOW.
      $overwriting = 0;
      
      // Time Offset [ If required ( in hours ).. ]:
      $timeoffset = +0;
      
      include("uploader.php");
      
      echo "</body>";
      	echo "</html>\n";
      ?>
      uploader.php
      Code:
      <?
      
      function get_files($dirstr)
        {
         $scanfiles = array();
         $fh = opendir($dirstr);
         while (false !== ($filename = readdir($fh)))
         {
      if (is_file("$dirstr/$filename")) {
           array_push($scanfiles, $filename); }
         }
         closedir($fh);
         sort($scanfiles);
         return $scanfiles;
      }
      
      
      $count = count($_FILES['userfile']['name']);
      if ($count > 0) {
      
      $i=0;
      $f=0;
      while ($i < $count) {
      
      $kbsize = (round($_FILES['userfile']['size'][$i]/5000));
      $date = date("j M Y g:ia", time()+($timeoffset*3600));
      $userip = $_SERVER['REMOTE_ADDR'];
      
      if ($limitsize == 1) {
      if ($_FILES['userfile']['size'][$i] > (1024*$maxsize) ) {
      $toobig[$i] = "{$_FILES['userfile']['name'][$i]} is too large! the maximum file size is $maxsize kb.";
      } }
      
      if ($acceptfilter == 1) {
      if (!in_array($_FILES['userfile']['type'][$i], $acceptabletypes)) {
      $rejectstring = "{$_FILES['userfile']['name'][$i]} is not of the type ";
      foreach ($acceptabletypes as $acceptabletype) {
      $rejectstring .= "$acceptabletype or "; }
      $rejectstring = substr($rejectstring, 0, -4);
      $notacceptable[$i] = "$rejectstring.";
      } }
      
      if ($overwriting !== 1) {
      if(file_exists("pkfiles/{$_FILES['userfile']['name'][$i]}")) {
      $alreadyexists[$i] = "a file of the name {$_FILES['userfile']['name'][$i]} already exists! overwriting is not permitted.";
      } }
      
      if (!isset($toobig[$i]) && !isset($notacceptable[$i]) && !isset($alreadyexists[$i])) {
      $file="{$_FILES['userfile']['name'][$i]}";
      $videsc = $_POST["videsc"];
      if(spacesin($file))
      {
              echo "No input space!.<br/>";
       }else{
      if (!eregi("\.(mid|gif|bmp|mid|midi|3gp|mp3|mp4|wav|mpn|nth|mpc|jar|jad|jpeg|jpg|sis|mmf|amr|thm|png|wbmp|rar|zip)$",$file))
      {
       echo "Unsupported file extension!<br/>";
       }else{
      
      copy($_FILES['userfile']['tmp_name'][$i], "pkfiles/{$_FILES['userfile']['name'][$i]}");
      echo "{$_FILES['userfile']['name'][$i]}<br>";
      $ext = getext($file);
              $mime = getextfile($ext);
      $file = "{$_FILES['userfile']['name'][$i]}";
      $filesize = filesize("./pkfiles/".$file);
      $filesize = $filesize / 50000;
      $fsize = 0;
      $fsizetxt = "";
        if ($filesize < 1)
        {
           $fsize = round($filesize*50000);
           $fsizetxt = "".$fsize." KB";
          $check1 = "KB";
        }else{
           $fsize = round($filesize,2);
           $fsizetxt = "".$fsize." MB";
      $check1 = "MB";
        }
       $info = "<br/>Name<br/>".$file." Type<br/>".$mime." Size<br/>".$fsizetxt."";
      $res = mysql_query("INSERT INTO ibwf_vault SET uid='".$uid."', title='".$file."', pudt='".time()."', did='".$did."', info='".$info."', filesize='".$fsizetxt."', mime='".$mime."', itemurl='".$file."'");
            if($res)
            {
              echo "File successfully uploaded!<br/>";
            }else{
              echo "Invalid or already in our database!<br/>";
            }
      }
      
      
      }
      $f++;
      $content .= "$date $userip uploads pkfiles/{$_FILES['userfile']['name'][$i]} ($kbsize kb)\n";
      }
      
      elseif ($_FILES['userfile']['size'][$i] !== 0) { 
      echo "$toobig[$i] $notacceptable[$i] $alreadyexists[$i]<br>"; 
      $content .= "$date $userip fails to upload $uploaddir/{$_FILES['userfile']['name'][$i]} ($kbsize kb) - $toobig[$i] $notacceptable[$i] $alreadyexists[$i]\n";
      }
      
      $i++;   
      }
      
      
      
      if ($makelog == 1) {
      $handle = fopen("$logfile", "a");
      fwrite ($handle, $content);
      fclose ($handle); }
      
      }
      
      
      ?>
      
      
      <form action="<?= $_SERVER['PHP_SELF']."?".$_SERVER['QUERY_STRING']; ?>" method="post" enctype="multipart/form-data">
        Add files and Get 5 Plusses for Every Downloads :)
      <br>
      
      <?
      for($d=0; $d < $fields; $d++) {
      
      echo "<input name=\"userfile[]\" type=\"file\" size=\"30\"><br>"; 
      
      }
      ?>
        Category:<br/><select name="did">
        <option value="1">Symbian Software</option>
       <option value="2">Java Software</option>
       <option value="3">Anti Virus</option>
      <option value="4">s40v2/s40v3 Themes</option>";
        <option value="5">s60/s60v3/Nseries Themes </option>
       <option value="6">Sony Ericsson Themes </option>
        <option value="7">s30/40/s40v2 Games </option>";
        <option value="8">s60/s60v3 Games </option>";
        <option value="9">Eseries/Nseries/Ngage Games </option>
       <option value="10">Sony Ericsson Games</option>
       <option value="11">Full MP3</option>
        <option value="12">3GP Videos</option>
       <option value="13">Scandal</option>
      <option value="14">Gameboy Games</option>
       <option value="15">Naruto Themes/Poly/MP3</option>
       <option value="16">MP3/MIDI/WAV/POLY/AMR/RAR</option>
           <option value="17">Opera Software</option>
        </select><br/>
      
      <input type="submit" value="Upload now">
      </form>
      
      
      <?
      
      echo "<ul>";
      
      
      if ($limitsize == 1) {
      echo "<li><b>The Maximum File size is 5MB.</b></li>"; }
      
      
      echo "</ul>";
      if ($ver==wml)
      {
      echo "<a href=\"http://wap.net.ph/index.php?action=vault&amp;sid=$sid\">Downloads</a><br/>";
      echo "<a href=\"http://wap.net.ph/index.php?action=main&amp;sid=$sid\">Main menu</a><br/>";
      }else{ 
      echo "<a href=\"http://v2.wap.net.ph/index.php?action=vault&amp;sid=$sid\">Downloads</a><br/>";
      echo "<a href=\"http://v2.wap.net.ph/index.php?action=main&amp;sid=$sid\">Main menu</a>";
      }
      unset($count, $acceptabletypes, $handle, $content, $date, $kbsize);
      
      
      ?>
      sql
      Code:
      --
      -- Table structure for table `ibwf_vault`
      --
      
      CREATE TABLE IF NOT EXISTS `ibwf_vault` (
        `id` int(100) NOT NULL auto_increment,
        `uid` int(100) NOT NULL default '0',
        `title` varchar(50) NOT NULL default '',
        `itemurl` varchar(255) NOT NULL default '',
        `pudt` int(100) NOT NULL default '0',
        `cat` int(50) NOT NULL default '0',
        `type` int(100) NOT NULL default '0',
        `downloads` int(100) NOT NULL default '0',
        `url` varchar(200) NOT NULL,
        `filesize` varchar(60) NOT NULL,
        `did` int(10) NOT NULL,
        `time` int(100) NOT NULL default '0',
        `mime` int(100) NOT NULL,
        `info` varchar(100) NOT NULL,
        PRIMARY KEY  (`id`)
      ) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=76 ;
      
      --
      -- Dumping data for table `ibwf_vault`
      --
      core.php
      Code:
      function getextfile($ext)
      {
          $ext = strtolower($ext);
          switch ($ext)
          {
            case "jpg":
            case "jpeg":
            case "jpe":
            return "image/jpeg";
              break;
            case "gif":
            return "image/x-generic";
              break;
             case "png":
            return "image/png";
              break;
             case "bmp":
              return "image/bmp";
              break;
            case "zip":
            return "application/zip";
              break;
            case "sis":
              return "application/vnd.symbian.install";
              break;
           case "rar":
              return "package/x-generic";
              break;
            case "amr":
           return "audio/amr";
              break;
           case "mpga":
            case "mp3":
            case "mp2":
              return "audio/mpeg";
              break;
            case "wav":
              return "audio/x-wav";
              break;
            case "mpg":
            case "mpeg":
            case "mpe":
            return "video/mpeg";
              break;
             case "3gp":
             case "3gpp":
              return "video/3gpp";
              break;
              case "jar":
              return "application/java-archive";
              break;
           case "jad":
              return "text/vnd.sun.j2me.app-descriptor";
              break;
              default:
              return "other";
              break;
          }
      }
      //////////////////////GET USER NICK FROM USERID
      
      function getfile($id)
      {
        $unick = mysql_fetch_array(mysql_query("SELECT id FROM ibwf_vault WHERE id='".$id."'"));
        return $unick[0];
      }
      create a folder pkfiles and chmod it 777

      Here are all the files needed anyone can help me set it up corectly
      Last edited by riderz; 30.08.09, 18:15.

      Comment


        #33
        theres some missing fild in your uploader rider..

        Comment


          #34
          ive posted everything that i found on the wap.net.ph i dnt think there are mising files which one are missing

          Comment


            #35
            bro theres no form for the title,description of files in your uploader.php

            Comment


              #36
              in upload.php is not defined in thes $uploaddir ="."; where????? Try to definises $uploaddir ="$pkfiles";
              and add to config.php (as we did for the MMS inbox)

              $pkfiles = "./pkfiles";

              P.S Not I tested this, but can be ok
              Last edited by srecnica; 30.08.09, 19:25.
              sigpichttp://happy.srecnica.com/web

              Comment


                #37
                and what bout the url uploader i have error in genproc after i click upload it just give a blank page

                the uploader work in the upload.php file there i dnt have a prob the prob i have i cant download the file or delete it

                it get upload to the folder but i cant download the file or delete it
                Last edited by riderz; 30.08.09, 18:53.

                Comment


                  #38
                  which browser to trying to do? maybe the problem is the ban for browsers that are defined in the file getnow.php
                  sigpichttp://happy.srecnica.com/web

                  Comment


                    #39
                    when i click on the file to download there are no action taken place im using opera atm

                    Comment


                      #40
                      Originally posted by huwad View Post
                      oh c0m'on? what kind of admin he is? ahaha.. an admin that can be phish? wiw.. i t0ld u, only n0obz can be phished..
                      you can't say it brother.,ika nga, mtalino man ang matsing, naiisahan o npaglalanganan dn.. =)
                      My Blog: http://jhommark.blogspot.com
                      My Facebook: http://www.facebook.com/jhommark
                      My Official Site: http://www.undergroundweb.tk
                      My Community Site: http://undergroundwap.xtreemhost.com

                      Comment


                        #41
                        yes..continue again..hehe -up-

                        Comment


                          #42
                          Originally posted by zamaritan View Post
                          yes..continue again..hehe -up-
                          hehe, ayuko na..tnt..d nmn tlga q nanguna eh..
                          [br/]
                          just be keen observant people..you can fix that..i'll try also..wait..maybe the problem is in getnow.php?
                          Last edited by kiLLeR-eyEd_14; 30.08.09, 19:38.
                          My Blog: http://jhommark.blogspot.com
                          My Facebook: http://www.facebook.com/jhommark
                          My Official Site: http://www.undergroundweb.tk
                          My Community Site: http://undergroundwap.xtreemhost.com

                          Comment


                            #43
                            yea i think so coz it get uploaded but when i try to download there are no action taken place and i dnt know whats the prob with the url uploader there are no action after u click on upload when u type in the url of the item it go to a blank page in genproc

                            Comment


                              #44
                              My files work now i can download the stuff hehe now i have a prob with the delt option

                              Comment


                                #45
                                Code:
                                else if($action=="addvlt")
                                {
                                
                                if(!getplusses(getuid_sid($sid))>25)
                                    {
                                      echo "<title>pinoykindat.net</title>";
                                      echo "<p align=\"center\">";
                                      echo "Only the user of 25+ plusses can add a vault item<br/><br/>";
                                      echo "<a href=\"index.php?action=main&amp;sid=$sid\">Home</a>";
                                      echo "</p>";
                                      echo "</body>";
                                      echo "</html>";
                                      exit();
                                    }
                                  $viname = $_POST["viname"];
                                  $vilink = $_POST["vilink"];
                                $videsc = $_POST["videsc"];
                                  $did = $_POST["did"];
                                  $vid = $_POST["vid"];
                                 //$qut = $_POST["qut"];
                                
                                 $fname= array_reverse(explode("/",$vilink));
                                  addonline(getuid_sid($sid),"Adding A Vault Item","index.php?action=main");
                                
                                error_reporting(0);
                                 if(strlen($viname)<5)
                                {
                                      echo "<title>pinoykindat.net</title>";
                                      echo "<p align=\"center\">";
                                        echo "5 minimum letters for the title!";
                                  echo "<br/><a href=\"index.php?action=main&amp;sid=$sid\">";
                                  echo "Main menu</a>";
                                      echo "</p>";
                                      echo "</body>";
                                      echo "</html>";
                                      exit();
                                    }
                                 if(strlen($vilink)<5)
                                {
                                      echo "<title>pinoykindat.net</title>";
                                      echo "<p align=\"center\">";
                                        echo "5 minimum letters for the link!";
                                  echo "<br/><a href=\"index.php?action=main&amp;sid=$sid\">";
                                  echo "Main menu</a>";
                                      echo "</p>";
                                      echo "</body>";
                                      echo "</html>";
                                      exit();
                                    }
                                 if(strlen($videsc)<5)
                                {
                                      echo "<title>pinoykindat.net</title>";
                                      echo "<p align=\"center\">";
                                        echo "5 minimum letters for the description!";
                                  echo "<br/><a href=\"index.php?action=main&amp;sid=$sid\">";
                                  echo "Main menu</a>";
                                      echo "</p>";
                                      echo "</body>";
                                      echo "</html>";
                                      exit();
                                    }
                                if(spacesin($vilink))
                                {
                                      echo "<card id=\"main\" title=\"Error adding\">";
                                      echo "<p align=\"center\">";
                                      echo "No space input!<br/>";
                                      echo "<a href=\"index.php?action=main&amp;sid=$sid\">Main menu</a>";
                                      echo "</p>";
                                      echo "</body>";
                                      echo "</html>";
                                      exit();
                                    }
                                $fname= array_reverse(explode("/",$vilink));
                                
                                if (!eregi("\.(mid|gif|bmp|mid|midi|3gp|mp3|mp4|wav|mpn|nth|mpc|jar|jad|jpeg|jpg|sis|mmf|amr|thm|png|wbmp|rar|zip)$",$fname[0]))
                                {
                                echo "<card id=\"main\" title=\"Error adding\">";
                                      echo "<p align=\"center\">";
                                echo "<b>Unsuported File extention!</b><br/>";
                                echo "<a href=\"index.php?action=main&amp;sid=$sid\">Main menu</a>";
                                                  echo "</p></card></wml>";
                                			exit();
                                			}
                                echo "<title>pinoykindat.net</title>";
                                      echo "<p align=\"center\">";
                                      $crdate = time();
                                      //$uid = getuid_sid($sid);
                                
                                   $res = false;
                                
                                $defaultDest = "$dir";
                                $slash       = "/";
                                
                                $dest        = "./pkfiles/";
                                 $fname= array_reverse(explode("/",$vilink));
                                $ds = array($dest, $slash, $fname[0]);
                                		$ds = implode("", $ds);
                                  if (!copy($vilink, $ds))
                                {
                                 echo "Dead link is not allowed!(<br/>"; 
                                }else{       
                                  $fname= array_reverse(explode("/",$vilink));
                                $ext = getext($fname[0]);
                                        $mime = getextfile($ext);
                                $fname= array_reverse(explode("/",$vilink));
                                   $filesize = filesize($ds);
                                $filesize = $filesize / 1048576;
                                $fsize = 0;
                                $fsizetxt = "";
                                  if ($filesize < 1)
                                  {
                                     $fsize = round($filesize*1024,0);
                                     $fsizetxt = "".$fsize."KB";
                                    $check1 = "KB";
                                  }else{
                                     $fsize = round($filesize,2);
                                     $fsizetxt = "".$fsize." MB";
                                $check1 = "MB";
                                  }
                                  $res = mysql_query("INSERT INTO ibwf_vault SET uid='".$uid."', title='".mysql_escape_string($viname)."', pudt='".$crdate."', did='".$did."', info='".$videsc."',filesize='".$fsizetxt."', mime='".$mime."', itemurl='".$fname[0]."'");
                                 if($res)
                                      {
                                mysql_query("UPDATE ibwf_users SET plusses=plusses-'5' WHERE id='".$uid."'");
                                 echo "File added successfully!";
                                      }else{
                                        
                                      }
                                }
                                      echo "<br/><br/>";
                                      echo "<a href=\"index.php?action=main&amp;sid=$sid\">";
                                echo "Main menu</a>";
                                      echo "</p>";
                                      echo "</body>";
                                
                                }
                                add this in the genproc now the file get uploaded but it dnt display on the downloads lists anyone please help

                                Comment

                                Working...
                                X