我正在尝试安装PEAR以用于PHP。 当我阅读http://pear.php.net/manual/en/installation.getting.php上的安装说明时,我应该运行文件go-pear.bat,这是我在C:\ wamp \ bin \ php \ php5.3.0目录。 根据我已阅读的所有安装指南,它应该安装并询问我一系列安装问题,但我收到以下错误:
phar“C:\ wamp \ bin \ php \ php5.3.0 \ PEAR \ go-pear.phar”没有签名PHP Warning:require_once(phar://go-pear.par/index.php):failed to在C:\ wamp \ bin \ php \ php5.3.0 \ PEAR \ go-pear.phar中打开流:phar错误:无效网址或不存在的phar“phar://go-pear.phar/index.php” 1236行
警告:require_once(phar://go-pear.par/index.php):未能打开流:phar错误:无效网址或不存在的phar“phar://go-pear.phar/index.php”中C:\ wamp \ bin \ php \ php5.3.0 \ PEAR \ go-pear.phar 1236行按任意键继续...
我不确定为什么我收到此错误。 我刚刚安装了新的Wampserver。
I am trying to install PEAR for use with PHP. As i read on the installation instructions at http://pear.php.net/manual/en/installation.getting.php , I am supposed to run the file go-pear.bat which I have in my C:\wamp\bin\php\php5.3.0 directory. According to all the installation guides I have read, it should install and ask me a series of installation questions, but I am receiving the following error:
phar "C:\wamp\bin\php\php5.3.0\PEAR\go-pear.phar" does not have a signature PHP Warning: require_once(phar://go-pear.par/index.php): failed to open stream: phar error: invalid url or non-existent phar "phar://go-pear.phar/index.php" in C:\wamp\bin\php\php5.3.0\PEAR\go-pear.phar on line 1236
Warning: require_once(phar://go-pear.par/index.php): failed to open stream: phar error: invalid url or non-existent phar "phar://go-pear.phar/index.php" in C:\wamp\bin\php\php5.3.0\PEAR\go-pear.phar on line 1236 Press any key to continue...
I'm not sure why I am receiving this error. I just installed the new Wampserver recently.
最满意答案
也许这就是你要找的。
这里是步骤:
1)找到“php.ini”文件。 就我而言,我发现它在这条路上:
C:\ WAMP \ BIN \ PHP \ php5.3.0 \ php.ini中
不要使用WAMP系统托盘图标来编辑此文件。 当我尝试时它不起作用 - 您必须手动找到它。
2)找到粗体的以下行:
; http://php.net/phar.require-hash;phar.require_hash = On; http://php.net/phar.require-hash
; phar.require_hash = On
3)通过删除分号取消注释“; phar.require_hash = On”行。
4)将“开”改为“关”。
; http://php.net/phar.require-hash
phar.require_hash =关
5)保存文件。
在我执行这些步骤后,“go-pear.bat”又开始正常工作。
Maybe this is what you are looking for.
Here are the steps:
1) Locate the "php.ini" file. In my case, I found it at this path:
C:\wamp\bin\php\php5.3.0\php.ini
Don't use the WAMP system tray icon to edit this file. It didn't work when I tried - you have to manually locate it.
2) Find the following line, in bold:
; http://php.net/phar.require-hash;phar.require_hash = On ; http://php.net/phar.require-hash
;phar.require_hash = On
3) Uncomment the ";phar.require_hash = On" line by removing the semi-colon.
4) Change "On" to "Off".
; http://php.net/phar.require-hash
phar.require_hash = Off
5) Save the file.
After I performed those steps, "go-pear.bat" began working normally again.
更多推荐
发布评论