Beispiel #1
0
function get_guest($myid)
{
    $myinfo = get_row('gid', 'zx_guest', 'wgid=' . $myid);
    $ip = GetIP();
    $browser = get_userAgent($_SERVER['HTTP_USER_AGENT']);
    $time = time();
    if (empty($myinfo)) {
        $result = get_insert('zx_guest', 'wgid,logins,last,lastip,browser', "'{$myid}',1,{$time},'{$ip}','{$browser}'");
    } else {
        $result = get_update('zx_guest', "last={$time},lastip='{$ip}',browser='{$browser}',logins=logins+1", 'wgid=' . $myid);
    }
    $myinfo = get_row('*', 'zx_guest', 'wgid=' . $myid);
    return $myinfo;
}
Beispiel #2
0
                echo '<span>Page ' . $pagination['page'] . ' / ' . $pagination['pages'] . '</span>';
                echo '</div>';
            }
        } else {
            echo '<div style="text-align:center; margin-top: 20px;">On the wall appear only products from your favorite stores/brands. <br />
  <a href="' . tlink('stores') . '" class="nice_a">Choose from the list</a></div>';
        }
    } else {
        $pagination = have_wall(array('firstchar' => isset($_GET['firstchar']) ? $_GET['firstchar'] : ''));
        echo '<div class="title">My Wall <span style="float: right;">' . ($pagination['results'] ? $pagination['results'] . ' ' . (is_first($pagination['results']) ? 'coupon' : 'coupons') : 'Nothing found yet') . '</span></div>';
        echo '<div style="margin-bottom: 20px;">

<ul class="category">
<li class="active">Coupons</li>';
        if (theme_has_products()) {
            echo '<li><a href="' . get_update(array('type' => 'products', 'page' => 1)) . '">Products</a></li>';
        }
        echo '</ul>

</div>';
        if ($pagination['results']) {
            foreach (wall(array('firstchar' => isset($_GET['firstchar']) ? $_GET['firstchar'] : '')) as $item) {
                echo '<article class="array_item">

<div class="table">

<div class="left">
<img src="' . store_avatar($item->store_img) . '" alt="">
<span class="rating"><span style="width:' . $item->stars * 16 . 'px;"></span></span>
<a href="' . $item->store_reviews_link . '">' . $item->reviews . ' reviews</a>';
                echo !empty($item->cashback) ? '<span class="cashback-points" data-ttip="Great! Use it and you\'ll receive ' . $item->cashback . ' points.">' . $item->cashback . '</span> ' : '';
<?php 
require_once "./Base.php";
ob_implicit_flush(true);
echo "微信企业号平台wiki更新检测:<br>";
$ret = get_update(SESSION_QY, WORK_LOCK_QY, BASE_URL_QY, WIKI_DIR_QY, MAIL_LOCK_QY, REMOTE_GIT_QY ? REMOTE_GIT_QY : REMOTE_GIT, REMOTE_GIT_QY ? '' : SESSION_QY);
//如果没有设置独立git库,则使用共用git库,同时使用独立分支进行提交
if ($ret) {
    echo "<br>已更新,将尝试发送通知邮件.<br>";
    send_mail(WIKI_DIR_QY, MAIL_LOCK_QY, "监测通知:微信企业号平台WIKI更新");
}
<?php 
require_once "./Base.php";
ob_implicit_flush(true);
echo "微信公众号平台wiki更新检测:<br>";
$ret = get_update(SESSION_MP, WORK_LOCK_MP, BASE_URL_MP, WIKI_DIR_MP, MAIL_LOCK_MP, REMOTE_GIT_MP ? REMOTE_GIT_MP : REMOTE_GIT, REMOTE_GIT_MP ? '' : SESSION_MP);
//如果没有设置独立git库,则使用共用git库,同时使用独立分支进行提交
if ($ret) {
    echo "<br>已更新,将尝试发送通知邮件.<br>";
    send_mail(WIKI_DIR_MP, MAIL_LOCK_MP, "监测通知:微信公众平台WIKI更新");
}
function show_pro_form($con, $error = "")
{
    ?>

<div class="row">

<div class="large-6 large-centered columns">

<div class="proced" style="color:white; font-size:50px; text-align:center; 
font-weight: bold; border-style: solid;  border-width: medium;">
<?php 
    get_update($con);
    ?>
</div>
<form style="padding-top:80px;" method="POST" action="procedures.php">
		Procedure: <input type="text" name="pname" placeholder="Procedure"><br>
		<br><button type="submit" name="submit">Add Procedure</button>
	</form>
		</div>
		</div>
	

 <?php 
}
Beispiel #6
0
<div class="table">

<div class="left">
<img src="' . product_avatar($item->image) . '" alt="">
<span class="rating"><span style="width:' . $item->stars * 16 . 'px;"></span></span>
<a href="' . $item->store_reviews_link . '">' . $item->reviews . ' reviews</a>';
    echo !empty($item->cashback) ? '<span class="cashback-points" data-ttip="Great! Purchase this product and you\'ll receive ' . $item->cashback . ' points.">' . $item->cashback . '</span> ' : '';
    echo '</div>

<div class="right">
<a href="' . $item->link . '" class="title">' . $item->title . '</a>';
    if (!empty($item->price)) {
        echo '<div class="price_info">Price: <span class="price">' . (empty($item->old_price) ? '' : '<span>' . price_format($item->old_price) . '</span>') . price_format($item->price) . ' ' . $item->currency . '</span></div>';
    }
    echo 'More products for <a href="' . get_update(array('type' => 'products'), $item->store_link) . '">' . $item->store_name . '</a>
<div class="description">' . (!empty($item->description) ? nl2br($item->description) : 'no description') . '</div>

<ul class="details">
<li>Coupon Added: <b>' . timeago(strtotime($item->date), 'seconds') . ' ago</b></li>';
    if ($item->is_expired) {
        echo '<li>Expired on: <span class="expired">' . date('m/d/y', strtotime($item->expiration_date)) . '</span></li>';
    } else {
        if (!$item->is_started) {
            echo '<li>Starts on: <span class="notstarted">' . date('m/d/y', strtotime($item->expiration_date)) . '</span></li>';
        } else {
            echo '<li>Expiration: <span class="active">' . date('m/d/y', strtotime($item->expiration_date)) . '</span></li>';
        }
    }
    echo '</ul>
Beispiel #7
0
<?php

require 'lib/database.php';
require 'lib/misc.php';
require 'lib/authentication.php';
redirect_if_not_logged_in("login.php");
$updates = get_update();
if (isset($_POST['updates'])) {
    if (!isset($_FILES['pdf']) || !file_exists($_FILES['pdf']['tmp_name']) || !is_uploaded_file($_FILES['pdf']['tmp_name'])) {
        update_updates(stripslashes($_POST['description']));
    } else {
        $info = pathinfo($_FILES['pdf']['name']);
        $ext = $info['extension'];
        // get the extension of the file
        $newname = "updates." . $ext;
        $target = 'pdfs/' . $newname;
        move_uploaded_file($_FILES['pdf']['tmp_name'], $target);
        update_updates(stripslashes($_POST['description']), $target);
    }
}
?>

<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Edge CMS</title>

    <!-- Bootstrap -->