コード例 #1
0
ファイル: ctl_upload.php プロジェクト: zcmyworld/nothing
 public static function photo_del()
 {
     $photoId = empty($_GET['photoId']) ? "" : $_GET['photoId'];
     mod_index::delPhoto($photoId);
     $rs = mod_index::getPhoto();
     render_template("photo.php", array("photo_list" => $rs));
 }
コード例 #2
0
ファイル: ctl_index.php プロジェクト: zcmyworld/nothing
 public static function updateText()
 {
     $id = $_POST['id'];
     $text = $_POST['text'];
     $param['id'] = $id;
     $param['text'] = $text;
     $rs = mod_index::updateText($param);
     echo json_encode(array("error" => "0", "id" => $id));
 }
コード例 #3
0
ファイル: ctl_index.php プロジェクト: zcmyworld/nothing
 public static function index()
 {
     $rs = mod_index::getIndex();
     $bigPhoto = array();
     $smallPhoto = array();
     foreach ($rs as $key => $val) {
         if ($val['type'] == 1) {
             array_push($bigPhoto, $val);
         } elseif ($val['type'] == 2) {
             array_push($smallPhoto, $val);
         }
     }
     render_template("index.php", array("bigPhoto" => $bigPhoto, "smallPhoto" => $smallPhoto));
 }