constants.php 629 B

12345678910111213141516171819
  1. <?php
  2. // 全局常量
  3. define("APP_DIR", dirname(__FILE__));
  4. define("SUPPORT_RESTFUL", false);
  5. define("SESSION_KEY", "HEANUP_SESSION_UID");
  6. define("SIGN", "weatherapisign2019");
  7. define("ALERT_TOTAL", 40);
  8. if (get_magic_quotes_gpc()) {
  9. function stripslashes_deep($value)
  10. {
  11. $value = is_array($value) ? array_map('stripslashes_deep', $value) : stripslashes($value);
  12. return $value;
  13. }
  14. $_POST = array_map('stripslashes_deep', $_POST);
  15. $_GET = array_map('stripslashes_deep', $_GET);
  16. $_COOKIE = array_map('stripslashes_deep', $_COOKIE);
  17. $_REQUEST = array_map('stripslashes_deep', $_REQUEST);
  18. }