Why Wont It Show The Image

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

    Why Wont It Show The Image

    <?

    include(&#39;class.upload.php&#39;);
    include("config.php");
    include("core.php");


    if($mime== WEB)
    {
    echo "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>";

    echo "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">";

    }else{
    echo "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>";

    echo "<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.1//EN\"". " \"http://www.wapforum.org/DTD/wml_1.1.xml\">";
    }
    $bcon = connectdb();
    if (!$bcon)
    {
    if($mime== WEB)
    {
    echo dberror($mime);

    }else{
    echo dberror($mime);
    }
    }
    $getuthm = mysql_fetch_array(mysql_query("SELECT theme FROM ibwf_users WHERE id=&#39;".$uid."&#39;"));
    $uth = $getuthm[0];
    if(!$uth=="")
    {
    $uthm = "$uth";
    }else{
    $uthm = "default.css";
    }
    $ses = $_GET["ses"];
    $uid = getuid_ses($ses);

    set_time_limit(0);
    $brws = explode(" ",$HTTP_USER_AGENT);
    $ubr = $brws[0];
    $uip = getip();

    $img1 = $_POST["img1"];

    if((islogged($ses)==false)||($uid==0))
    {
    if($mime== WEB)
    {
    echo notlogged($mime);

    }else{
    echo notlogged($mime);
    }

    }



    if(isipbanned($uip,$ubr))
    {

    if(!isshield(getuid_ses($ses)))
    {
    if($mime== WEB)
    {
    echo useripbanned($mime,$uip,$ubr);

    }else{
    echo useripbanned($mime,$uip,$ubr);
    }

    }
    }

    //echo isbanned($uid);
    if(isbanned($uid))
    {
    if($mime== WEB)
    {
    echo userbanned($mime,$uid);

    }else{
    echo userbanned($mime,$uid);
    }

    }

    ///////////////////////////////////////////////////////////Main
    if($action=="main")
    {
    addonline(getuid_ses($ses),"User Gallery","");
    if($mime== WEB)
    {
    echo webhead($uthm,$stitle);
    echo "<p align=\"center\">";
    echo "The Gallery of the Members from MostWantedZN
    ";
    echo "
    ";
    echo "
    </p>";
    echo "

    ";
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery WHERE sex=&#39;2&#39;"));
    echo "<a href=\"usergallery.php?action=females&amp;ses=$ses \"><img src=\"images/female.gif\" alt=\"*\"/>Females</a>($noi[0])
    ";
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery WHERE sex=&#39;1&#39;"));
    echo "<a href=\"usergallery.php?action=males&amp;ses=$ses\" ><img src=\"images/male.gif\" alt=\"*\"/>Males</a>($noi[0])

    ";
    echo "<a href=\"usergallery.php?action=upload&amp;ses=$ses\ ">Add Your Photo</a>

    ";
    echo "
    </p>";
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo webfoot();

    }else{
    echo waphead($stitle);
    echo "<p align=\"center\">";
    echo "The Gallery of the Members from MostWantedZN
    ";
    echo "
    ";
    echo "
    </p>";
    echo "

    ";
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery WHERE sex=&#39;2&#39;"));
    echo "<a href=\"usergallery.php?action=females&amp;ses=$ses \"><img src=\"images/female.gif\" alt=\"*\"/>Females</a>($noi[0])
    ";
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery WHERE sex=&#39;1&#39;"));
    echo "<a href=\"usergallery.php?action=males&amp;ses=$ses\" ><img src=\"images/male.gif\" alt=\"*\"/>Males</a>($noi[0])

    ";
    echo "<a href=\"usergallery.php?action=upload&amp;ses=$ses\ ">Add Your Photo</a>

    ";
    echo "
    </p>";
    echo "<p align=\"center\">";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo wapfoot();

    }
    }

    else if($action=="males")
    {
    addonline(getuid_ses($ses),"Male Gallery","");
    if($mime== WEB)
    {
    echo webhead($uthm,$stitle);
    echo "<p align=\"center\">";
    echo "Male Users From MostWantedZN";
    echo "

    ";
    echo "
    </p>";
    //////ALL LISTS SCRIPT <<
    $uid1 = getuid_ses($ses);

    if($page=="" || $page<=0)$page=1;
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery WHERE sex=&#39;1&#39;"));
    $num_items = $noi[0]; //changable
    $items_per_page= 5;
    $num_pages = ceil($num_items/$items_per_page);
    if(($page>$num_pages)&&$page!=1)$page= $num_pages;
    $limit_start = ($page-1)*$items_per_page;

    //changable sql

    $sql = "SELECT uid, id, imageurl FROM ibwf_usergallery WHERE sex=&#39;1&#39; ORDER BY id DESC LIMIT $limit_start, $items_per_page";


    echo "

    ";
    $items = mysql_query($sql);

    echo mysql_error();
    if(mysql_num_rows($items)>0)
    {
    while ($item = mysql_fetch_array($items))
    {
    $sql = "SELECT rating FROM ibwf_usergallery_rating WHERE imageid=&#39;".$item[1]."&#39;";
    $imginfo = mysql_query($sql);

    echo mysql_error();
    if(mysql_num_rows($imginfo)>0)
    {
    while ($imginfos = mysql_fetch_array($imginfo)){
    $ratingtotal = $ratingtotal + $imginfos[0];}
    }


    if($totalcomments<1){$totalcomments=0;}
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE imageid=&#39;".$item[1]."&#39;"));
    if ($norm[0]>0){
    $rating = ceil($ratingtotal/$norm[0]);
    }else{$rating=0;}

    $rated = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE byuid=&#39;".$uid1."&#39; and imageid =&#39;".$item[1]."&#39;"));
    $totalcomments = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE imageid =&#39;".$item[1]."&#39; and commentsyn =&#39;Y&#39;"));
    $userinfo = mysql_fetch_array(mysql_query("SELECT name FROM ibwf_users WHERE id=&#39;".$item[0]."&#39;"));

    echo "<a href=\"index.php?action=viewuser&amp;who=$item[0]&amp;ses=$ses\">$userinfo[0]</a>";
    if(canratephoto($uid1, $item[0]) and ($rated[0]==0))
    {
    echo "
    <a href=\"usergallery.php?action=rate&amp;ses=$ses&am p;whoimage=$item[1]\">Rate This Photo</a>";
    }
    if(($uid1=="1") or ($uid1==$item[0]))
    {
    echo " / <a href=\"usergallery.php?action=delsss1&amp;ses=$ses &amp;whoimage=$item[1]\">Del</a>";
    }
    if($uid1==$item[0])
    {
    echo "
    <a href=\"genproc.php?action=upavg&amp;ses=$ses&amp;a vsrc=$item[2]\">Use As Avatar</a>";
    }
    echo "

    <img src=\"$item[2]\" alt=\"$userinfo[0]\"/>
    ";
    echo "Rating: $rating/10 (<a href=\"usergallery.php?action=votes&amp;ses=$ses&a mp;whoimage=$item[1]\">$norm[0]</a> Votes)
    <a href=\"usergallery.php?action=comments&amp;ses=$se s&amp;whoimage=$item[1]\">Comments</a>($totalcomments[0])";
    echo "


    ";
    $ratingtotal = 0;

    }
    }

    echo "</p>";
    echo "<p align=\"center\">";
    if($page>1)
    {
    $ppage = $page-1;
    echo "<a href=\"usergallery.php?action=males&amp;ses=$ses&a mp;page=$ppage\">«Prev</a> ";
    }
    if($page<$num_pages)
    {
    $npage = $page+1;
    echo "<a href=\"usergallery.php?action=males&amp;ses=$ses&a mp;page=$npage\">Next»</a>";
    }
    echo "
    $page/$num_pages
    ";
    if($num_pages>2)
    {
    $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>";
    $rets .= "<anchor>[GO]";
    $rets .= "<go href=\"usergallery.php\" method=\"get\">";
    $rets .= "<postfield name=\"action\" value=\"$action\"/>";
    $rets .= "<postfield name=\"ses\" value=\"$ses\"/>";
    $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
    $rets .= "</go></anchor>";

    echo $rets;
    }
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo webfoot();

    }else{
    echo waphead($stitle);
    echo "<p align=\"center\">";
    echo "Male Users From MostWantedZN";
    echo "

    ";
    echo "
    </p>";
    //////ALL LISTS SCRIPT <<
    $uid1 = getuid_ses($ses);

    if($page=="" || $page<=0)$page=1;
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery WHERE sex=&#39;1&#39;"));
    $num_items = $noi[0]; //changable
    $items_per_page= 5;
    $num_pages = ceil($num_items/$items_per_page);
    if(($page>$num_pages)&&$page!=1)$page= $num_pages;
    $limit_start = ($page-1)*$items_per_page;

    //changable sql

    $sql = "SELECT uid, id, imageurl FROM ibwf_usergallery WHERE sex=&#39;1&#39; ORDER BY id DESC LIMIT $limit_start, $items_per_page";


    echo "

    ";
    $items = mysql_query($sql);

    echo mysql_error();
    if(mysql_num_rows($items)>0)
    {
    while ($item = mysql_fetch_array($items))
    {
    $sql = "SELECT rating FROM ibwf_usergallery_rating WHERE imageid=&#39;".$item[1]."&#39;";
    $imginfo = mysql_query($sql);

    echo mysql_error();
    if(mysql_num_rows($imginfo)>0)
    {
    while ($imginfos = mysql_fetch_array($imginfo)){
    $ratingtotal = $ratingtotal + $imginfos[0];}
    }


    if($totalcomments<1){$totalcomments=0;}
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE imageid=&#39;".$item[1]."&#39;"));
    if ($norm[0]>0){
    $rating = ceil($ratingtotal/$norm[0]);
    }else{$rating=0;}

    $rated = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE byuid=&#39;".$uid1."&#39; and imageid =&#39;".$item[1]."&#39;"));
    $totalcomments = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE imageid =&#39;".$item[1]."&#39; and commentsyn =&#39;Y&#39;"));
    $userinfo = mysql_fetch_array(mysql_query("SELECT name FROM ibwf_users WHERE id=&#39;".$item[0]."&#39;"));

    echo "<a href=\"index.php?action=viewuser&amp;who=$item[0]&amp;ses=$ses\">$userinfo[0]</a>";
    if(canratephoto($uid1, $item[0]) and ($rated[0]==0))
    {
    echo "
    <a href=\"usergallery.php?action=rate&amp;ses=$ses&am p;whoimage=$item[1]\">Rate This Photo</a>";
    }
    if(($uid1=="1") or ($uid1==$item[0]))
    {
    echo " / <a href=\"usergallery.php?action=delsss1&amp;ses=$ses &amp;whoimage=$item[1]\">Del</a>";
    }
    if($uid1==$item[0])
    {
    echo "
    <a href=\"genproc.php?action=upavg&amp;ses=$ses&amp;a vsrc=$item[2]\">Use As Avatar</a>";
    }
    echo "

    <img src=\"$item[2]\" alt=\"$userinfo[0]\"/>
    ";
    echo "Rating: $rating/10 (<a href=\"usergallery.php?action=votes&amp;ses=$ses&a mp;whoimage=$item[1]\">$norm[0]</a> Votes)
    <a href=\"usergallery.php?action=comments&amp;ses=$se s&amp;whoimage=$item[1]\">Comments</a>($totalcomments[0])";
    echo "


    ";
    $ratingtotal = 0;

    }
    }

    echo "</p>";
    echo "<p align=\"center\">";
    if($page>1)
    {
    $ppage = $page-1;
    echo "<a href=\"usergallery.php?action=males&amp;ses=$ses&a mp;page=$ppage\">«Prev</a> ";
    }
    if($page<$num_pages)
    {
    $npage = $page+1;
    echo "<a href=\"usergallery.php?action=males&amp;ses=$ses&a mp;page=$npage\">Next»</a>";
    }
    echo "
    $page/$num_pages
    ";
    if($num_pages>2)
    {
    $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>";
    $rets .= "<anchor>[GO]";
    $rets .= "<go href=\"usergallery.php\" method=\"get\">";
    $rets .= "<postfield name=\"action\" value=\"$action\"/>";
    $rets .= "<postfield name=\"ses\" value=\"$ses\"/>";
    $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
    $rets .= "</go></anchor>";

    echo $rets;
    }
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo wapfoot();

    }
    }

    else if($action=="females")
    {
    addonline(getuid_ses($ses),"Female Gallery","");
    if($mime== WEB)
    {
    echo webhead($uthm,$stitle);
    echo "<p align=\"center\">";
    echo "Female Users From MostWantedZN";
    echo "

    ";
    echo "
    </p>";
    //////ALL LISTS SCRIPT <<
    $uid1 = getuid_ses($ses);

    if($page=="" || $page<=0)$page=1;
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery WHERE sex=&#39;2&#39;"));
    $num_items = $noi[0]; //changable
    $items_per_page= 5;
    $num_pages = ceil($num_items/$items_per_page);
    if(($page>$num_pages)&&$page!=1)$page= $num_pages;
    $limit_start = ($page-1)*$items_per_page;

    //changable sql

    $sql = "SELECT uid, id, imageurl FROM ibwf_usergallery WHERE sex=&#39;2&#39; ORDER BY id DESC LIMIT $limit_start, $items_per_page";


    echo "

    ";
    $items = mysql_query($sql);

    echo mysql_error();
    if(mysql_num_rows($items)>0)
    {
    while ($item = mysql_fetch_array($items))
    {
    $sql = "SELECT rating FROM ibwf_usergallery_rating WHERE imageid=&#39;".$item[1]."&#39;";
    $imginfo = mysql_query($sql);

    echo mysql_error();
    if(mysql_num_rows($imginfo)>0)
    {
    while ($imginfos = mysql_fetch_array($imginfo)){
    $ratingtotal = $ratingtotal + $imginfos[0];}
    }


    if($totalcomments<1){$totalcomments=0;}
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE imageid=&#39;".$item[1]."&#39;"));
    if ($norm[0]>0){
    $rating = ceil($ratingtotal/$norm[0]);
    }else{$rating=0;}

    $rated = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE byuid=&#39;".$uid1."&#39; and imageid =&#39;".$item[1]."&#39;"));
    $totalcomments = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE imageid =&#39;".$item[1]."&#39; and commentsyn =&#39;Y&#39;"));
    $userinfo = mysql_fetch_array(mysql_query("SELECT name FROM ibwf_users WHERE id=&#39;".$item[0]."&#39;"));

    echo "<a href=\"index.php?action=viewuser&amp;who=$item[0]&amp;ses=$ses\">$userinfo[0]</a>";
    if(canratephoto($uid1, $item[0]) and ($rated[0]==0))
    {
    echo "
    <a href=\"usergallery.php?action=rate&amp;ses=$ses&am p;whoimage=$item[1]\">Rate This Photo</a>";
    }
    if(($uid1=="1") or ($uid1==$item[0]))
    {
    echo " / <a href=\"usergallery.php?action=delsss1&amp;ses=$ses &amp;whoimage=$item[1]\">Del</a>";
    }
    if($uid1==$item[0])
    {
    echo "
    <a href=\"genproc.php?action=upavg&amp;ses=$ses&amp;a vsrc=$item[2]\">Use As Avatar</a>";
    }
    echo "

    <img src=\"$item[2]\" alt=\"$userinfo[0]\"/>
    ";
    echo "Rating: $rating/10 (<a href=\"usergallery.php?action=votes&amp;ses=$ses&a mp;whoimage=$item[1]\">$norm[0]</a> Votes)
    <a href=\"usergallery.php?action=comments&amp;ses=$se s&amp;whoimage=$item[1]\">Comments</a>($totalcomments[0])";
    echo "


    ";
    $ratingtotal = 0;

    }
    }

    echo "</p>";
    echo "<p align=\"center\">";
    if($page>1)
    {
    $ppage = $page-1;
    echo "<a href=\"usergallery.php?action=females&amp;ses=$ses &amp;page=$ppage\">«Prev</a> ";
    }
    if($page<$num_pages)
    {
    $npage = $page+1;
    echo "<a href=\"usergallery.php?action=females&amp;ses=$ses &amp;page=$npage\">Next»</a>";
    }
    echo "
    $page/$num_pages
    ";
    if($num_pages>2)
    {
    $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>";
    $rets .= "<anchor>[GO]";
    $rets .= "<go href=\"usergallery.php\" method=\"get\">";
    $rets .= "<postfield name=\"action\" value=\"$action\"/>";
    $rets .= "<postfield name=\"ses\" value=\"$ses\"/>";
    $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
    $rets .= "</go></anchor>";

    echo $rets;
    }
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo webfoot();

    }else{
    echo waphead($stitle);
    echo "<p align=\"center\">";
    echo "Female Users From MostWantedZN";
    echo "

    ";
    echo "
    </p>";
    //////ALL LISTS SCRIPT <<
    $uid1 = getuid_ses($ses);

    if($page=="" || $page<=0)$page=1;
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery WHERE sex=&#39;2&#39;"));
    $num_items = $noi[0]; //changable
    $items_per_page= 5;
    $num_pages = ceil($num_items/$items_per_page);
    if(($page>$num_pages)&&$page!=1)$page= $num_pages;
    $limit_start = ($page-1)*$items_per_page;

    //changable sql

    $sql = "SELECT uid, id, imageurl FROM ibwf_usergallery WHERE sex=&#39;2&#39; ORDER BY id DESC LIMIT $limit_start, $items_per_page";


    echo "

    ";
    $items = mysql_query($sql);

    echo mysql_error();
    if(mysql_num_rows($items)>0)
    {
    while ($item = mysql_fetch_array($items))
    {
    $sql = "SELECT rating FROM ibwf_usergallery_rating WHERE imageid=&#39;".$item[1]."&#39;";
    $imginfo = mysql_query($sql);

    echo mysql_error();
    if(mysql_num_rows($imginfo)>0)
    {
    while ($imginfos = mysql_fetch_array($imginfo)){
    $ratingtotal = $ratingtotal + $imginfos[0];}
    }


    if($totalcomments<1){$totalcomments=0;}
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE imageid=&#39;".$item[1]."&#39;"));
    if ($norm[0]>0){
    $rating = ceil($ratingtotal/$norm[0]);
    }else{$rating=0;}

    $rated = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE byuid=&#39;".$uid1."&#39; and imageid =&#39;".$item[1]."&#39;"));
    $totalcomments = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE imageid =&#39;".$item[1]."&#39; and commentsyn =&#39;Y&#39;"));
    $userinfo = mysql_fetch_array(mysql_query("SELECT name FROM ibwf_users WHERE id=&#39;".$item[0]."&#39;"));

    echo "<a href=\"index.php?action=viewuser&amp;who=$item[0]&amp;ses=$ses\">$userinfo[0]</a>";
    if(canratephoto($uid1, $item[0]) and ($rated[0]==0))
    {
    echo "
    <a href=\"usergallery.php?action=rate&amp;ses=$ses&am p;whoimage=$item[1]\">Rate This Photo</a>";
    }
    if(($uid1=="1") or ($uid1==$item[0]))
    {
    echo " / <a href=\"usergallery.php?action=delsss1&amp;ses=$ses &amp;whoimage=$item[1]\">Del</a>";
    }
    if($uid1==$item[0])
    {
    echo "
    <a href=\"genproc.php?action=upavg&amp;ses=$ses&amp;a vsrc=$item[2]\">Use As Avatar</a>";
    }
    echo "

    <img src=\"$item[2]\" alt=\"$userinfo[0]\"/>
    ";
    echo "Rating: $rating/10 (<a href=\"usergallery.php?action=votes&amp;ses=$ses&a mp;whoimage=$item[1]\">$norm[0]</a> Votes)
    <a href=\"usergallery.php?action=comments&amp;ses=$se s&amp;whoimage=$item[1]\">Comments</a>($totalcomments[0])";
    echo "


    ";
    $ratingtotal = 0;

    }
    }

    echo "</p>";
    echo "<p align=\"center\">";
    if($page>1)
    {
    $ppage = $page-1;
    echo "<a href=\"usergallery.php?action=females&amp;ses=$ses &amp;page=$ppage\">«Prev</a> ";
    }
    if($page<$num_pages)
    {
    $npage = $page+1;
    echo "<a href=\"usergallery.php?action=females&amp;ses=$ses &amp;page=$npage\">Next»</a>";
    }
    echo "
    $page/$num_pages
    ";
    if($num_pages>2)
    {
    $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>";
    $rets .= "<anchor>[GO]";
    $rets .= "<go href=\"usergallery.php\" method=\"get\">";
    $rets .= "<postfield name=\"action\" value=\"$action\"/>";
    $rets .= "<postfield name=\"ses\" value=\"$ses\"/>";
    $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
    $rets .= "</go></anchor>";

    echo $rets;
    }
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo wapfoot();

    }
    }

    else if($action=="rate")
    {
    addonline(getuid_ses($ses),"User Gallery","");
    if($mime== WEB)
    {
    echo webhead($uthm,$stitle);
    echo "<p align=\"center\">";
    echo "Rate this members Photo: 1=Low, 10=High
    You can also leave a comment for this photo!
    ";
    echo "
    ";
    echo "
    </p>";
    echo "

    ";
    echo "<form action=\"usergallery.php?action=rateuser&amp;ses=$ ses&amp;whoimage=$whoimage\" method=\"post\">";
    echo "Rate: <select name=\"rate\" value=\"$rate[0]\">";
    echo "<option value=\"1\">1</option>";
    echo "<option value=\"2\">2</option>";
    echo "<option value=\"3\">3</option>";
    echo "<option value=\"4\">4</option>";
    echo "<option value=\"5\">5</option>";
    echo "<option value=\"6\">6</option>";
    echo "<option value=\"7\">7</option>";
    echo "<option value=\"8\">8</option>";
    echo "<option value=\"9\">9</option>";
    echo "<option value=\"10\">10</option>";
    echo "</select>
    ";

    echo "Comments: <input name=\"comment\" format=\"*M\" maxlength=\"200\"/>
    ";
    echo "<input type=\"submit\" value=\"Rate\"/>";
    echo "</form>";

    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo webfoot();

    }else{
    echo waphead($stitle);
    echo "<p align=\"center\">";
    echo "Rate this members Photo: 1=Low, 10=High
    You can also leave a comment for this photo!
    ";
    echo "
    ";
    echo "
    </p>";
    echo "

    ";
    echo "Rate: <select name=\"rate\" value=\"$rate[0]\">";
    echo "<option value=\"1\">1</option>";
    echo "<option value=\"2\">2</option>";
    echo "<option value=\"3\">3</option>";
    echo "<option value=\"4\">4</option>";
    echo "<option value=\"5\">5</option>";
    echo "<option value=\"6\">6</option>";
    echo "<option value=\"7\">7</option>";
    echo "<option value=\"8\">8</option>";
    echo "<option value=\"9\">9</option>";
    echo "<option value=\"10\">10</option>";
    echo "</select>
    ";

    echo "Comments: <input name=\"comments\" format=\"*M\" maxlength=\"200\"/>
    ";
    echo "<anchor>Rate<go href=\"usergallery.php?action=rateuser&amp;ses=$se s&amp;whoimage=$whoimage\" method=\"post\">";
    echo "<postfield name=\"rate\" value=\"$(rate)\"/>";
    echo "<postfield name=\"comments\" value=\"$(comments)\"/>";
    echo "</go></anchor>";

    echo "</p>";

    echo "<p align=\"center\">";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "
    </p>";
    echo wapfoot();

    }
    }

    else if($action=="comments")
    {
    addonline(getuid_ses($ses),"User Gallery","");
    if($mime== WEB)
    {
    echo webhead($uthm,$stitle);
    echo "<p align=\"center\">";
    echo "
    ";
    echo "
    </p>";
    //////ALL LISTS SCRIPT <<

    if($page=="" || $page<=0)$page=1;
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE imageid=&#39;".$whoimage."&#39; and commentsyn =&#39;Y&#39;"));
    $num_items = $noi[0]; //changable
    $items_per_page= 5;
    $num_pages = ceil($num_items/$items_per_page);
    if(($page>$num_pages)&&$page!=1)$page= $num_pages;
    $limit_start = ($page-1)*$items_per_page;

    $uidinfo = mysql_fetch_array(mysql_query("SELECT uid FROM ibwf_usergallery WHERE id=&#39;".$whoimage."&#39;"));
    $uid = getuid_ses($ses);


    $sql = "SELECT rating, comments, byuid, time, commentsreply, id FROM ibwf_usergallery_rating WHERE imageid =&#39;".$whoimage."&#39; and commentsyn =&#39;Y&#39; ORDER BY time DESC LIMIT $limit_start, $items_per_page";


    echo "

    ";
    $items = mysql_query($sql);
    echo mysql_error();
    if(mysql_num_rows($items)>0)
    {
    while ($item = mysql_fetch_array($items))
    {

    if(isonline($item[2]))
    {
    $iml = "<img src=\"images/onl.gif\" alt=\"+\"/>";

    }else{
    $iml = "<img src=\"images/ofl.gif\" alt=\"-\"/>";
    }
    if(strlen($item[1])>1){

    $snick = getnick_uid($item[2]);
    $lnk = "<a href=\"index.php?action=viewuser&amp;who=$item[2]&amp;ses=$ses\">$iml$snick:</a> $item[0]/10";
    echo "$lnk
    ";
    $bs = date("d/m/y",$item[3]);
    $text = parsepm($item[1], $ses);
    if(($uid==$uidinfo[0]) and (strlen($item[4])<1))
    {
    $replylink = "<a href=\"usergallery.php?action=commentreply&amp;ses =$ses&amp;id=$item[5]\">Reply to Comment</a>
    $bs";
    }else{
    $replylink = " $bs";
    }
    echo "$text";
    if(strlen($item[4])>1)
    {
    $text1 = parsepm($item[4], $ses);
    echo "
    Reply: $text1";
    }
    echo "
    $replylink

    ";
    echo "
    ";
    }
    }
    }
    echo "</p>";
    echo "<p align=\"center\">";
    if($page>1)
    {
    $ppage = $page-1;
    echo "<a href=\"usergallery.php?action=$action&amp;page=$pp age&amp;ses=$ses&amp;who=$who\">«Prev</a> ";
    }
    if($page<$num_pages)
    {
    $npage = $page+1;
    echo "<a href=\"usergallery.php?action=$action&amp;page=$np age&amp;ses=$ses&amp;who=$who\">Next»</a>";
    }
    echo "
    $page/$num_pages
    ";
    if($num_pages>2)
    {
    $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>";
    $rets .= "<anchor>[GO]";
    $rets .= "<go href=\"usergallery.php\" method=\"get\">";
    $rets .= "<postfield name=\"action\" value=\"$action\"/>";
    $rets .= "<postfield name=\"who\" value=\"$who\"/>";
    $rets .= "<postfield name=\"ses\" value=\"$ses\"/>";
    $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
    $rets .= "</go></anchor>";

    echo $rets;
    }
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo webfoot();

    }else{
    echo waphead($stitle);
    echo "<p align=\"center\">";
    echo "
    ";
    echo "
    </p>";
    //////ALL LISTS SCRIPT <<

    if($page=="" || $page<=0)$page=1;
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE imageid=&#39;".$whoimage."&#39; and commentsyn =&#39;Y&#39;"));
    $num_items = $noi[0]; //changable
    $items_per_page= 5;
    $num_pages = ceil($num_items/$items_per_page);
    if(($page>$num_pages)&&$page!=1)$page= $num_pages;
    $limit_start = ($page-1)*$items_per_page;

    $uidinfo = mysql_fetch_array(mysql_query("SELECT uid FROM ibwf_usergallery WHERE id=&#39;".$whoimage."&#39;"));
    $uid = getuid_ses($ses);


    $sql = "SELECT rating, comments, byuid, time, commentsreply, id FROM ibwf_usergallery_rating WHERE imageid =&#39;".$whoimage."&#39; and commentsyn =&#39;Y&#39; ORDER BY time DESC LIMIT $limit_start, $items_per_page";


    echo "

    ";
    $items = mysql_query($sql);
    echo mysql_error();
    if(mysql_num_rows($items)>0)
    {
    while ($item = mysql_fetch_array($items))
    {

    if(isonline($item[2]))
    {
    $iml = "<img src=\"images/onl.gif\" alt=\"+\"/>";

    }else{
    $iml = "<img src=\"images/ofl.gif\" alt=\"-\"/>";
    }
    if(strlen($item[1])>1){

    $snick = getnick_uid($item[2]);
    $lnk = "<a href=\"index.php?action=viewuser&amp;who=$item[2]&amp;ses=$ses\">$iml$snick:</a> $item[0]/10";
    echo "$lnk
    ";
    $bs = date("d/m/y",$item[3]);
    $text = parsepm($item[1], $ses);
    if(($uid==$uidinfo[0]) and (strlen($item[4])<1))
    {
    $replylink = "<a href=\"usergallery.php?action=commentreply&amp;ses =$ses&amp;id=$item[5]\">Reply to Comment</a>
    $bs";
    }else{
    $replylink = " $bs";
    }
    echo "$text";
    if(strlen($item[4])>1)
    {
    $text1 = parsepm($item[4], $ses);
    echo "
    Reply: $text1";
    }
    echo "
    $replylink

    ";
    echo "
    ";
    }
    }
    }
    echo "</p>";
    echo "<p align=\"center\">";
    if($page>1)
    {
    $ppage = $page-1;
    echo "<a href=\"usergallery.php?action=$action&amp;page=$pp age&amp;ses=$ses&amp;who=$who\">«Prev</a> ";
    }
    if($page<$num_pages)
    {
    $npage = $page+1;
    echo "<a href=\"usergallery.php?action=$action&amp;page=$np age&amp;ses=$ses&amp;who=$who\">Next»</a>";
    }
    echo "
    $page/$num_pages
    ";
    if($num_pages>2)
    {
    $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>";
    $rets .= "<anchor>[GO]";
    $rets .= "<go href=\"usergallery.php\" method=\"get\">";
    $rets .= "<postfield name=\"action\" value=\"$action\"/>";
    $rets .= "<postfield name=\"who\" value=\"$who\"/>";
    $rets .= "<postfield name=\"ses\" value=\"$ses\"/>";
    $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
    $rets .= "</go></anchor>";

    echo $rets;
    }
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo wapfoot();

    }
    }

    else if($action=="commentreply")
    {
    addonline(getuid_ses($ses),"User Gallery","");
    if($mime== WEB)
    {
    echo webhead($uthm,$stitle);
    $id = $_GET["id"];
    echo "<p align=\"center\">";
    echo "Reply to a Comment
    ";
    echo "
    ";
    echo "
    </p>";
    echo "

    ";
    echo "<form action=\"usergallery.php?action=commentreplyaction &amp;ses=$ses&amp;id=$id\" method=\"post\">";
    echo "Reply: <input name=\"reply\" format=\"*M\" maxlength=\"200\"/>
    ";
    echo "<input type=\"submit\" value=\"Reply\"/>";
    echo "</form>";

    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo webfoot();

    }else{
    echo waphead($stitle);
    echo "<p align=\"center\">";
    echo "Reply to a Comment
    ";
    echo "
    ";
    echo "
    </p>";
    echo "

    ";

    echo "Reply Message<input name=\"reply\" format=\"*M\" maxlength=\"200\"/>
    ";
    echo "<anchor>Reply";
    echo "<go href=\"usergallery.php?action=commentreplyaction&a mp;ses=$ses&amp;id=$id\" method=\"post\">";
    echo "<postfield name=\"reply\" value=\"$(reply)\"/>";
    echo "</go></anchor>";

    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo wapfoot();

    }
    }

    else if($action=="votes")
    {
    addonline(getuid_ses($ses),"User Gallery","");
    if($mime== WEB)
    {
    echo webhead($uthm,$stitle);
    echo "<p align=\"center\">";
    echo "
    ";
    echo "
    </p>";
    //////ALL LISTS SCRIPT <<

    if($page=="" || $page<=0)$page=1;
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE imageid=&#39;".$whoimage."&#39;"));
    $num_items = $noi[0]; //changable
    $items_per_page= 20;
    $num_pages = ceil($num_items/$items_per_page);
    if(($page>$num_pages)&&$page!=1)$page= $num_pages;
    $limit_start = ($page-1)*$items_per_page;

    $imageratinginfo = "SELECT rating, byuid FROM ibwf_usergallery_rating WHERE imageid=&#39;".$item[1]."&#39;";


    $sql = "SELECT rating, byuid, time FROM ibwf_usergallery_rating WHERE imageid =&#39;".$whoimage."&#39; ORDER BY time DESC LIMIT $limit_start, $items_per_page";


    echo "

    ";
    $items = mysql_query($sql);
    echo mysql_error();
    if(mysql_num_rows($items)>0)
    {
    while ($item = mysql_fetch_array($items))
    {

    if(isonline($item[1]))
    {
    $iml = "<img src=\"images/onl.gif\" alt=\"+\"/>";

    }else{
    $iml = "<img src=\"images/ofl.gif\" alt=\"-\"/>";
    }

    $snick = getnick_uid($item[1]);
    $lnk = "<a href=\"index.php?action=viewuser&amp;who=$item[1]&amp;ses=$ses\">$iml$snick:</a> $item[0]/10";
    echo "$lnk
    ";

    }
    }
    echo "</p>";
    echo "<p align=\"center\">";
    if($page>1)
    {
    $ppage = $page-1;
    echo "<a href=\"usergallery.php?action=$action&amp;page=$pp age&amp;ses=$ses&amp;who=$who\">«Prev</a> ";
    }
    if($page<$num_pages)
    {
    $npage = $page+1;
    echo "<a href=\"usergallery.php?action=$action&amp;page=$np age&amp;ses=$ses&amp;who=$who\">Next»</a>";
    }
    echo "
    $page/$num_pages
    ";
    if($num_pages>2)
    {
    $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>";
    $rets .= "<anchor>[GO]";
    $rets .= "<go href=\"usergallery.php\" method=\"get\">";
    $rets .= "<postfield name=\"action\" value=\"$action\"/>";
    $rets .= "<postfield name=\"who\" value=\"$who\"/>";
    $rets .= "<postfield name=\"ses\" value=\"$ses\"/>";
    $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
    $rets .= "</go></anchor>";

    echo $rets;
    }
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo webfoot();

    }else{
    echo waphead($stitle);
    echo "<p align=\"center\">";
    echo "
    ";
    echo "
    </p>";
    //////ALL LISTS SCRIPT <<

    if($page=="" || $page<=0)$page=1;
    $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_usergallery_rating WHERE imageid=&#39;".$whoimage."&#39;"));
    $num_items = $noi[0]; //changable
    $items_per_page= 20;
    $num_pages = ceil($num_items/$items_per_page);
    if(($page>$num_pages)&&$page!=1)$page= $num_pages;
    $limit_start = ($page-1)*$items_per_page;

    $imageratinginfo = "SELECT rating, byuid FROM ibwf_usergallery_rating WHERE imageid=&#39;".$item[1]."&#39;";


    $sql = "SELECT rating, byuid, time FROM ibwf_usergallery_rating WHERE imageid =&#39;".$whoimage."&#39; ORDER BY time DESC LIMIT $limit_start, $items_per_page";


    echo "

    ";
    $items = mysql_query($sql);
    echo mysql_error();
    if(mysql_num_rows($items)>0)
    {
    while ($item = mysql_fetch_array($items))
    {

    if(isonline($item[1]))
    {
    $iml = "<img src=\"images/onl.gif\" alt=\"+\"/>";

    }else{
    $iml = "<img src=\"images/ofl.gif\" alt=\"-\"/>";
    }

    $snick = getnick_uid($item[1]);
    $lnk = "<a href=\"index.php?action=viewuser&amp;who=$item[1]&amp;ses=$ses\">$iml$snick:</a> $item[0]/10";
    echo "$lnk
    ";

    }
    }
    echo "</p>";
    echo "<p align=\"center\">";
    if($page>1)
    {
    $ppage = $page-1;
    echo "<a href=\"usergallery.php?action=$action&amp;page=$pp age&amp;ses=$ses&amp;who=$who\">«Prev</a> ";
    }
    if($page<$num_pages)
    {
    $npage = $page+1;
    echo "<a href=\"usergallery.php?action=$action&amp;page=$np age&amp;ses=$ses&amp;who=$who\">Next»</a>";
    }
    echo "
    $page/$num_pages
    ";
    if($num_pages>2)
    {
    $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>";
    $rets .= "<anchor>[GO]";
    $rets .= "<go href=\"usergallery.php\" method=\"get\">";
    $rets .= "<postfield name=\"action\" value=\"$action\"/>";
    $rets .= "<postfield name=\"who\" value=\"$who\"/>";
    $rets .= "<postfield name=\"ses\" value=\"$ses\"/>";
    $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>";
    $rets .= "</go></anchor>";

    echo $rets;
    }
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo wapfoot();

    }
    }

    else if($action=="rateuser")
    {
    addonline(getuid_ses($ses),"Rate a User","");
    $rate = $_POST["rate"];
    $comment = $_POST["comment"];
    if($mime== WEB)
    {
    echo webhead($uthm,$stitle);
    echo "<p align=\"center\">";
    $uid = getuid_ses($ses);
    if((strlen($comment))>1){
    $res= mysql_query("INSERT INTO ibwf_usergallery_rating SET imageid=&#39;".$whoimage."&#39;, rating=&#39;".$rate."&#39;, comments=&#39;".$comment."&#39;, byuid=&#39;".$uid."&#39;, time=&#39;".(time() - $timeadjust)."&#39;, commentsyn=&#39;Y&#39;");
    }else
    if((strlen($comment))<2){
    $res= mysql_query("INSERT INTO ibwf_usergallery_rating SET imageid=&#39;".$whoimage."&#39;, rating=&#39;".$rate."&#39;, comments=&#39;".$comment."&#39;, byuid=&#39;".$uid."&#39;, time=&#39;".(time() - $timeadjust)."&#39;, commentsyn=&#39;N&#39;");
    }

    if(($res) and ((strlen($comment))>1)){

    echo "<img src=\"images/ok.gif\" alt=\"o\"/>Rated Successfully
    ";
    echo "<img src=\"images/ok.gif\" alt=\"o\"/>Comments added Successfully
    ";
    }else
    if(($res) and ((strlen($comment))<2)){

    echo "<img src=\"images/ok.gif\" alt=\"o\"/>Rated Successfully
    ";
    echo "<img src=\"images/notok.gif\" alt=\"x\"/>No Comments were added
    ";
    }
    else{
    echo "<img src=\"images/notok.gif\" alt=\"x\"/>Rated unsuccessfully
    ";
    echo "<img src=\"images/notok.gif\" alt=\"x\"/>No Comments were added
    ";
    }
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo webfoot();

    }else{
    echo waphead($stitle);
    echo "<p align=\"center\">";
    $uid = getuid_ses($ses);
    if((strlen($comment))>1){
    $res= mysql_query("INSERT INTO ibwf_usergallery_rating SET imageid=&#39;".$whoimage."&#39;, rating=&#39;".$rate."&#39;, comments=&#39;".$comment."&#39;, byuid=&#39;".$uid."&#39;, time=&#39;".time()."&#39;, commentsyn=&#39;Y&#39;");
    }else
    if((strlen($comment))<2){
    $res= mysql_query("INSERT INTO ibwf_usergallery_rating SET imageid=&#39;".$whoimage."&#39;, rating=&#39;".$rate."&#39;, comments=&#39;".$comment."&#39;, byuid=&#39;".$uid."&#39;, time=&#39;".time()."&#39;, commentsyn=&#39;N&#39;");
    }

    if(($res) and ((strlen($comment))>1)){

    echo "<img src=\"images/ok.gif\" alt=\"o\"/>Rated Successfully
    ";
    echo "<img src=\"images/ok.gif\" alt=\"o\"/>Comments added Successfully
    ";
    }else
    if(($res) and ((strlen($comment))<2)){

    echo "<img src=\"images/ok.gif\" alt=\"o\"/>Rated Successfully
    ";
    echo "<img src=\"images/notok.gif\" alt=\"x\"/>No Comments were added
    ";
    }
    else{
    echo "<img src=\"images/notok.gif\" alt=\"x\"/>Rated unsuccessfully
    ";
    echo "<img src=\"images/notok.gif\" alt=\"x\"/>No Comments were added
    ";
    }
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo wapfoot();

    }
    }

    else if($action=="commentreplyaction")
    {
    addonline(getuid_ses($ses),"Reply To Comment","");
    $id = $_GET["id"];
    $reply = $_POST["reply"];
    if($mime== WEB)
    {
    echo webhead($uthm,$stitle);
    echo "<p align=\"center\">";
    $uid = getuid_ses($ses);
    $res = mysql_query("UPDATE ibwf_usergallery_rating SET commentsreply=&#39;".$reply."&#39; WHERE id=&#39;".$id."&#39;");


    if($res){

    echo "<img src=\"images/ok.gif\" alt=\"o\"/>Replyed Successfully
    ";
    }
    else{
    echo "<img src=\"images/notok.gif\" alt=\"x\"/>Replyed unsuccessfully
    ";
    }
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo webfoot();

    }else{
    echo waphead($stitle);
    echo "<p align=\"center\">";
    $uid = getuid_ses($ses);
    $res = mysql_query("UPDATE ibwf_usergallery_rating SET commentsreply=&#39;".$reply."&#39; WHERE id=&#39;".$id."&#39;");


    if($res){

    echo "<img src=\"images/ok.gif\" alt=\"o\"/>Replyed Successfully
    ";
    }
    else{
    echo "<img src=\"images/notok.gif\" alt=\"x\"/>Replyed unsuccessfully
    ";
    }
    echo "</p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo wapfoot();

    }
    }

    else if($action=="upload")
    {
    addonline(getuid_ses($ses),"Uploading a Photo","");
    $rate = $_POST["rate"];
    $comment = $_POST["comment"];
    if($mime== WEB)
    {
    echo webhead($uthm,$stitle);
    set_time_limit(0);
    echo "

    ";
    echo "You can now upload your photo direct from your phone. If this doesn&#39;t work, MMS or E-Mail me the photo to scooby.doo@telkomsa.net
    Note: You must rename your photo to your username if you MMS or E-Mail it.
    ";


    echo "
    Pick a Photo to upload, and press &#39;upload&#39;
    ";
    echo " <form name=\"form2\" enctype=\"multipart/form-data\" method=\"post\" action=\"upload.php?action=upload&amp;ses=$ses\" />";
    echo "<input type=\"file\" size=\"32\" name=\"my_field\" value=\"\" />";
    echo "<input type=\"hidden\" name=\"action\" value=\"image\" />
    ";
    echo "<input type=\"submit\" name=\"Submit\" value=\"upload\" />";
    echo "</form>";

    echo "
    </p>";
    ////// UNTILL HERE >>
    echo "<p align=\"center\">";
    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo webfoot();

    }else{
    echo waphead($stitle);
    echo "

    ";
    echo "If you want to upload a photo, you must use the xHTML version of the site or u can just MMS or E-Mail your photo to scooby.doo@telkomsa.net

    Note: You have to rename your pic to your username, or it won&#39;t be uploaded.
    Allow 2 to 7 days for your photo to be uploaded, it must be validatd first.

    ";

    echo "
    </p>";

    echo "<p align=\"center\">";
    echo "
    <a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo wapfoot();

    }
    }
    //////////// Delete users posts
    else if($action=="delsss1")
    {

    if($mime== WEB)
    {
    echo webhead($uthm,$stitle);
    echo "<p align=\"center\">";

    echo "
    ";
    $res = mysql_query("DELETE FROM ibwf_usergallery WHERE id=&#39;".$whoimage."&#39;");
    $res = mysql_query("DELETE FROM ibwf_usergallery_rating WHERE imageid=&#39;".$whoimage."&#39;");


    if($res)
    {
    echo "<img src=\"images/ok.gif\" alt=\"O\"/>Photo and all the Comments have been deleted";
    }else{
    echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error deleting Photo";
    }

    echo "

    <a href=\"usergallery.php?action=main&amp;ses=$ses\"> «Back to Gallery</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo webfoot();

    }else{
    echo waphead($stitle);
    echo "<p align=\"center\">";

    echo "
    ";
    $res = mysql_query("DELETE FROM ibwf_usergallery WHERE id=&#39;".$whoimage."&#39;");
    $res = mysql_query("DELETE FROM ibwf_usergallery_rating WHERE imageid=&#39;".$whoimage."&#39;");


    if($res)
    {
    echo "<img src=\"images/ok.gif\" alt=\"O\"/>Photo and all the Comments have been deleted";
    }else{
    echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error deleting Photo";
    }

    echo "

    <a href=\"admincp.php?action=chuinfo&amp;ses=$ses\">" ;
    echo "User info</a>
    ";
    echo "<a href=\"index.php?action=admincp&amp;ses=$ses\"><im g src=\"images/admn.gif\" alt=\"*\"/>";
    echo "Admin CP</a>
    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";

    echo "</p>";
    echo wapfoot();

    }
    }else
    {
    addonline(getuid_ses($ses),"Searching For Gold In Gallery","");
    if($mime== WEB)
    {
    echo webhead($uthm,$stitle);
    echo "<p align=\"center\">";
    echo "I don&#39;t know how did you get into here, but there&#39;s nothing to show

    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo webfoot();

    }else{
    echo waphead($stitle);
    echo "<p align=\"center\">";
    echo "I don&#39;t know how did you get into here, but there&#39;s nothing to show

    ";
    echo "<a href=\"index.php?action=main&amp;ses=$ses\"><img src=\"images/home.gif\" alt=\"*\"/>";
    echo "Home</a>";
    echo "</p>";
    echo wapfoot();

    }
    }
    ?>











    sql 4 it


    -- --------------------------------------------------------

    --
    -- Tabel struktuur vir tabel `ibwf_usergallery`
    --

    CREATE TABLE `ibwf_usergallery` (
    `id` int(100) NOT NULL auto_increment,
    `uid` int(100) NOT NULL default &#39;0&#39;,
    `imageurl` varchar(100) NOT NULL default &#39;&#39;,
    `sex` char(1) NOT NULL default &#39;&#39;,
    `time` int(100) NOT NULL default &#39;0&#39;,
    PRIMARY KEY (`id`)
    ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;

    --
    -- Stort data vir tabel `ibwf_usergallery`
    --


    -- --------------------------------------------------------

    #2
    Be more specific

    Comment


      #3
      image view script its your host read topic "Upload error" the post of me place that in hass file..
      Visit: Chat4u.mobi - The New Lay Of being a site of your dreams!
      Visit: WapMasterz Coming Back Soon!
      _______
      SCRIPTS FOR SALE BY SUBZERO
      Chat4u Script : coding-talk.com/f28/chat4u-mobi-script-only-150-a-17677/ - > Best Script for your site no other can be hacked by sql or uploaders.
      FileShare Script : coding-talk.com/f28/file-wap-share-6596/ -> Uploader you will never regret buying yeah it mite be old now but it still seems to own others...
      _______
      Info & Tips
      php.net
      w3schools.com

      Comment


        #4
        its the same problem in much topics. I am in my mobile, i cant read all the code, but:
        1) be sure the /gallery/ folder exist.
        2) be sure to upload the image into that gallery.
        3) edit the image source code.
        Hope you understood.
        mysterio.al - programming is a functional art

        Comment

        Working...
        X