跳至主要內容
  • Hostloc 空間訪問刷分
  • 售賣場
  • 廣告位
  • 賣站?

4563博客

全新的繁體中文 WordPress 網站
  • 首頁
  • 帮忙看下我这个PHP语法有没有错误,为啥不能正常运行
未分類
14 2 月 2020

帮忙看下我这个PHP语法有没有错误,为啥不能正常运行

全球VPS大学 大佬有话说 :

帮忙看下我这个PHP语法有没有错误,为啥不能正常运行

本帖最后由 全球VPS大学 于 2020-2-14 19:41 编辑

if($GLOBALS[‘config’][‘app’][‘encrypt’]==’3′){
        require_once ‘encryption.php’;//引用加密文件
        $player_info[‘url’] = encryption_en::encode($player_info[‘url’],’123′);
      $player_info[‘url_next’] = encryption_en::encode($player_info[‘url_next’],’123′);
                       
      }       

//其中    $player_info[‘url’]是一个标签。

/ 加密方式是这个调用的   encryption_en::encode(‘abc’,’123′);
//其中123是密钥

然后总是提示encryption_en’ not found 错误

//encryption.php 部分代码
class encryption_en{
        private static $default_key = ‘123’;
       

        public static function encode($string,$key = ”, $expiry = 0){
                $ckeyLength = 4;
                $key = md5($key ? $key : self::$default_key);
                $keya = md5(substr($key, 0, 16));               
                $keyb = md5(substr($key, 16, 16));               
                $keyc = substr(md5(microtime()), – $ckeyLength);

叫妇 大佬有话说 :

这几行代码没语法问题

文章導覽

上一篇文章
下一篇文章

AD

其他操作

  • 登入
  • 訂閱網站內容的資訊提供
  • 訂閱留言的資訊提供
  • WordPress.org 台灣繁體中文

51la

4563博客

全新的繁體中文 WordPress 網站
返回頂端
本站採用 WordPress 建置 | 佈景主題採用 GretaThemes 所設計的 Memory
4563博客
  • Hostloc 空間訪問刷分
  • 售賣場
  • 廣告位
  • 賣站?
在這裡新增小工具