Installing ssh2 on xampp - php

I am trying to install ssh2 on xampp
Xampp version : 3.2.1
PHP version : 5.4.19
Until now I have used following step to install:
download and copied libssh2.dll file to c:\windows\system32
php_ssh2.dll and php_ssh2.pdb files in the "ext" (e.g c:\xampp\php\ext) folder;
remove ; from this line extention:php_ssh2.dll in php.ini.
restart xampp
But I am getting error in log file:
unable to load dynamic library php_ssh2.dll
Can anyone help me with this?

A couple of things you may have missed :-
You need the Thread Safe (-ts-) version of php_ssh2
You need to make sure you get the 32 or 64 bit version to match your PHP/Apache and not to match your OS
You need the version of php_ssh2 that matches your PHP version i.e. 5.4
Having a look here for the download there is only a 32bit version of SSH2 compiled with VC9 available for PHP5.4, so you will have to ensure you have the 32bit version of XAMPP installed.
Oh and a final note, you do not need, and should not do, the copy of php_ssh2.dll into the c:\windows\system32 so remove the dll from this folder. PHP knows where to load its extensions from and putting files in c:\windows\system32 will only confuse things when you want to upgrade your version of XAMPP.

Related

How to install php_imagick on wamp64

I've been trying to install php_imagick on wamp64 without any luck.
The desired goal is for WordPress to stop showing the error message:
The optional module, Imagick, is not installed or has been disabled.
You can also skip reading and view the images attached below.
My setup:
Wamp64 Windows 10 Release Version 3.2.3.3 64 Bits [Windows Build: 19041]
PHP Version: 7.4.9
Build Date: Aug 4 2020 11:45:36
Windows: NT *username* 10.0 build 19041 (Windows 10) AMD64
Compiler Visual: C++ 2017
Architecture: x64
Loaded Configuration File: C:\wamp64\bin\apache\apache2.4.46\bin\php.ini
Thread Safety: enabled
I tried installing the following ImageMagick files:
1) ImageMagick-7.0.10-30-Q16-HDRI-x64-dll.exe
----A) php_imagick-3.4.3rc1-5.6-ts-vc11-x64.zip
----B) php_imagick-3.4.3rc1-7.1-ts-vc14-x64.zip
2) ImageMagick-7.0.10-30-Q16-x64-dll.exe
----A) php_imagick-3.4.3rc1-7.1-ts-vc14-x64.zip
----B) php_imagick-3.4.4rc2-7.3-ts-vc15-x64.zip
3) ImageMagick-6.9.3-7-Q16-x64-dll.exe (Current)
----A) php_imagick-3.4.4rc2-7.3-ts-vc15-x64.zip (Current)
----B) php_imagick-3.4.3rc1-7.1-ts-vc14-x64.zip
----C) php_imagick-3.4.3rc1-5.6-ts-vc11-x64.zip
What I did:
I first installed the EXE file and then extracted from the zip file just the php_imagick.dll file into this folder:
C:\wamp64\bin\php\php7.4.9\ext
Which matches my currently used PHP version (see images later for more information[php.ini]).
I tried restarting Wamp, rebuilding symlinks by switching PHP/Apache versions.
Will also be worth mentioning that I at one point tried extracting the full zip into the 'ext' folder under a folder named 'php_imagick' as shown below and did manage to get this error:
C:\wamp64\bin\php\php7.4.9\ext\php_imagick\php_imagick.dll (The specified procedure could not be found.)
but mostly I receive these errors:
[25-Sep-2020 08:58:50 UTC] PHP Warning:  PHP Startup: Unable to load dynamic library 'php_imagick.dll' (tried: c:/wamp64/bin/php/php7.4.9/ext/php_imagick.dll (The specified module could not be found.), c:/wamp64/bin/php/php7.4.9/ext/php_php_imagick.dll.dll (The specified module could not be found.)) in Unknown on line 0
When I install Magick using the EXE, I make sure to check the install to the path, Change the folder to C:\ImageMagick, and install the legacy drivers if possible, as suggested on Stack OverFlow.
(I also make sure to uninstall the last version I tried each time)
I have Visual Studio installed and a bunch of redistributables and also both x86 and x64 versions of these:
https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads
http://www.microsoft.com/en-us/download/details.aspx?id=30679
Without any luck, I went ahead and read several Stack OverFlow posts and could not find a solution.
How to install ImageMagick with Wampserver 3.0.0 64?
step-by-step instructions for installing IMAGEMAGICK on WAMP?
Installing php_imagick.dll PHP extension on wampserver 2.2
Unable to install php_imagick.dll on wamp
Imagick delegates installation on WAMP
How to install ImageMagick with Wampserver 3.0.0 64?
step-by-step instructions for installing IMAGEMAGICK on WAMP?
Installing php_imagick.dll PHP extension on wampserver 2.2
Unable to install php_imagick.dll on wamp
Imagick delegates installation on WAMP
WAMP PHP Startup Error: Unable to load dynamic library
Installing ImageMagick extension with php/windows
Linker error when trying to use ImageMagick as static libraries with Visual Studio compiler
Installing Magick++ in Visual C++ 2010
Installing Magick++ in visual studio 2019
ImageMagick with Visual Studio
WampServer and Imagemagick, imagick php module not recogized
Cannot load imagick library
ImageMagick not working
What can I try next?
typo in line 955: .php=.dll
I hired a freelancer to fix this for us.
Uninstall any versions of WampServer and ImageMagick you have installed
Don't forget to backup your database and www folder before you uninstall
We are going to install a trustable software called Chocolatey that will help us fix a bunch of errors with Wamp64 and it's extensions as well as help us update those applications with one command.
For those of you who already fixed this before using Chocolatey and
now seeing this error message again simply update Wamp and ImageMagick
using the choco commands provided on their website and then read my
note under 4) for more information
Run PowerShell as Admin
Follow this guide to Download chocolatey https://chocolatey.org/install
Use the same methods to Download Wamp64 https://chocolatey.org/packages/wamp-server
Run Wamp from the newly created shortcut on your desktop
Change the PHP version to 7.4.9 or the latest and only then move
to the other steps
Don't worry about the fact the folder is named Wamp and not Wamp64. It's still the 64bit version. You can check this in the about section of Wamp
Download https://chocolatey.org/packages/imagemagick
Download https://windows.php.net/downloads/pecl/deps/ImageMagick-7.0.7-11-vc15-x64.zip
Note: If that doesn't work, they probably updated again. Just try the same methods using newer versions then these. I will first try more recent versions of php_imagick instead of replacing the ImageMagick core DLL files. One thing I will not do is give up.
Extract And Copy all CORE_RL and IM_MOD_RL DLL files into C:\wamp\bin\php\php7.4.9 where php.exe is located
(Do not run any EXE file from here as we already installed ImageMagick)
Download https://windows.php.net/downloads/pecl/releases/imagick/3.4.4/php_imagick-3.4.4-7.4-ts-vc15-x64.zip
Extract and Copy just the php_imagick.dll file to C:\wamp\bin\php\php7.4.9\ext
Open your php.ini file by left-clicking Wamp->PHP->php.ini and then make sure you delete all leftovers and add below any extention= line the code below:
extention=imagick
(Apparently, New PHP versions require writing it without the "php_"...".dll" parts)
Restart Wamp by closing it and reopening it from its shortcut
This is by far the only solution I could get running.
choco:
Google = https://www.google.com/search?q=chocolatey
2019 = http://web.archive.org/web/20190101113929/https://chocolatey.org/
2018 = http://web.archive.org/web/20180414000310/https://chocolatey.org/
Enjoy
I use wampserver 3.2.3 64bit together with PHP 7.3.
Copying the CORE_RL and IM_MOD_RL DLLs into the PHP root direcory as orr burgel recommended in item #5 did not work for me.
I had to copy these DLLs into c:\wamp64\bin\apache\apache2.4.41\bin.

Where to find php_imagick.dll for php 5.5.12 for Windows wampserver 2.5?

I am using Wampserver 2.5 on my Windows 7 (32 bit) and my PHP version is 5.5.12. I am unable to use IMAGICK.
I have installed IMAGICK version 6.8.9 on my system and it works like charm on the command line.
Further, I have followed instructions to enable it on my wampserver.
Inserted "SetEnv MAGICK_HOME C:/imagemagick" in httpd.conf at Appache.
Downloaded php_imagick-3.1.2-5.5-ts-vc11-x86.zip
Copied and pasted the php_imagick.dll from zip to php.ini at Appache.
While running a simple script on php [$a = new Imagick()] I get the error [Class 'Imagick' not found].
Kindly direct me to the right way of installation and the right downloads to install IMAGICK on Wampserver 2.5 / Windows 7 / 32bit / PHP 5.5.12.
Manual installation of imagick on Wamp, Xampp, and IIS
Create a folder imagick in php/ext folder.
Now add this newly created php/ext/imagick folder to windows path.
Download the latest version of imagick for windows from this link. http://windows.php.net/downloads/pecl/releases/imagick/
Download php extension of imagick from this link.
http://windows.php.net/downloads/pecl/deps/
Before downloading these 2 zip files, match the file name of your installation with your php.
for eg. php_imagick-3.2.0b2-5.5-nts-vc11-x86.zip
-Here 5.5 is the version of php
-nts is for IIS and windows (wamp) and ts is for Apache and Linux (xampp)
-VC11 and VC9 are the version of compilation, run phpinfo and check that it match with your php version.
-x86 is for 32 bit x64 is for 64 bit machines, i recommend use x86 only
Once you have downloaded the correct version for your php, extract the downloaded file to imagick folder you have added to path, take all files from bin folder to the root of imagick and replace all
Add full path to php_imagick.dll in php.ini like extension=C:\wamp\php\ext\imagick\php_imagick.dll
Restart your computer for path to take effect. Then open command and type dcraw and press enter. if you have added the path correctly a list of parameters will be shown, your Imagick is installed sucessfully.
Run phpinfo again and you will see Imagick listed as extension.
I would add a small, but crucial advice, becaues it took me 10 hours of sunday, to get it working.
This is for Win7/10 x64 and Wamp 2.5 x64
There is a php.ini file in apache/bin folder and there should be added a new line with php_imagick.dll extension :)

install imagick in xammp 1.8.3

I tried every article on installing imagick in xampp but non of them is worked. it is surprise to see that installing dll is not as simple as it normally suggest
i am trying imagick on xampp 1.8.3 but if any one have any idea to install imagick in xampp then please guide me
I am trying on
Windows 8 Pro 64-bit
XAMPP Version: 1.8.3
Control Panel Version: 3.2.1 [ Compiled: May 7th 2013 ]
firstly i installed Binary Release Win32 dynamic at 16 bits-per-pixel in C:\ImageMagick-6.8.9-Q16
then load this dll in php\ext
and lastly edit extension=php_imagick.dll in php.ini
now after restart windows i got this error
PHP Startup: Unable to load dynamic library 'C:\xampp\php\ext\php_imagick.dll'
- The specified procedure could not be found.
lastly all other dll files have PHP 5.5.9 version but i have not found any php_imagick.dll that have PHP version 5.5 .Even this dll is also 5.3 PHP version. is this work also
Please tell me why i am getting this error
I believe that imagemagick also needs access to the CORE_RL_*.dll set which are located in the C:\ImageMagick-6.8.9-Q16 directory that you installed into.
You have to add this folder into to your PATH for these to be found at runtime.
Its a bit messy and if anyone knows a better solution than adding this to the PATH I would love to know about it.
Try downloading your php_imagick.dll from here http://windows.php.net/downloads/pecl/releases/imagick/

MongoDb with php on windows 7 64 bits

I installed wampserver, and mongodb both up and running i installed the mongodb extension PHP 5.3 VC6 Thread-Safe Mongo extension and added php_mongo.dll extension to php.ini, restarted the server but it won't show up in phpinfo() and of course it won;t work. Where did i skip a step ?
PHP x86 or x64 ? Look at "Architecture" in phpinfo. Official drivers doesn't work with Apache + PHP x64.
Look at this post: http://groups.google.com/group/mongodb-user/browse_thread/thread/1d2cecd9734e54fc/ff785888cb8e2c39?lnk=gst&q=x64#ff785888cb8e2c39
php_mongo.dll is now available for 64 bit architecture too. You can download the same from github. No need to downgrade now to 32-bit.
https://github.com/downloads/mongodb/mongo-php-driver/php_mongo-1.2.12.zip
parent link : https://github.com/mongodb/mongo-php-driver/downloads
Have you checked the php_mongo.dll is actually in the PHP exstension dir?
In my case Windows 7 64 bits, php-5.6.14-Win32-VC11-x64 and php_mongo-1.6.11-5.6-ts-vc11-x64
After check the VSVC Versions, configure the php.ini location, in the php.ini put the correct file the extensio_dir. And add to sytema PATH the location of php.
You need to copy libeay32.dll, libsasl.dll and ssleay32.dll into c:\windows\system32 and c:\windows\syswow64
Good day.

step-by-step instructions for installing IMAGEMAGICK on WAMP?

There don't seem to be any concise tutorials/walk throughs for installing ImageMagick on WAMP for use with PHP.
I've tried dozens of combinations of their binary releases with different php extension dll files. I can get imagemagick working fine from the command line, and I can get it to show as ticked in the WAMP extensions, but can't actually use it.
Has anyone come across a good guide for installing this ball ache piece of software?
I've followed http://www.knowledge-transfers.com/it/installing-imagemagick-on-windows-setup-imagick-on-php with no luck...
Update: this is what happens when I follow the steps in PHP farmer's answer on windows7. My php.ini is setup as follows:
extension_dir = "c:/wamp/bin/php/php5.3.0/ext/"
extension=php_imagick.dll
I reboot and get these two errors in this order
and here is the dll file where it should be:
I know this is old post but I spend my all day to make it work, so here are the steps that helped me:
Download ImageMagick Binary Release - http://www.imagemagick.org/script/download.php
Install in C:\imagemagick, on last step check "Add application directory to your system path"
Download Imagick DLL: PHP5.6.x version from http://www.peewit.fr/imagick/ (I have 5.6+ version installed on my localhost
Copy php_imagick.dll to C:\wamp\bin\php\ext
Download PHP 5.6 Thread Safe (TS) x86 version from http://pecl.php.net/package/imagick/3.1.2/windows
Copy CORE_RL_* files to C:\wamp\bin\apache\bin\
Edit php.ini file in C:\wamp\bin\apache\bin\php.ini, add extension=php_imagick.dll line in extensions section
Copy all files from C:\imagemagick\modules\coders and C:\imagemagick\modules\filters to C:\imagemagick to load ImageMagick supported formats
Go to Control Panel -> System -> Advanced Settings -> Environment Variables -> New System Variable -> MAGICK_HOME = C:\imagemagick
Restart Wamp server and check phpinfo() for imagick plugin
If last step does not work, restart Windows
I have improved fsasvari answer to cater general scenarios and versions. All credits to him.
Install Imagick in WAMP
Open your phpinfo() page
Check the below
PHP version (mine : 5.5.12)
Compiler (mine : MSVC11 (Visual C++ 2012) )
Architecture : (mine : x64)
Thread Safety : enabled
Loaded Configuration File (mine : C:\wamp\bin\apache\apache2.4.9\bin\php.ini)
extension_dir : (mine : c:/wamp/bin/php/php5.5.12/ext/)
Apache Bin (Not in phpinfo() page) : C:\wamp\bin\apache\apache2.4.9\bin\
Get the latest release match to your architecture from here (for me it was ImageMagick-x86_64-pc-windows.exe).
Copy all files from C:\imagemagick\modules\coders and C:\imagemagick\modules\filters to C:\imagemagick to load ImageMagick supported formats
Install in C:\imagemagick, on last step check "Add application directory to your system path"
Download the PECL matching to your architecture
http://pecl.php.net/package/imagick/3.1.2/windows
(for me : 5.5 Thread Safe (TS) x64)
Extract it and copy all the CORE_RL_* files to apache bin folder (mine : C:\wamp\bin\apache\apache2.4.9\bin)
Copy php_imagick.* files to extension dir (mine : c:/wamp/bin/php/php5.5.12/ext/)
Edit php.ini file (mine : C:\wamp\bin\apache\apache2.4.9\bin\php.ini)
add extension=php_imagick.dll line in extensions section
Go to Control Panel -> System -> Advanced Settings -> Environment Variables -> New System Variable -> MAGICK_HOME = C:\imagemagick
Restart Wamp server and check phpinfo() for imagick plugin
If last step does not work, restart Windows (Specially if you have previously installed imagemagick in different folder/version)
For WAMPSERVER 3.1.9 64bit, PHP Version: 7.3.5
I had a lot of trouble with this as well and some things I did wrong was that I doubted ImageMagick would load on my new php version. But you have to believe it will work and don't try with older php versions :)
So this was my approach, remember to follow it with your own settings and versions/folders.
Before you start, make sure you running the php version you want to run. If you installed Wampserver 3, you may click the wamp icon and go to php version and activate the one you want to run.
1
Get latest ImageMagick version for your system here: http://ftp.icm.edu.pl/packages/ImageMagick/binaries/
(I got the ImageMagick-x86_64-pc-windows.exe in the bottom)
2
Install ImageMagick in C:/imagemagick (I put it in lower cases),
You will be asked for some stuff during install, just make sure the path thingy is ticked.
You should also tick the convert thingy if it allows you.
Then after install you can run CMD and type convert -version to see if imagick is installed.
3
Run <?php phpinfo(); ?> And find out these settings:
PHP Version: 7.3.5
System: Windows
Compiler: MSVC15 (Visual C++ 2017) ([VC15])
Architecture: x64 (or maybe you have x86)
Thread Safety: enabled ([TS] else [NTS])
You probably have other settings, but you need to remember yours to download the proper php_imagick.dll
4
Get the php_imagick.dll you want for your php version from here: http://pecl.php.net/package/imagick
I got mine from here: http://pecl.php.net/package/imagick/3.4.4/windows for php 7.3
Remember your info from the phpinfo(), it has to match, else it won't work.
5
After you unzip it, copy the php_imagick.dll and paste it in C:/wamp64/bin/php/php7.3.5/ext/
Then copy all the other .dll files from that folder into C:/wamp64/bin/apache/apache2.4.39/bin/
Yes it's dirty but you will get it working like this.
6
Add extension=php_imagick.dll in C:/wamp64/bin/php/php7.3.5/phpForApache.ini
I added it after the other extensions in the file.
7
Restart all Wamp services.
If you been messing around earlier with installs, you might have to restart the computer due to some weird cache stuff.
8
Check phpinfo() again if imagick shows up and try something like $im = new Imagick();
9
Click the Wamp icon -> php -> extensions, php_imagick should be listed.
Good luck! :)
PHP 5.4 php_imagick.dll is here: http://www.peewit.fr/imagick/ .
I read somewhere that 64bit php doesnt work with php_imagick. That might be the case when you get this error in apache_error.log
PHP Warning: PHP Startup: Unable to load dynamic library 'c:/wamp/bin/php/php5.4.3/ext/php_imagick.dll' -
%1 is not a valid Win32 application.\r\n in Unknown on line 0
As mentioned above, it was also necessary to add this into httpd.conf (also, i read you cant have spaces/dashes/dots):
SetEnv MAGICK_HOME C:/imagemagick"
If you dont, you might get this error:
"PHP Warning: PHP Startup: Unable to load dynamic library 'c:/wamp/bin/php/php5.4.3/ext/php_imagick.dll' -
The specified procedure could not be found. in Unknown on line 0"
In the end, this article might partially help: http://www.elxsy.com/2009/07/installing-imagemagick-on-windows-and-using-with-php-imagick/
This was a headache for me as well, but unfortunately I installed this quite awhile ago. The instructions from that link you posted seem accurate. Have you ran phpinfo(); to see if it is installed in the Apache Environment? It should be listed as MAGICK_HOME.
Make sure "SetEnv MAGICK_HOME C:/imagemagick" is set at the end of your httpd.conf file. Assuming imagemagick is installed in that directory.
Be sure that you have the extension "php_imagick.dll" in your php.ini file as well.
It should work just fine if you have all those set.
On another note, here is a nice little library someone built to make imagick easier to use. https://github.com/francodacosta/phmagick
I hope that helps! Good luck!
I've never used WAMP but I have found that sometimes installing PHP extensions on Windows I need to ensure that any dll's that the extension relies on is in the Windows system PATH. If there is more than the one dll packaged with the imagemagick extension, try adding the directory that the dll's reside in to the Windows system PATH then REBOOT (to ensure that the web server gets a copy of the NEW environment).
I know this is an old question but i guess this will help someone someday out there....
If you are on WAMPP and have PHP 5.4.x installed , go here http://www.peewit.fr/imagick/
and download appropriate files as instructed. It will work.
Please see this answer already on StackOverflow:
Installing ImageMagick extension with php/windows
I answered this question some time ago. This solves the DLL mismatch error.

Categories