Viewing file: showbanner.php (2.11 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php //***************
/********************************************************************************
- MemHT Portal -
Copyright (C) 2007-2008 by Miltenovik Manojlo
http://www.memht.com
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your opinion) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License along
with this program; if not, see <http://www.gnu.org/licenses/> (GPLv2)
or write to the Free Software Foundation, Inc., 51 Franklin Street,
Fifth Floor, Boston, MA02110-1301, USA.
********************************************************************************/
?><style type="text/css">
<!--
body {
margin: 0px;
padding: 0px;
}
-->
</style><?php
//===========================================
//Database: Connect
//===========================================
require_once("../../../inc/inc_config.php");
require_once("../../../inc/inc_database.php");
$dblink = new database();
$dblink->connect();
require_once("../../../inc/inc_functions.php");
require_once("../../../inc/inc_login.php");
global $userid;
if (isAuth($userid,2)) {
if (isset($_GET['id'])) {
$id = inCode($_GET['id']);
$row2 = $dblink->get_row("SELECT * FROM memht_banners_banner WHERE id='$id'");
$btipo = intval($row2['tipo']); //0=img,1=script
$bcontenuto = stripslashes($row2['contenuto']);
if ($btipo==0) {
echo "<img src='$bcontenuto' border='0'>";
} else {
echo $bcontenuto;
}
} else {
echo "Error!";
}
} else die("Access Denied!");
//===========================================
//Database: Disconnect
//===========================================
$dblink->disconnect();
?>
|