Exemplo n.º 1
0
?>
<body>
<?php 
include_once 'title.php';
?>
<div id="wrapper2">
	<div id="welcome" class="container">
		<div class="title">
			<h2>Add a new Resolution</h2>
		</div>
		<?php 
include '/functions/add_resolution.function.php';
add_resolution();
?>
	</div>
</div>
<div id="wrapper3">
	<div id="three-column" class="container"></br></br>
		<?php 
include '/classes/resolution.class.php';
$res_obj = new res();
$res_obj->read_table($uid);
?>
	</div>	
</div>
<?php 
include 'footer.php';
?>
</body>
</html>
Exemplo n.º 2
0
 /**
  * 获取图片集列表
  *
  * @param  string time
  * @param  string uuid
  * @param  string page_Index 当前页数
  * @param  string pageSize	 每页显示页数
  * @return string
  */
 public function get_pic_list(req $req, res $res, $args)
 {
     if (isset($_GET['time']) && isset($_GET['uuid']) && isset($_GET['pageIndex']) && isset($_GET['pageSize'])) {
         //验证sign
         $time = $_GET['time'];
         $uuid = $_GET['uuid'];
         $str = $time . $uuid;
         $sign = $req->getQueryParam('sign');
         if ($sign) {
             $signs = $this->des->decrypt($sign);
             if ($str !== $signs) {
                 return $res->error(-101, 'sign值无效');
             }
         } else {
             return $res->error(-1004, 'sign值不能为空');
         }
         $pic = new \App\Model\Pics();
         $page_Index = $req->getQueryParam('pageIndex');
         $page_Size = $req->getQueryParam('pageSize');
         if ($result['list'] = $pic->pic_list($page_Index, $page_Size)) {
             return $res->success($result);
         } else {
             return $res->error(-1004, '请求数据为空');
         }
     } else {
         return $res->error(-1, 'time和uuid与pageIndex跟pageSize不能为空');
     }
 }