Jelajahi Sumber

允许web运行

visuddhinanda 5 tahun lalu
induk
melakukan
a20d9243be
1 mengubah file dengan 2 tambahan dan 1 penghapusan
  1. 2 1
      app/dict/redis_sys_rgl_part.php

+ 2 - 1
app/dict/redis_sys_rgl_part.php

@@ -2,7 +2,8 @@
 require_once "../path.php";
 require_once "../redis/function.php";
 
-if (PHP_SAPI == "cli") {
+if (PHP_SAPI == "cli" || isset($_COOKIE["userid"])) 
+{
 	$redis = redis_connect();
 	if ($redis != false) {
 		$dbh = new PDO(_DICT_DB_REGULAR_, "", "", array(PDO::ATTR_PERSISTENT => true));