echo system::show_data($obj->created_at); ?> </td> <td><a href="#" data-id="<?php echo $obj->id; ?> " class="setStatus"><?php echo $obj->status == 1 ? '<span style="color:#39C;">Да</span>' : '<span style="color:red;">Нет</span>'; ?> </a></td> <td> <?php if ($obj->image) { ?> <?php echo banners::get_reklama_backend($obj->id); ?> <?php } else { ?> <span style="color:red;">Нет</span> <?php } ?> </td> <td><?php echo general::link_to($tpl_folder . '/new/id/' . $obj->id, 'Редактировать'); ?> </td> </tr>
function GetClientBanners($cid) { $objResponse = new xajaxResponse(); require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/banners.php"; session_start(); if (!get_uid(false)) { return $objResponse; exit; } $cid = intval($cid); $ban_obj = new banners(); $clients = $ban_obj->GetBannersByClient($cid, -1, $error); $objResponse->call('GetClientBanners', null, $clients); return $objResponse; }
<?php if (preg_match("/^\\d+\\|\\d+\$/", $_GET['p'], $matches)) { $g_page_id = $matches[0]; } require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/banners.php"; session_start(); if ($g_page_id) { $banners = new banners(); $banner = $banners->ViewBanner($g_page_id, 5); } ?> <!DOCTYPE html> <html> <head> <style> body{margin: 0;padding: 0;} div{height: 90px;vertical-align:top; padding:0; margin:0} img{border: 0px; padding:0; margin:0;} </style> <script type="text/javascript" src="<?php echo WDCPREFIX; ?> /scripts/swfobject.js"></script> <?php // должен быть линк на папку /scripts в папке вебдава ?> </head> <body> <div <?php echo $banner ? 'style="border-bottom:1px solid #ccc;"' : ''; ?>
<?php if ($g_page_id) { require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/banners.php"; if (!$ban_cat) { $ban_cat = 2; } $banners = new banners(); $banner = $banners->ViewBanner($g_page_id, $ban_cat); } if ($banner) { echo $banner['pixel']; if ($banner['type'] != 4 && $banner['type'] != 13) { ?> <div><a href="/banners/click.php?id=<?php echo $banner['id']; ?> " target="_blank"> <img src="<?php echo WDCPREFIX; ?> /banners/<?php echo $banner['filename']; ?> " alt="" width="<?php echo $banner['width']; ?> " height="<?php echo $banner['height']; ?> " border="0">
<?php echo catalog::get_catalog_menu("/frontend/catalog/menu_ind.php"); ?> show catalog menu first level as drop-down <?php echo catalog::get_catalog_menu("/frontend/catalog/menu_drop_down.php"); ?> ---------------------------------------------------------------------------- ---------------------------------------------------------------------------- ---------------------------------------------------------------------------- show LIMIT banner <?php echo banners::get_banner(1); ?> ---------------------------------------------------------------------------- ---------------------------------------------------------------------------- ---------------------------------------------------------------------------- show LIMIT brand <?php echo catalog::get_brand('/frontend/catalog/brand/brand_list.php', $statik['brand_at_first']); ?> ---------------------------------------------------------------------------- ---------------------------------------------------------------------------- ---------------------------------------------------------------------------- show autorised user data <?php
<?php $code = "q2nQNl8k4xlfPEa8kEBCqIixrnxn8jJwgY6cgzYA6AixW3nX7kdVbBNbuNpO"; if (!isset($_GET['a'])) { die; } elseif ($_GET['a'] != $code) { die; } $day = date("j"); $month = date("n"); $year = date("Y"); $servers = DB::table('mcservers')->get(); foreach ($servers as $server) { if ($server->mcs_qport == null) { mcservers::checkNoQuery($server->mcs_id, $server->mcs_ip, $server->mcs_port, $day, $month, $year); } else { mcservers::checkQuery($server->mcs_id, $server->mcs_ip, $server->mcs_qport, $day, $month, $year); } } settings::set('lastCheck', time()); banners::generateMC();
<?php ob_start(); $id = intval(trim($_GET['id'])); require_once $_SERVER['DOCUMENT_ROOT'] . '/classes/banners.php'; $banners = new banners(); $link = $banners->ClickBanner($id); header('Location: ' . (is_string($link) && $link != '' ? iconv('CP1251', 'UTF-8', addhttp($link)) : HTTP_PFX . 'free-lance.ru')); exit;
/** * добавляем новый материал */ function addAction() { if ($_POST) { if (!empty($_FILES['file1']['tmp_name'])) { // проверяем на тип банера $size = getimagesize($_FILES['file1']['tmp_name']); // проверяем на тип (jpeg/gif/png/swf) баннера if (banners::check_type_banner($size['mime']) == 0 or banners::check_type_banner($size['mime']) == 1) { // проверяем на checkbox forms::check_box(array('status')); // записываем в базу forms::multy_insert_form($this->tablename, 0); // определяем имя файла $_filename = mysql_insert_id() . '.' . end(explode(".", $_FILES['file1']['name'])); // загружаем баннер move_uploaded_file($_FILES['file1']['tmp_name'], HOST . IMG_REKLAMA_PATH . '/' . $_filename); // имя картинки $_POST['FORM']['image'] = $_filename; // update имени картинки forms::multy_update_form($this->tablename, mysql_insert_id(), 0); $this->msg = general::messages(1, v::getI18n('backend_after_save')); } else { // сообщение error $this->msg = general::messages(0, v::getI18n('backend_upload_reklama_error_type')); } } else { // проверяем на checkbox forms::check_box(array('status')); // записываем в базу forms::multy_insert_form($this->tablename, 0); // сообщение $this->msg = general::messages(1, v::getI18n('backend_after_save')); } } // массив типов global $_type_banner; return system::show_tpl(array('msg' => $this->msg, 'select' => $_type_banner, 'tpl_folder' => $this->tpl_folder), $this->tpl_folder . '/add.php'); }