Jump to content

Archived

This topic is now archived and is closed to further replies.

theITvideos

Trying to install PEAR on Wamp Server and I see this...

Recommended Posts

Hi there,

 

I am  trying to install PEAR on my Wamp server. Everything is working fine. Its just that I don't have PEAR installed on my WAMP.

 

I double-clicked the go-pear.bat file located in:

 

C:\wamp\bin\php\php5.3.0

 

And I get this error in my command prompt :=

 

phar "C:\wamp\bin\php\php5.3.0\PEAR\go-pear.phar" does not have a signaturePHP W
arning:  require_once(phar://go-pear.phar/index.php): failed to open stream: pha
r 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.phar/index.php): failed to open stream: pha
r 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 . . .

 

Kindly let me know how I can fix this. See the Screenshots I've taken.

 

All comments and feedback are welcomed. :)

 

Thank you :)

 

[attachment deleted by admin]

Share this post


Link to post
Share on other sites

Change your go-pear.bat file to this:

 

@ECHO OFF
set PHP_BIN=php.exe
%PHP_BIN% -d output_buffering=0 -d phar.require_hash=0 PEAR\go-pear.phar
pause

Share this post


Link to post
Share on other sites

Change your go-pear.bat file to this:

 

@ECHO OFF
set PHP_BIN=php.exe
%PHP_BIN% -d output_buffering=0 -d phar.require_hash=0 PEAR\go-pear.phar
pause

 

I have tried installing Pear by dbl-clicking the go-pear.bat file and the installation is shown in the Screenshots which I've attached.

 

I believe it is installed as I've registered Pear by double-clicking 'PEAR_ENV.reg' file.  as shown in the Screenshot.

 

Now I am using a php file that uses PEAR and I still get the PEAR error as if it is not properly installed.

 

Can you see what is missing here.

 

Thank you :)

 

 

[attachment deleted by admin]

Share this post


Link to post
Share on other sites

I can't be of much help because I don't use windows, but have you done as Mchl suggested?

Share this post


Link to post
Share on other sites

Change your go-pear.bat file to this:

 

@ECHO OFF
set PHP_BIN=php.exe
%PHP_BIN% -d output_buffering=0 -d phar.require_hash=0 PEAR\go-pear.phar
pause

 

I got it working!!

 

Thanks bro!!

Share this post


Link to post
Share on other sites

Installing PEAR has it's side-effects on Windows. The include_path is wrong, change it to:

 

 

.;C:\Wamp\bin\php\php5.3.0\PEAR

 

 

In your php.ini. If you have a default installation of WAMP find php.ini in your bin\apache\apache2.2.11\bin\ open it and search for include_path. The end result should look like:

 

 

; UNIX: "/path1:/path2";include_path = ".:/php/includes";; Windows: "\path1;\path2";include_path = ".;c:\php\includes";; PHP's default setting for include_path is ".;/path/to/php/pear"; http://php.net/include-pathinclude_path = ".;C:\Wamp\bin\php\php5.3.0\PEAR"

 

 

Chances are there isn't an include_path in this case just write it! Copy this line and paste it also in the php.ini located under bin\php\php5.3.0 this will make this settings effective under CLI.

Share this post


Link to post
Share on other sites

Installing PEAR has it's side-effects on Windows. The include_path is wrong, change it to:

 

 

.;C:\Wamp\bin\php\php5.3.0\PEAR

 

 

In your php.ini. If you have a default installation of WAMP find php.ini in your bin\apache\apache2.2.11\bin\ open it and search for include_path. The end result should look like:

 

 

; UNIX: "/path1:/path2";include_path = ".:/php/includes";; Windows: "\path1;\path2";include_path = ".;c:\php\includes";; PHP's default setting for include_path is ".;/path/to/php/pear"; http://php.net/include-pathinclude_path = ".;C:\Wamp\bin\php\php5.3.0\PEAR"

 

 

Chances are there isn't an include_path in this case just write it! Copy this line and paste it also in the php.ini located under bin\php\php5.3.0 this will make this settings effective under CLI.

 

 

That is exactly what is did and it worked!!!!

 

I am so happy!

 

Thanks for the help bro. You are great!! :o)

Share this post


Link to post
Share on other sites

I may have forgotten to tell you that you should restart Apache after this process to make the effects visible. Which is actually easy as you only need to click on the wamp tray-icon and press restart all services (for convenience or Apache - Service - Restart Service)

Share this post


Link to post
Share on other sites

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.