Exemplo n.º 1
0
<?php

require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/stdf.php";
require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/banner_promo.php";
session_start();
$banner = intval($_GET['type']);
$bpromo = new banner_promo($_GET['type']);
if (intval($bpromo->info['id'])) {
    $bpromo->writeClickStat();
    header('Location: ' . $bpromo->info['banner_link']);
    exit;
} else {
    require_once "404.php";
    exit;
}
Exemplo n.º 2
0
<?php

define('IS_ACCESS_PAGE', 1);
require_once $_SERVER['DOCUMENT_ROOT'] . '/classes/stdf.php';
require_once $_SERVER['DOCUMENT_ROOT'] . '/classes/banner_promo.php';
session_start();
if (!get_uid(false)) {
    include '../403.php';
    exit;
}
//просмотр информации о статистике баннера
if (isset($_GET['type'])) {
    $type = __paramInit('int', 'type');
    $bpromo = new banner_promo();
    $access = $bpromo->isAccess($type);
    $type = $bpromo->setType(intval($type), true);
    if ($type > 0 && ($access || hasPermissions('advstat') || hasPermissions('adm'))) {
        $count = $bpromo->getCountStat();
        $stats = $bpromo->getStat();
        $banner = $bpromo->info;
        $content = 'inner_index.php';
    } else {
        include '../403.php';
        exit;
    }
} else {
    include '../403.php';
    exit;
}
$content = 'inner_index.php';
include $_SERVER['DOCUMENT_ROOT'] . '/template2.php';
Exemplo n.º 3
0
<?php

$date = date("Ymd");
$banner_promo_show = false;
require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/banner_promo.php";
require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/kwords.php";
$ban_promo = new banner_promo();
$ban_promo->setType($ban_promo->getActiveBanner(), 1);
if (($no_banner != 1 || $no_banner != true) && $date >= date('Ymd', strtotime($ban_promo->info['from_date'])) && $date <= date('Ymd', strtotime($ban_promo->info['to_date']))) {
    $banner_promo_show = false;
    $banner_promo_type_ban = $ban_promo->info['type_ban'];
    $banner_promo_img = $ban_promo->info['name_img'];
    $banner_promo_code = $ban_promo->info['code_text'];
    $banner_promo_image_style = $ban_promo->info['img_style'] != "" ? 'style="' . $ban_promo->info['img_style'] . '"' : '';
    $banner_promo_title = htmlspecialchars(stripslashes($ban_promo->info['img_title']));
    $banner_promo_text = htmlspecialchars(stripslashes($ban_promo->info['linktext']));
    $banner_promo_link_style = htmlspecialchars(stripslashes($ban_promo->info['link_style']));
    $banner_promo_type = intval($ban_promo->info['id']);
    $banner_link = $ban_promo->info['banner_link'];
    $ban_promo->writeViewStat();
    if ($ban_promo->info['page_target'] == '0|0' || $ban_promo->info['page_target'] == $g_page_id) {
        $banner_promo_show = true;
    }
}
// Типовые услуги - главная страница для неавторизованных и заказчиков
if (get_uid(false) == 0 || is_emp()) {
    $projects_url = '/projects/';
    $projects_active = $grey_main && $kind != 8 && $kind != 2;
    $tservice_url = '/';
    $tservice_active = $_SERVER['REQUEST_URI'] == '/' || preg_match("#^/tu/#", $_SERVER["REQUEST_URI"], $m);
} else {
Exemplo n.º 4
0
<?php

if (!defined('IN_STDF')) {
    header("HTTP/1.0 404 Not Found");
    exit;
}
$date = date("Ymd");
$banner_promo_show = false;
require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/banner_promo.php";
require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/kwords.php";
$ban_promo = new banner_promo();
//$ban_promo->setType($ban_promo->getActiveBanner(), 1);
$ban_promo->setTypeByPage($g_page_id);
if (($no_banner != 1 || $no_banner != true) && $date >= date('Ymd', strtotime($ban_promo->info['from_date'])) && $date <= date('Ymd', strtotime($ban_promo->info['to_date']))) {
    $banner_promo_show = false;
    $banner_promo_type_ban = $ban_promo->info['type_ban'];
    $banner_promo_img = $ban_promo->info['name_img'];
    $banner_promo_code = $ban_promo->info['code_text'];
    $banner_promo_image_style = $ban_promo->info['img_style'] != "" ? 'style="' . $ban_promo->info['img_style'] . '"' : '';
    $banner_promo_title = htmlspecialchars(stripslashes($ban_promo->info['img_title']));
    $banner_promo_text = htmlspecialchars(stripslashes($ban_promo->info['linktext']));
    $banner_promo_link_style = htmlspecialchars(stripslashes($ban_promo->info['link_style']));
    $banner_promo_type = intval($ban_promo->info['id']);
    $banner_link = $ban_promo->info['banner_link'];
    $ban_promo->writeViewStat();
    if ($ban_promo->info['page_target'] == '0|0' || $ban_promo->info['page_target'] == $g_page_id) {
        $banner_promo_show = true;
    }
}
$banner_promo_class = 'b-menu__banner b-menu__banner_ln1';
if ($banner_promo_inline) {
Exemplo n.º 5
0
}
$bpromo = new banner_promo();
$inner_page = "inner_menu.php";
$css_file = array('payed.css', 'moderation.css', 'nav.css', 'calendar.css');
$js_file = array('calendar.js');
//просмотр информации о статистике баннера
if (isset($_GET['type'])) {
    $type = $bpromo->setType(intval($_GET['type']), true);
    if ($type > 0) {
        $inner_page = "inner_index.php";
    } else {
        include "../../404.php";
        exit;
    }
} else {
    $bpromo = new banner_promo();
    $banners = $bpromo->getInfoBanners();
}
//редактирование
if (isset($_GET['edit'])) {
    $edit = intval($_GET['edit']);
    $bpromo->setType($edit, true);
    $advChecked = '';
    $activeChecked = '';
    if ($bpromo->info['advertising'] == 't') {
        $advChecked = 'checked="checked"';
    }
    if ($bpromo->info['is_activity'] == 't') {
        $activeChecked = 'checked="checked"';
    }
    if ($bpromo->info['is_pro'][0] == '1') {