Пример #1
0
function getname($supercode, $mysqli)
{
    $fullname = '';
    $sql = "select * from channel where code='{$supercode}'";
    $res = $mysqli->query($sql);
    $row = $res->fetch_assoc();
    $fullname .= $row['cname'] . ",";
    if ($row['code'] != $row['supercode']) {
        getname($row['supercode'], $mysqli);
    }
    return $fullname;
}
Пример #2
0
            return stripslashes($matches[1][0]);
        }
    }
}
if (isset($_POST["file"])) {
    $result = '';
    if ($config['total'] != 0) {
        $used = $db->ExecuteSQL(sprintf('SELECT SUM(`size`) AS `sum` FROM `file` WHERE `owner` = \'%s\' AND `recycle` = \'0\'', $db->SecureData($_SESSION["username"])));
        if ($used[0]['sum'] >= $config["total"] * 1000 * 1000) {
            $result = "totalout";
        }
    }
    $file = @file_get_contents($_POST["file"]);
    $header = @get_headers($_POST["file"], 1);
    if ($file !== false && stripos($header[0], '200') !== false) {
        $name = getname($_POST["file"]);
        if (strlen($file) == 0) {
            // 只有當無法正常偵測大小時才使用 header ,因為header可能被偽造
            $size = $header["Content-Length"];
        } else {
            $size = strlen($file);
        }
        if ($config['size'] != 0) {
            if ($size > $config["size"] * 1000 * 1000) {
                $result = "sizeout";
            }
        }
        /* Create Key */
        $passphrase['a'] = sha1(md5(mt_rand() . uniqid()));
        $passphrase['b'] = $_SESSION['password'];
        $iv = substr(md5("<X" . $passphrase['b'], true), 0, 8);
Пример #3
0
<div class="panel panel-primary">
	<div class="panel-heading" style="background: #56892E;">
		<h3 class="panel-title" align="center">QQ查询</h3>
	</div>
	<ul align="center" class="list-group" style="list-style:none;">
		<li class="list-group-item">
    <form action="index.php" method="get"><input type="hidden" name="mod" value="wall">
    请输入要查询的QQ号码:<input type="text" class="form-control" name="q"><br><input type="submit" class="btn btn-primary btn-block" value="查询">
    </form>
<br>
	</ul>
</div>
';
} else {
    $q = $_GET['q'];
    $name = getname($q);
    //$panduan=qqpanduan($q);
    echo '
<div class="panel panel-primary" style="max-width:680px;">
	<div class="panel-heading" style="background: #56892E;">
		<h3 class="panel-title" align="center">' . $name . '的信息</h3>
	</div>
	<ul align="center" class="list-group" style="list-style:none;">
		<li class="list-group-item"><b><font color=green>QQ:' . $q . '</b></font><li>
		<li class="list-group-item"><b><font color=bule>昵称:' . $name . '</b></font><li>
		<li class="list-group-item"><b><font color=red>状态:<img src="http://wpa.qq.com/pa?p=9:' . $q . ':5"></b></font><li>
		<li class="list-group-item"><img src="http://q1.qlogo.cn/g?b=qq&nk=' . $q . '&s=100&t=' . time() . '"><li>
		<li class="list-group-item"><img src="http://qqshow-user.tencent.com/' . $q . '/22/00/1.gif?fr=mobileqq"><li>
		<li class="list-group-item"><a class="btn btn-s-md btn-info btn-rounded btn-block" value="发送消息" target="_blank" href="http://wpa.qq.com/msgrd?v=3&amp;uin=' . $q . '&amp;site=qq&amp;menu=yes">发送消息</a><li>
		<li class="list-group-item"><a class="btn btn-s-md btn-info btn-rounded btn-block" value="加为好友" target="_blank" href="tencent://AddContact/?fromId=45&fromSubId=1&subcmd=all&uin=' . $q . '&website">加为好友</a><li>
		<li class="list-group-item"><a class="btn btn-s-md btn-primary btn-rounded btn-block" value="浏览QQ空间" target="_blank" href="http://user.qzone.qq.com/' . $q . '">浏览QQ空间</a><li>
Пример #4
0
    } else {
        $ggcon = 'document.write(unescape("' . $ggdm . '"));';
    }
    $ggcon1 = '<?php exit();?>' . "\r\n" . $ggtitle . "\r\n" . $ggdm . "\r\n" . $ggclass . "\r\n" . $ggwidth . "\r\n" . $ggheight . "\r\n" . gnt() . "\r\n" . $ggzu . "\r\n" . $ggtj . "\r\n" . $ggjfclass . "\r\n" . $gglei;
    file_put_contents($path, $ggcon) or die('出错啦!无法创建.js文件!请将程序目录和所有文件的文件权限设置属性0755或0777。');
    file_put_contents($path1, $ggcon1) or die('出错啦!无法创建.php文件!请将程序目录和所有文件的文件权限设置属性0755或0777。');
    $gglist = file($path2);
    if (!is_array($gglist)) {
        $gglist[] = '';
    }
    array_shift($gglist);
    array_unshift($gglist, $thread . '-' . $ontid . "\r\n");
    array_unshift($gglist, '<?php exit();?>' . "\r\n");
    file_put_contents($path2, $gglist) or die('出错啦!无法创建.php文件!请将程序目录和所有文件的文件权限设置属性0755或0777。');
    $conn = new mysql();
    $conn->inoplog('添加广告', $ontid, 1, getname());
    die('1');
}
///////////////////////////
$ggiftj = $_COOKIE['ggiftj'];
$gglei = unescape($_COOKIE['gglei']);
$ggzu = unescape($_COOKIE['ggzu']);
$ggleil = file_get_contents($datadir . '/ggleilist.php');
$ggll = explode("\r\n", $ggleil);
array_shift($ggll);
$ggleilist = '';
foreach ($ggll as $value) {
    if ($value) {
        if ($value == $gglei) {
            $ggleilist .= '<option value="' . htmlspecialchars($value) . '" title="' . htmlspecialchars($value) . '" selected="selected">' . htmlspecialchars(cutstr($value, 10)) . '</option>';
        } else {
Пример #5
0
            $content1 = str_replace($gid . "\r\n", '', $content1);
            $content .= $gid . "\r\n";
        }
    }
    file_put_contents($file, $content);
    file_put_contents($file1, $content1);
    $conn->inoplog('还原广告位', $gids, 1, getname());
    die('1');
}
///////////////////////////
if ($menu == 'delggwtrue') {
    if (!$gids) {
        die('出错啦!gids为空!你让我删谁?');
    }
    $arraygid = explode(' ', $gids);
    $file = $datadir . '/ggwrecyclelist.php';
    $content = file_get_contents($file);
    foreach ($arraygid as $gid) {
        if (strlen($gid) == strlen($ggwthread) + 15) {
            $path = $datadir . '/' . $gid . '.jsrecycle';
            $path1 = $datadir . '/' . $gid . '.phprecycle';
            unlink($path) or die($gid . '删除错误!');
            unlink($path1) or die($gid . '删除错误!');
            $content = str_replace($gid . "\r\n", '', $content);
        }
    }
    file_put_contents($file, $content);
    $conn->inoplog('彻底删除广告位', $gids, 1, getname());
    die('1');
}
///////////////////////////
    $ggwlei = insql($_POST['ggwlei']);
    $ggwzu = insql($_POST['ggwzu']);
    $gid = insql($_POST['gid']);
    $gtime = insql($_POST['gtime']);
    if (!$ggwtitle) {
        die('标题不能为空!');
    }
    require 'func.gg.php';
    $path = $datadir . '/' . $gid . '.js';
    $path1 = $datadir . '/' . $gid . '.php';
    $ggwcon = ggwtojs($gid, $xzggcl, $ggwwidth, $ggwheight, $bjgg, $ggwclass);
    $ggwcon1 = '<?php exit();?>' . "\r\n" . $gtime . "\r\n" . $ggwtitle . "\r\n" . $ggwclass . "\r\n" . $ggwwidth . "\r\n" . $ggwheight . "\r\n" . $xzggcl . "\r\n" . $bjgg . "\r\n" . $ggwzu . "\r\n" . $ggwlei;
    file_put_contents($path, $ggwcon) or die('出错啦!无法创建.js文件!请将程序目录和所有文件的文件权限设置属性0755或0777。');
    file_put_contents($path1, $ggwcon1) or die('出错啦!无法创建.php文件!请将程序目录和所有文件的文件权限设置属性0755或0777。');
    $conn = new mysql();
    $conn->inoplog('修改广告位', $gid, 1, getname());
    die('1');
}
///////////////////////////
$ggwleil = file_get_contents($datadir . '/ggwleilist.php');
$ggwll = explode("\r\n", $ggwleil);
array_shift($ggwll);
$ggwleilist = '';
foreach ($ggwll as $value) {
    if ($value) {
        if ($value == $arrayd[8]) {
            $ggwleilist .= '<option value="' . htmlspecialchars($value) . '" title="' . htmlspecialchars($value) . '" selected="selected">' . htmlspecialchars(cutstr($value, 10)) . '</option>';
        } else {
            $ggwleilist .= '<option value="' . htmlspecialchars($value) . '" title="' . htmlspecialchars($value) . '">' . htmlspecialchars(cutstr($value, 10)) . '</option>';
        }
    }
Пример #7
0
#   copyright-notice must be displayed on the website   #
#              where this script is used.               #
#                                                       #
#    See readme.htm for further copyright information   #
#     IF YOU USE THIS SCRIPT, YOU ACCEPT THESE TERMS    #
#########################################################
#########################################
#               DETAILS                 #
#########################################
if ($_GET['pn_go'] == 'details') {
    /* Ausgabe des betreffenden Newseintrags */
    for ($i = 0; $i < $zeilen; $i++) {
        $eintrag = explode('§', $zeile[$i]);
        if ($eintrag[0] == $_GET['id']) {
            $datum = formatdate($eintrag[6], $dateformat);
            $eintrag[1] = getname($eintrag[1], 'news/inc/pn_userdata.php');
            $eintrag[2] = formattext($eintrag[2], $smilies, $smiliespath, $myBoardCodeTags, $texthtml);
            $eintrag[3] = formattext($eintrag[3], $smilies, $smiliespath, $myBoardCodeTags, $texthtml);
            if ($eintrag[4] != '') {
                $eintrag[4] = formattext($eintrag[4], $smilies, $smiliespath, $myBoardCodeTags, $texthtml);
                $eintrag[3] = $eintrag[3] . '<br /><br /><b>More:</b><br />' . $eintrag[4];
            }
            /* Kategorie-System */
            if ($showcat == 'yes') {
                $eintrag[5] = getcat($eintrag[5], 'news/inc/pn_categories.dat', 'catpics', $catpics);
            } else {
                $eintrag[5] = '';
            }
            /* ---------------- */
            $commentscount = commentscount($eintrag[0]);
            $comments = '<a href="' . $_SERVER['PHP_SELF'] . '?pn_go=details&id=' . $eintrag[0] . $params . '">Comments (' . $commentscount . ')</a>';
Пример #8
0
/**
 * Function used to check weather give thumb is deafult or not
 */
function is_default_thumb($i)
{
    if (getname($i) == 'processing.jpg') {
        return true;
    } else {
        return false;
    }
}
    $focontent = file($fofile);
    array_shift($focontent);
    $focontent[] = $foname . ' ' . $fourl . "\r\n";
    array_unshift($focontent, '<?php exit();?>' . "\r\n");
    file_put_contents($fofile, $focontent) or die($fofile . ' 禁止写入!');
    die('1');
} elseif ($menu == 'editfo') {
    $oldfo = insql($_REQUEST['oldfo']);
    $newfoname = insql($_REQUEST['newfoname']);
    $newfourl = insql($_REQUEST['newfourl']);
    $fofile = $datadir . '/fo.' . md5(getname()) . '.php';
    $focontent = file($fofile);
    array_shift($focontent);
    $folist = '<?php exit();?>' . "\r\n";
    foreach ($focontent as $value) {
        $foarray = explode(' ', $value);
        if ($foarray[0] == $oldfo) {
            $folist .= $newfoname . ' ' . $newfourl . "\r\n";
        } else {
            $folist .= $value;
        }
    }
    file_put_contents($fofile, $folist) or die($fofile . ' 禁止写入!');
    die('1');
} elseif ($menu == 'delfo') {
    $fov = insql($_REQUEST['fov']);
    $fofile = $datadir . '/fo.' . md5(getname()) . '.php';
    $folist = '<?php exit();?>' . "\r\n" . $fov;
    file_put_contents($fofile, $folist) or die($fofile . ' 禁止写入!');
    die('1');
}
Пример #10
0
    $yhznr = '<?php exit();?>' . "\r\n" . $yhzname . "\r\n" . $funcselect;
    file_put_contents($rankfile, $yhznr) or die('出错啦!' . $rankfile . ' 无法修改!请将程序目录和文件的文件权限设置属性0755或0777。');
    $conn = new mysql();
    $conn->inoplog('修改用户组', $rank, 1, getname());
    die('1');
    /////////////////////
} elseif ($_REQUEST['menu'] == 'delyhz') {
    /////////////////////
    $rank = htmlspecialchars(insql($_REQUEST['rank']));
    $rankfile = $datadir . '/access/' . $rank . '.access.php';
    if (!is_file($rankfile)) {
        die('用户组 ' . $rank . ' 不存在,删除失败!');
    }
    unlink($rankfile) or die('出错啦!' . $rankfile . ' 无法删除!请将程序目录和文件的文件权限设置属性0755或0777。');
    $conn = new mysql();
    $conn->inoplog('删除用户组', $rank, 1, getname());
    die('1');
    /////////////////////
} else {
    /////////////////////
    $subadminlist = '';
    foreach ($subadmin as $key => $value) {
        $accessdata = file($datadir . '/access/' . $value[1] . '.access.php');
        array_shift($accessdata);
        $zuname = htmlspecialchars(rtrim(array_shift($accessdata)));
        $subadminlist .= '<tr class="list">';
        $subadminlist .= '<td class="ui-widget-content uitd ct">' . htmlspecialchars($key) . '</td>';
        $subadminlist .= '<td class="ui-widget-content uitd ct">' . $zuname . '</td>';
        $subadminlist .= '<td class="ui-widget-content uitd ct"><button type="button" class="button editsa" value="' . htmlspecialchars($value[1]) . '" title="修改此管理员属性" />修改</button> <button type="button" class="button delsa" value="' . htmlspecialchars($key) . '" title="删除此管理员" />删除</button></td>';
        $subadminlist .= '</tr>';
    }
Пример #11
0
    } else {
        ?>
							<div class="msgbox1">
								<img src="images/alert.png" style="height: 50px;float: left; margin-right:1%;"/><br/><?php 
        echo $msg;
        ?>
							</div>
				<?php 
    }
}
$qisco = $db->prepare('select * from `collaborate_request` where `user`=? and `status`=?');
$qisco->execute(array($id, 0));
$risco_count = $qisco->rowCount();
$risco = $qisco->fetch();
if ($risco_count > 0) {
    $ow = getname($risco['owner']);
    ?>
				<div class="msgbox">
								<img src="images/message.png" style="height: 50px;float: left; margin-right:1%;"/><br/><?php 
    echo $ow;
    ?>
 has invited you to join his account. Please accept this request to start collaborating.
								<br/>
								<input type="button" class="viewbutton2" value="Accept" style="background:#2e7317;" onclick="acceptrequest(<?php 
    echo $risco['id'];
    ?>
);"/> &nbsp; &nbsp; <input type="button" class="viewbutton2" value="Reject" style="background: rgb(230, 129, 162);" onclick="rejectrequest(<?php 
    echo $risco['id'];
    ?>
);"/>
				</div>
Пример #12
0
                'echarts/chart/k',
				'echarts/chart/line',
				'echarts/chart/bar'     
            ],			
        function (ec) {
                
            var myChart1 = ec.init(document.getElementById('main'));
            var myChart2 = ec.init(document.getElementById('main2'));
            var myChart3 = ec.init(document.getElementById('main3'));
            var myChart4 = ec.init(document.getElementById('main4'));
          
            //呈現股價、MA線*3
            option1 = {
                title : {
                    text: <?php 
getname($Stockvisble);
?>
                },
                tooltip : {
                    trigger: 'axis',
                    showDelay: 0,
                    formatter: function (params) {
                            var res = params[0].name;
                            for (var i = params.length - 1; i >= 0; i--) {
                                if (params[i].value instanceof Array) {
                                    res += '<br/>' + params[i].seriesName;
                                    res += '<br/>開盤 : ' + params[i].value[0] + '  最高: ' + params[i].value[3];
                                    res += '<br/>收盤 : ' + params[i].value[1] + '  最低 : ' + params[i].value[2];
                                }
                                else
                                {
Пример #13
0
   </div>
   <div class="panel-body"><h4>
<?php 
echo handlestr($sub['forum_content']);
?>
</h4>
   </div>
</div>
   <?php 
if (isset($res) && $res != null) {
    ?>
   <?php 
    for ($i = 0; $i < count($res); ++$i) {
        ?>
   <span class="label label-primary"><?php 
        echo getname($i + 1);
        ?>
</span>
   <div name="<?php 
        echo $res[$i]['thread_id'];
        ?>
" class="panel panel-default">

   <div class="panel-body"><h4>
<?php 
        echo handlestr($res[$i]['thread_content']);
        ?>
</h4>
   </div>
   <div class="panel-footer pull-right">
   <?php 
Пример #14
0
images/no-photo.png'">
								<div><?php 
                echo $employee["name"] . ' ' . $employee["Sname"];
                ?>
<div class="small"><?php 
                echo $employee["DirectorateInitials"];
                ?>
</div></div>
							</div>
							<div class="content-nominate">
								<p>Belief: <?php 
                echo $employee["BeliefID"];
                ?>
</p>
								<p>Nominated By:<br><b><?php 
                echo getname($employee["NominatorEmpNum"]);
                ?>
</b></p>
							</div>
							<span id="wall<?php 
                echo $employee["ID"];
                ?>
Text" class="showbehaviour hidden mCustomScrollbar height260" data-mcs-theme="dark-2">
								<?php 
                echo $employee["personalMessage"];
                ?>
							</span>
						</div>
					</div>
				<?php 
            }
////////////////////////////
if ($menu == 'deluploadfile') {
    $fids = insql($_POST['fids']);
    if (!$fids) {
        die('出错啦!目标为空!你让我删谁?');
    }
    $dir = $datadir . '/updata/';
    $arrayfid = explode(' ', $fids);
    foreach ($arrayfid as $fid) {
        $fidclass = explode('.', $fid);
        if (is_numeric($fidclass[0]) && strlen($fidclass[0]) == 14) {
            unlink($dir . $fid) or die($fid . "删除错误!请确认属性是否设置正确!");
        }
    }
    $conn = new mysql();
    $conn->inoplog('删除上传广告文件', $fids, 1, getname());
    die('1');
}
////////////////////////////
$desc = insql($_REQUEST['desc']);
$limit = insql($_REQUEST['limit']);
$page = insql($_REQUEST['page']);
$desc = $desc ? '' : 'DESC';
$limit = is_numeric($limit) && $limit > 1 ? $limit : 30;
$page = is_numeric($page) && $page > 1 ? $page : 1;
$upath = $datadir . '/updata';
$upurl = $amsurl . $upath;
$files = getfiles($upath);
if ($desc) {
    rsort($files);
} else {
Пример #16
0
    //delete_from_activity_action_posted($activity_posted_info[0][1]); //mno
    delete_from_activity_action_posted($activity_posted_info[0][4]);
    //plno
    delete_from_postedlooks($activity_posted_info[0][4]);
    //plno
    delete_from_postlook_a_look_folder($_POST['img']);
    //delete in image folder
}
$activity_posted = select('activity', 6, array('action', 'Posted'), 'order by _table_id desc', array($start, $limit));
// for ($i=0; $i < count($activity_posted); $i++) {
// 	echo $activity_posted[$i][4]."<br>";
// }
// echo "total result is = ".count($activity_posted)."<br>";
for ($i = 0; $i < count($activity_posted); $i++) {
    $i1 = $i + 1;
    echo "\n\t\t\t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t\t<img title='Owner: " . getname($activity_posted[$i][4]) . " , Posted on: " . $activity_posted[$i][5] . "' class='img' src='../images/members/posted looks/" . $activity_posted[$i][4] . ".jpg'>\n\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t<table border=0>\n\t\t\t\t\t\t\t\t\t\t\t\t<td>\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t<form onsubmit=\"return deletes('" . getname($activity_posted[$i][4]) . "')\" method='POST' >\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t<input style='display:none' type='text' name='img' value='" . $activity_posted[$i][4] . "'>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t<input class='delete' title='Do you want to delete this look?' type = 'submit' value='delete' />\n\t\t\t\t\t\t\t\t\t\t\t\t\t</form>\n\t\t\t\t\t\t\t\t\t\t\t\t</td><td><p class=desc>Owner: " . getname($activity_posted[$i][4]) . " <br>Posted on: " . $activity_posted[$i][5] . "</p></td>\n\t\t\t\t\t\t\t\t\t\t\t\t";
    echo "\n\t\t\t\t\t\t\t\t\t\t\t</table>\n\t\t\t\t\t\t\t\t\t\t</td>\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t ";
    if ($i1 % 5 == 0) {
        echo "<tr>";
    }
}
/*
	function getname($plno){ 
								 
		$activity_posted_info=select_w_2('activity',6,array('action','Posted','_table_id',$plno),'and');
		// print_r($activity_posted_info);
		// return $fullname;
		$fs_members_info =select('fs_members',5,array('mno',$activity_posted_info[0][1]));
		// print_r($fs_members_info);
		return $fs_members_info[0][3].' '.$fs_members_info[0][1];
		
function getdata($year, $month, $agentids)
{
    $agentid = explode("|", $agentids);
    $maxdays = $_GET["maxdays"];
    $firstday = date("w", mktime(0, 0, 0, $month, 1, $year));
    $mysqli = new mysqli(DBSERVER, DBUSER, DBPWD, DB);
    ////set the query
    $arr = array();
    foreach ($agentid as &$id) {
        for ($i = 1; $i <= 31; $i++) {
            $arr["ha_" . $id . "_" . $i] = "";
        }
        for ($i = 1; $i <= 31; $i++) {
            $arr["hd_" . $id . "_" . $i] = "";
        }
    }
    foreach ($agentid as &$id) {
        $query = sprintf("SELECT * FROM `presence` WHERE `year`='%s' AND `month`='%s' AND `agentid`='%s' ORDER BY `type`,`agentid`,ABS(`day`)", $year, $month, $id);
        $result = $mysqli->query($query);
        if ($result) {
            while ($row = $result->fetch_object()) {
                $idtag = $row->type . "_" . $row->agentid . "_" . $row->day;
                $arr[$idtag] = $row->value;
                //$xml .= "<data idtag='$idtag'>".$row->value."</data>";
            }
        } else {
            echo $mysqli->error;
        }
        $result->close();
    }
    $mysqli->close();
    //print_r($arr);
    foreach ($agentid as &$id) {
        $j = $firstday;
        $tt = $_GET[$id];
        $ar_agent = getname($id);
        $output .= "<Row ss:AutoFitHeight=\"0\" ss:Height=\"29.988\"><Cell ss:StyleID=\"ce7\"><Data ss:Type=\"String\">" . $ar_agent[0] . "</Data></Cell><Cell ss:StyleID=\"ce19\"><Data ss:Type=\"String\">HA</Data></Cell>";
        for ($i = 1; $i <= $maxdays; $i++) {
            if ($j == 0 || $j == 6) {
                $style = "ce6";
            } else {
                $style = "ce28";
            }
            $output .= "<Cell ss:StyleID=\"{$style}\" id=\"ha_" . $id . "_" . $i . "\"><Data ss:Type=\"String\">" . $arr["ha_" . $id . "_" . $i] . "</Data></Cell>";
            if ($j == 6) {
                $j = 0;
            } else {
                $j++;
            }
        }
        $output .= "<Cell ss:StyleID=\"ce51\" ss:MergeDown=\"1\"><Data ss:Type=\"String\">{$tt}</Data></Cell><Cell ss:StyleID=\"ce58\" ss:MergeDown=\"1\" /><Cell ss:StyleID=\"ce58\" ss:MergeDown=\"1\" /></Row>";
        $output .= "<Row ss:AutoFitHeight=\"0\" ss:Height=\"29.988\"><Cell ss:StyleID=\"ce8\"><Data ss:Type=\"String\">" . $ar_agent[1] . "</Data></Cell><Cell ss:StyleID=\"ce19\"><Data ss:Type=\"String\">HD</Data></Cell>";
        $j = $firstday;
        for ($i = 1; $i <= $maxdays; $i++) {
            if ($j == 0 || $j == 6) {
                $style = "ce6";
            } else {
                $style = "ce28";
            }
            $output .= "<Cell ss:StyleID=\"{$style}\" id=\"hd_" . $id . "_" . $i . "\"><Data ss:Type=\"String\">" . $arr["hd_" . $id . "_" . $i] . "</Data></Cell>";
            if ($j == 6) {
                $j = 0;
            } else {
                $j++;
            }
        }
        $output .= "</Row>";
    }
    return $output;
}
Пример #18
0
                                             while ($row1 = mysql_fetch_assoc($query1)) {
                                                 $arr = array("label" => $row1['name'], "id" => $row1['id'], "name" => $row1['name'], "type" => $row1['type']);
                                                 array_push($reply, $arr);
                                             }
                                         } else {
                                             if ($type == "solution") {
                                                 $type1 = get_type_id($type);
                                                 $sql1 = "SELECT * FROM pkn_name WHERE (type='{$type1}' AND name LIKE '{$term}') ORDER BY name ASC";
                                                 // lay id name
                                                 $query1 = mysql_query($sql1);
                                                 while ($row1 = mysql_fetch_assoc($query1)) {
                                                     $sql2 = "SELECT * FROM {$table} WHERE name = '{$row1['id']}'";
                                                     // lay id name
                                                     $query2 = mysql_query($sql2);
                                                     while ($row2 = mysql_fetch_assoc($query2)) {
                                                         $arr = array("label" => getname($row2['name']), "id" => $row2['id'], "name" => getname($row2['name']), "units" => get_formula_units($row2['id']), "unitsname" => get_obj_name("pkn_units", get_formula_units($row2['id'])));
                                                         array_push($reply, $arr);
                                                     }
                                                 }
                                             }
                                         }
                                     }
                                 }
                             }
                         }
                     }
                 }
             }
         }
     }
 }
Пример #19
0
                <div class='btn-group-vertical' role='group' aria-label='refBButtons'>
                  <div class="button-decoration">
                    <button type="button" class="btn btn-bets" onClick="calcScore(10, '2', time, '<?php 
echo getname($Record, "Right");
?>
')">$10</button>
                  </div>
                  <div class="button-decoration">
                    <button type="button" class="btn btn-bets" onClick="calcScore(50, '2', time, '<?php 
echo getname($Record, "Right");
?>
')">$50</button>
                  </div>
                  <div class="button-decoration">
                    <button type="button" class="btn btn-bets" onClick="calcScore(100, '2', time, '<?php 
echo getname($Record, "Right");
?>
')">$100</button>
                </div>
<!-- =======
                  <div class="button-decoration">
                    <button type="button" class="btn btn-bets" onClick="calcScore(100, 'B', time, '<?php 
echo $answer;
?>
')">$100</button>
                  </div>
                  <div class="button-decoration">
                    <button type="button" class="btn btn-bets" onClick="calcScore(80, 'B', time, '<?php 
echo $answer;
?>
')">$80</button>
    $path1 = $datadir . '/ggtemplist.php';
    $ggtl = file_get_contents($path1);
    $ggtl = str_replace($selectggmb . "\r\n", '', $ggtl);
    file_put_contents($path1, $ggtl) or die('出错啦!无法修改.php文件!请将程序目录和所有文件的文件权限设置属性0755或0777。');
    $conn = new mysql();
    $conn->inoplog('删除广告模板', $selectggmb, 1, getname());
    die('1');
    /////////////////////
} elseif ($_REQUEST['menu'] == 'renewitem') {
    /////////////////////
    $itemlist = htmlspecialchars(insql($_REQUEST['itemlist']));
    $path1 = $datadir . '/ggtemplist.php';
    $ggtl = '<?php exit();?>' . "\r\n" . $itemlist;
    file_put_contents($path1, $ggtl) or die('出错啦!无法修改.php文件!请将程序目录和所有文件的文件权限设置属性0755或0777。');
    $conn = new mysql();
    $conn->inoplog('排序广告模板', $itemlist, 1, getname());
    die('1');
    /////////////////////
} else {
    /////////////////////
    $ggtl = file_get_contents($datadir . '/ggtemplist.php');
    $ggtla = explode("\r\n", $ggtl);
    array_shift($ggtla);
    array_pop($ggtla);
    $ggtemp_list = '';
    $ggtemp_sortable = '';
    foreach ($ggtla as $key => $value) {
        if ($value && file_exists($datadir . '/' . $value . '.php')) {
            $mbnr = file($datadir . '/' . $value . '.php');
            array_shift($mbnr);
            $mbsm = htmlspecialchars(rtrim(array_shift($mbnr)));
Пример #21
0
  <meta name="viewport" content="width=device-width; initial-scale=1.0">

  <!-- Replace favicon.ico & apple-touch-icon.png in the root of your domain and delete these references -->
  <link rel="stylesheet" type="text/css" href="CSS/styles.css">
</head>

<body>
  <div>
    <header>
      <h1>Rental Confirmation</h1>
    </header>

    <div id="wrapper">
    	<?php 
echo getname();
echo '<br />';
echo '<br />';
echo "Contact Info: ";
echo '<br />';
echo '<br />';
echo getEmail();
echo '<br />';
echo '<br />';
echo 'Your total cost: $';
echo getCost();
?>
    </div>

    <footer id="footer">
			<hr />
Пример #22
0
0.2:改进rcon功能<br />
0.1:增加登录功能
<?php 
} else {
    if ($_GET['action'] == 'changepassword') {
        $db->inject_check($_POST['password']);
        $db->query("UPDATE user SET password='******'password']}' WHERE id='{$my['id']}'");
        $my['password'] = $_POST['password'];
    } elseif ($_GET['action'] == 'tpa') {
        $db->inject_check($_GET['player']);
        if (empty($_GET['player'])) {
            echo '未定义玩家!<br />';
        } elseif (!is_online($_GET['player'])) {
            echo '该玩家不在线!<br />';
        } else {
            $tname = getname($_GET['player']);
            showmsg($my['name'], '请求已发送至 ' . $tname);
            showmsg($tname, $my['name'] . ' 想要传送到你这里来,请前往网页端接受请求.');
            $db->query("UPDATE user SET tpid='{$_GET['player']}' WHERE id='{$my['id']}'");
        }
    } elseif ($_GET['action'] == 'tpaccept') {
        $q = $db->query("SELECT * FROM user WHERE tpid='{$my['id']}'");
        $tplayer = $db->fetch_array($q);
        if (empty($tplayer['id'])) {
            echo '没有玩家向你发出过请求!<br />';
        } elseif (!is_online($tplayer['name'])) {
            echo '请求已失效!<br />';
        } else {
            showmsg($my['name'], '成功接受请求.');
            showmsg($tplayer['name'], '对方已接受你的传送请求.');
            $db->query("UPDATE user SET tpid='0' WHERE tpid='{$my['id']}'");
Пример #23
0
 /**
  * Index video thumbs...
  * will search for video thumbs in its folder and sort them in an array
  * and can be retrieved later for use in easy format
  * 
  * @param INT videoid | ARRAY videoarray
  */
 function index_video_thumbs($arr, $update_db = true)
 {
     $video = $arr;
     if (!is_array($video)) {
         $video = $this->get_video($video, true);
     }
     if (!$video) {
         return false;
     }
     /** @todo : this function must be callable and work when multi-server
      * is  installed
      */
     $folder = '';
     if ($video['file_directory']) {
         $folder = '/' . $video['file_directory'];
     }
     $dir = THUMBS_DIR . $folder . '/' . $video['file_name'];
     $thumbs = glob($dir . '*.jpg');
     $new_thumbs = array();
     foreach ($thumbs as $thumb) {
         $name = getName($thumb);
         $name_arr = explode('-', $name);
         $new_thumbs[$name_arr[1]][] = getname($thumb) . '.jpg';
     }
     if ($update_db) {
         //$this->update_meta($video['videoid'], 'thumbs', '|no_mc|' . json_encode($new_thumbs));
         $this->update_extras($video['videoid'], 'thumbs', $new_thumbs);
     }
     return $new_thumbs;
 }
Пример #24
0
    $path1 = $datadir . '/' . $clthread . '-' . $ontid . '.php';
    $path2 = $datadir . '/' . 'ggcllist.php';
    $ggclcon = cltojs($gid, $wllx, $clqz, $xzgg, $lhcl, $lhjg, $sjeorne, $sjsz, $xzmrcs, $mrcs, $xzfkcs, $fkcs, $oseorne, $os, $fbleorne, $fbl, $llqeorne, $llq, $yuyeorne, $yuy, $lyeorne, $vly, $urleorne, $url, $diyueorne, $diyu, $jreorne, $jr);
    $ggclcon1 = '<?php exit();?>' . "\r\n" . gnt() . "\r\n" . $cltitle . "\r\n" . $clsm . "\r\n" . $wllx . "\r\n" . $clqz . "\r\n" . $xzgg . "\r\n" . $lhcl . "\r\n" . $lhjg . "\r\n" . $sjeorne . "\r\n" . $sjsz . "\r\n" . $xzmrcs . "\r\n" . $mrcs . "\r\n" . $xzfkcs . "\r\n" . $fkcs . "\r\n" . $oseorne . "\r\n" . $os . "\r\n" . $fbleorne . "\r\n" . $fbl . "\r\n" . $llqeorne . "\r\n" . $llq . "\r\n" . $yuyeorne . "\r\n" . $yuy . "\r\n" . $lyeorne . "\r\n" . $vly . "\r\n" . $urleorne . "\r\n" . $url . "\r\n" . $diyueorne . "\r\n" . $diyu . "\r\n" . $jreorne . "\r\n" . $jr . "\r\n" . $ggclzu . "\r\n" . $ggcllei;
    file_put_contents($path, $ggclcon) or die('出错啦!无法创建.js文件!请将程序目录和所有文件的文件权限设置属性0755或0777。');
    file_put_contents($path1, $ggclcon1) or die('出错啦!无法创建.php文件!请将程序目录和所有文件的文件权限设置属性0755或0777。');
    $ggcllist = file($path2);
    if (!is_array($ggcllist)) {
        $ggcllist[] = '';
    }
    array_shift($ggcllist);
    array_unshift($ggcllist, $clthread . '-' . $ontid . "\r\n");
    array_unshift($ggcllist, '<?php exit();?>' . "\r\n");
    file_put_contents($path2, $ggcllist) or die('出错啦!无法创建.php文件!请将程序目录和所有文件的文件权限设置属性0755或0777。');
    $conn = new mysql();
    $conn->inoplog('添加广告策略', $gid, 1, getname());
    die('1');
}
///////////////////////////
$ggcllei = unescape($_COOKIE['ggcllei']);
$ggclzu = unescape($_COOKIE['ggclzu']);
$ggclleil = file_get_contents($datadir . '/ggclleilist.php');
$ggclll = explode("\r\n", $ggclleil);
array_shift($ggclll);
$ggclleilist = '';
foreach ($ggclll as $value) {
    if ($value) {
        if ($value == $ggcllei) {
            $ggclleilist .= '<option value="' . htmlspecialchars($value) . '" title="' . htmlspecialchars($value) . '" selected="selected">' . htmlspecialchars(cutstr($value, 10)) . '</option>';
        } else {
            $ggclleilist .= '<option value="' . htmlspecialchars($value) . '" title="' . htmlspecialchars($value) . '">' . htmlspecialchars(cutstr($value, 10)) . '</option>';
Пример #25
0
} else {
    $tejia = 0;
}
function getname($exname)
{
    $dir = "upimages/";
    $i = 1;
    if (!is_dir($dir)) {
        mkdir($dir, 0777);
    }
    while (true) {
        if (!is_file($dir . $i . "." . $exname)) {
            $name = $i . "." . $exname;
            break;
        }
        $i++;
    }
    return $dir . $name;
}
$exname = strtolower(substr($_FILES['upfile']['name'], strrpos($_FILES['upfile']['name'], '.') + 1));
$uploadfile = getname($exname);
move_uploaded_file($_FILES['upfile']['tmp_name'], $uploadfile);
if (trim($_FILES['upfile']['name'] != "")) {
    $uploadfile = "admin/" . $uploadfile;
} else {
    $uploadfile = "";
}
$jianjie = $_POST[jianjie];
$addtime = $nian . "-" . $yue . "-" . $ri;
mysql_query("insert into tb_shangpin(mingcheng,jianjie,addtime,dengji,xinghao,tupian,typeid,shichangjia,huiyuanjia,pinpai,tuijian,shuliang,cishu)values('{$mingcheng}','{$jianjie}','{$addtime}','{$dengji}','{$xinghao}','{$uploadfile}','{$typeid}','{$shichangjia}','{$huiyuanjia}','{$pinpai}','{$tuijian}','{$shuliang}','0')", $conn);
echo "<script>alert('商品" . $mingcheng . "添加成功!');window.location.href='addgoods.php';</script>";
Пример #26
0
function tryindex($fs, $dir)
{
    global $CFG, $RTI;
    $bdir = basedir($dir);
    $index_file = '';
    $ifile = pathjoin($CFG['cachedir'], $RTI['base'], sha1($dir) . '.idx');
    if (isarchive() && ($index_file = @file_get_contents($ifile)) !== false) {
        return $index_file;
    } else {
        foreach ($fs as $f) {
            if (!isweb($f)) {
                continue;
            }
            if (empty($index_file)) {
                $index_file = $f;
            } elseif (preg_match('/^index/i', $f)) {
                if (preg_match('/^index/i', $index_file)) {
                    if (strlen(getname($f)) < strlen(getname($index_file))) {
                        $index_file = $f;
                    }
                } else {
                    $index_file = $f;
                }
            } elseif (preg_match('/^default/i', $f)) {
                if (preg_match('/^default/i', $index_file)) {
                    if (strlen(getname($f)) < strlen(getname($index_file))) {
                        $index_file = $f;
                    }
                } elseif (!preg_match('/^index/i', $index_file)) {
                    $index_file = $f;
                }
            } elseif (levenshtein($bdir, $f) < levenshtein($bdir, $index_file) && !preg_match('/^index/i', $index_file) && !preg_match('/^default/i', $index_file)) {
                $index_file = $f;
            }
        }
        if (isarchive()) {
            if (!ufile_exists($CFG['cachedir'] . $RTI['base'])) {
                umkdir($CFG['cachedir'] . $RTI['base']);
            }
            file_put_contents($ifile, $index_file);
        }
        return $index_file;
    }
}
            }
        }
        file_put_contents($datadir . '/ggclzulist.php', $zulist) or die($datadir . '/ggclzulist.php 禁止写入!');
        $content = file_get_contents($datadir . '/ggcllist.php');
        $array = explode("\r\n", $content);
        array_shift($array);
        array_pop($array);
        foreach ($array as $gid) {
            $ggcld = insou1(file($datadir . '/' . $gid . '.php'));
            if ($ggcld[31] == $yggclzu . "\r\n") {
                $ggcld[31] = $xggclzu . "\r\n";
                file_put_contents($datadir . '/' . $gid . '.php', $ggcld);
            }
        }
    }
    $conn = new mysql();
    $conn->inoplog('修改广告策略类/组', ($xggcllei ? $yggcllei . ':' . $xggcllei . '|' : '') . ($xggclzu ? $yggclzu . ':' . $xggclzu : ''), 1, getname());
    die('1');
}
//////////////////////
if ($menu == 'editdelleizu') {
    $leiv = insql($_REQUEST['leiv']);
    $zuv = insql($_REQUEST['zuv']);
    $newggclleiv = '<?php exit();?>' . "\r\n" . $leiv;
    file_put_contents($datadir . '/ggclleilist.php', $newggclleiv) or die($datadir . '/ggclleilist.php 禁止写入!');
    $newggclzu = '<?php exit();?>' . "\r\n" . $zuv;
    file_put_contents($datadir . '/ggclzulist.php', $newggclzu) or die($datadir . '/ggclzulist.php 禁止写入!');
    $conn = new mysql();
    $conn->inoplog('排列/删除广告策略类/组', $leiv . '|' . $zuv, 1, getname());
    die('1');
}
Пример #28
0
if ($_SESSION['type'] == USERTYPE_SUPERVISOR) {
    getteamlist($_SESSION['group']);
}
$proboption = makeproboptions();
?>

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
</head>

<body>
<table width="100%">
<tr><td align="left">
<h2>Welcome: <?php 
echo getname($id);
?>
</h2>
</td><td align="right">
<a href="login.php">[log out]</a>
</td></tr>
</table>
<hr>

<?php 
if (defined('ANALYSIS_MODE')) {
    echo '<h2>ANALYSIS MODE</h2>';
    // put anything you want to show on analysis mode
    echo "<br>\n";
}
?>
Пример #29
0
        $SqlPassword1 = $SqlPassword;
    }
    $SqlDataBase1 = rtrim(htmlspecialchars(insql($_POST['SqlDataBase1'])), '\\');
    $Pre1 = rtrim(htmlspecialchars(insql($_POST['Pre1'])), '\\');
    $amsurl1 = rtrim(htmlspecialchars(insql($_POST['amsurl1'])), '\\');
    if ($amsurl1 && strrchr($amsurl1, '/') != '/') {
        $amsurl1 .= '/';
    }
    $thread1 = rtrim(htmlspecialchars(insql($_POST['thread1'])), '\\');
    $clthread1 = rtrim(htmlspecialchars(insql($_POST['clthread1'])), '\\');
    $ggwthread1 = rtrim(htmlspecialchars(insql($_POST['ggwthread1'])), '\\');
    $timezone1 = rtrim(htmlspecialchars(insql($_POST['timezone1'])), '\\');
    $configdata = "<?php\ndefined('IN_NIUXAMS') or exit('Access Denied.');\n\$adname = '{$adname1}';\n\$adpassword = '******';\n\$SqlServer = '{$SqlServer1}';\n\$SqlUserName = '******';\n\$SqlPassword = '******';\n\$SqlDataBase = '{$SqlDataBase1}';\n\$Pre = '{$Pre1}';\n\$amsurl = '{$amsurl1}';\n\$thread = '{$thread1}';\n\$clthread = '{$clthread1}';\n\$ggwthread = '{$ggwthread1}';\n\$timezone = '{$timezone1}';\n";
    file_put_contents('config.php', $configdata) or errwin('出错啦!config.php无法修改!请将程序目录和文件的文件权限设置属性0755或0777。');
    $conn = new mysql();
    $conn->inoplog('修改基本参数', 'cssz', 1, getname());
    okwin('恭喜你,修改参数成功了!');
    exit;
}
///////////////////////////
$title = '基本参数设置';
require 'mo.head.php';
?>
<style>
.cssz{
	border-width:1px 0px 0px 1px;
}
.left{
	border-width:0px 1px 1px 0px;
	font-size: 1em;
	line-height: 1.8em;
Пример #30
0
<?php

$modbase = "modules/login";
setstyle($modbase . "/");
$cp_nextact = getvardata("cp_nextact", "view");
$user = getvardata("user", "");
$pass = getvardata("pass", "");
$answer = getvardata("answer", "");
$pass1 = getvardata("pass1", "");
$pass2 = getvardata("pass2", "");
$error = getvardata("error", "");
echo "<input type=hidden name='cp_nextact' id='cp_nextact' value=\"{$cp_nextact}\">\n";
switch ($cp_nextact) {
    case "view":
        getname($shandle, $user, $pass);
        break;
    case "veriname":
        veriname($shandle, $user, $pass);
        break;
    case "requestion":
        requestion($shandle, $user, $answer, $error);
        break;
    case "reanswer":
        checkanswer($shandle, $user, $answer);
        break;
    case "getnewpass":
        getnewpass($user, $pass1, $pass2, $error);
        break;
    case "badanswer":
        badanswer($user);
        break;