Esempio n. 1
0
<?php

/**************************************************************************************************
| Gag Clone Script
| http://www.gagclonescript.com
| webmaster@gagclonescript.com
|
|**************************************************************************************************
|
| By using this software you agree that you have read and acknowledged our End-User License 
| Agreement available at http://www.gagclonescript.com/eula.html and to be bound by it.
|
| Copyright (c) GagCloneScript.com. All rights reserved.
|**************************************************************************************************/
include "../include/config.php";
include_once "../include/functions/import.php";
verify_login_admin();
$AID = intval($_REQUEST[AID]);
if ($AID > 0) {
    $query = $conn->execute("select code, nsfwcode from advertisements where AID='" . mysql_real_escape_string($AID) . "' limit 1");
    $ad = $query->getrows();
    Stemplate::assign('ad', $ad[0]);
}
$mainmenu = "11";
$submenu = "1";
Stemplate::assign('mainmenu', $mainmenu);
Stemplate::assign('submenu', $submenu);
STemplate::display("administrator/global_header.tpl");
STemplate::display("administrator/ads_preview.tpl");
STemplate::display("administrator/global_footer.tpl");
        $link = "Page {$page_no} of <b>{$spage}</b> Pages";
    } else {
        $link = "<br><br><br><center>There is no {$_REQUEST['a']} video available</center><br>";
    }
    //                $link = "You are in Page <b>$page</b> of <b>$spage</b>";
    if ($tpage > 1) {
        $nextpage = $page + 1;
        $prevpage = $page - 1;
        $prevlink = "<a href='videos.php?a={$_REQUEST['a']}&status={$status}&page={$prevpage}&sort={$sort}'><img src='../images/icon/previous.gif' title='Previous' alt='Previous' border='0' style='vertical-align: middle;'></a>";
        $nextlink = "<a href='videos.php?a={$_REQUEST['a']}&status={$status}&page={$nextpage}&sort={$sort}'><img src='../images/icon/next.gif' title='Next' alt='Next' border='0' style='vertical-align: middle;'></a>";
        if ($page == $tpage) {
            $link .= "&nbsp;&nbsp;|&nbsp;{$prevlink}";
        } elseif ($tpage > $page && $page > 1) {
            $link .= "&nbsp;&nbsp;|&nbsp;{$prevlink} &nbsp;&nbsp;{$nextlink}";
        } elseif ($tpage > $page && $page <= 1) {
            $link .= "&nbsp;&nbsp;|&nbsp;{$nextlink}";
        }
    }
    $sql = "SELECT * from video {$query} limit {$startfrom}, {$listing_per_page}";
    $rs = $conn->Execute($sql);
    $total = $rs->recordcount() + 0;
    $videos = $rs->getrows();
    STemplate::assign('link', $link);
    STemplate::assign('grandtotal', $grandtotal + 0);
    STemplate::assign('total', $total + 0);
    STemplate::assign('page', $page + 0);
    STemplate::assign('videos', $videos);
}
Stemplate::assign('err', $err);
Stemplate::assign('msg', $msg);
STemplate::display("siteadmin/channelvideos.tpl");
Esempio n. 3
0
        }
        $pagelinks .= $currentpage . "&nbsp;";
        $uppercounter = $currentpage + 1;
        while ($uppercounter < $currentpage + 10 - $counter && $uppercounter <= $toppage) {
            $pagelinks .= "<a href='{$adminurl}/bans_ip.php?page={$uppercounter}{$add1}'>{$uppercounter}</a>&nbsp;";
            $uppercounter++;
        }
        if ($currentpage < $toppage) {
            $pagelinks .= "<a href='{$adminurl}/bans_ip.php?page={$thenextpage}{$add1}'>Next</a>&nbsp;";
            $pagelinks .= "<a href='{$adminurl}/bans_ip.php?page={$toppage}{$add1}' title='last page'>Last</a>&nbsp;";
        }
    }
} else {
    $error = "Sorry, no IPs were found.";
}
$mainmenu = "5";
$submenu = "1";
Stemplate::assign('mainmenu', $mainmenu);
Stemplate::assign('submenu', $submenu);
Stemplate::assign('sorthow', $sorthow);
Stemplate::assign('sortby', $sortby);
Stemplate::assign('currentpage', $currentpage);
STemplate::display("administrator/global_header.tpl");
STemplate::assign('beginning', $beginning);
STemplate::assign('ending', $ending);
STemplate::assign('pagelinks', $pagelinks);
STemplate::assign('total', $total + 0);
STemplate::assign('results', $results);
Stemplate::assign('error', $error);
STemplate::display("administrator/bans_ip.tpl");
STemplate::display("administrator/global_footer.tpl");
Esempio n. 4
0
        $err = "Date has overlap with previour one.";
    }
    if ($err == "") {
        # FORMATIN ANSWERS...
        $ansBank = "";
        for ($i = 0; $i < $_REQUEST[txtAnsQty]; $i++) {
            $xx = "voteAnsBox" . $i;
            ## TO ADD LESS THEN ONE PIPE
            if ($ansBank != "") {
                $ansBank .= "|";
            }
            $ansBank .= $_REQUEST[$xx];
        }
        # INSERTING NEW POL QUESTION
        $sql = " INSERT INTO poll_question set \n                                                                                poll_qty='{$_REQUEST['txtQtn']}',\n                                                                                poll_answer='{$ansBank}',\n                                                                                start_date='{$start_day}',\n                                                                                end_date='{$end_day}'";
        $rs = $conn->Execute($sql);
        if ($rs) {
            $err = "Submit successfull";
        }
    }
}
## COLLECT DATE AND MONTH FOR SELECT INPUT
$month = months();
$dayes = days();
$year = cc_year();
Stemplate::assign('err', $err);
Stemplate::assign('msg', $msg);
Stemplate::assign('dayes', $dayes);
Stemplate::assign('month', $month);
Stemplate::assign('year', $year);
STemplate::display("siteadmin/poll.tpl");