I recently installed iis 7 and php 5.6.15 on my windows computer and for the most part everything is working fine. I can run phpinfo perfectly, but when I was trying to connect to a remote MySQL database I received the error above.
From searching the web I've learned that I do not have the module required to use pdo (pdo_mysql I think?).
I also for some reason do not have a php.ini. I have a loaded configuration file of (none) according to phpinfo. I have a php.ini-production and development however, but when I renamed production as php.ini I couldn't even use phpinfo.
So in conclusion how would I go about installing the pdo module I need (noting that I have very little experience with web design or php in general)?
I suggest you use a WAMP stack instead of IIS. Use WAMP/XAMPP on your windows! It's much easier to configure, and install modules. Plus, it would have configured your MySQL and Apache Server for php for you! So, you can just start building away!
Related
So I have been looking on the net for hours now and I can't solve my problem.
I have wamp installed (WampServer Version 3.1.7 64bit).
I want to open phpMyAdmin through wamp. (I have the phpMyAdmin5.0.2 installed and phpMyAdmin.conf is configured).
I have several php versions installed.(this was done through the process of trying to fix the solution alone).
When I try to open phpMyAdmin I get this error message: [1]: https://i.stack.imgur.com/ZEMaX.png .
I have tried configuring php.ini file (by de-commenting mysqli) it didn't change a thing.
Here's my php.ini file joined in the google drive link: https://drive.google.com/file/d/1fQuVoh5vhRX-MHhYL3zMQ4xNkstO-4Ch/view?usp=sharing .
I have configured extension_dir tp the php/ext folder.
I have similary configured my windows path to the php/ext.
Nothing I try works. Any help is welcome.
Thank you.
Since you're using WAMP, which should include all the pieces you need already working, but also have several PHP versions installed, it sounds like you're installing more than you need which is causing conflicts.
Assume you have no data in your database or web pages that you need to preserve, I suggest removing everything; get rid of WAMP and any extra Apache, PHP, or MySQL/MariaDB installations you have. Clean up (delete or move out of the way) any leftover configuration files, then reinstall WAMP. If you have trouble after installing only WAMP and no other PHP installation, then report back here details of the error. WAMP should come to you working and all ready to go, so if there is a problem, it will be helpful to start from a known base installation without extra configuration files or executable that will cause conflicts.
I'll also point out that the very top of the file you posted states that it's used only for the PHP Command Line Interface, so this is not the configuration file used by anything running through your webserver (like phpMyAdmin or your site). It's a little confusing that there are really two PHP instances (one for the command line and one that runs through the webserver), but in this case you would be looking for the file in wamp/bin/apache/apache2.x.y/bin/php.ini
I just updated my Wamp Server and got a problem now.
My SQLSRV extension wont get loaded correctly.
I dont know where the problem is exactly because i dont get any errors on startup. Also the error log is clean. There is just a little red triangle instead of a check in the php extension list:
Some Information:
Windows Server 2012 x64
Wamp 2.5 32BIT
PHP5.5
The Warning Icon means one of 2 things :-
Either the extension= line is in your php.ini but the dll it points to is not in your \ext folder
Or the dll exists in the ext folder but not in your php.ini
Which one is it in your case. If you updated WAMPServer the SQLServer dll does not come with any PHP install by default, so you will have to download it from the microsoft site.
hmm, i still cant understand this error. sure i know that i have to download the SQL driver manually. And i know only the "SQLSRV31.EXE" driver is working with Win Server 2K12. I downloaded this one and copied all php5.5 drivers into the /ext folder. Then i copied the name of the dll`s and added them to the php.ini:
http://fs1.directupload.net/images/141206/pkij993j.png
I will tryout installing the older wamp version with php5.4 included. May this will work =)
I also experienced the same thing happened to you. I tried many things but didn't work at all. I installed all the things required for Wamp like Microsoft visual basics 2012 but it still didn't worked.
This is the most important thing, for me this problem happened because i download wamp server 2.5 from the official wamp server site. http://www.wampserver.com/Mk
DON'T DO IT. it's totally a shit. then i download wamp server 2.4(old version) from this site called FIRE HORSE. this is the link http://www.filehorse.com/download-wampserver-32/
I downloaded and installed wamp server 2.4 from this site and it worked perfectly fine. and i also installed the latest Joomla version 3.4.5 in wamp server. Now i'm using it 100% fine. Many thanks for FIRE HORSE site.
I hope you all will find this useful and don't forget to tell me if i'm wrong because i'm still in learning progress i just shared my experience with you all. thank you.
I have a php project developed using zend framework, when i hosted to my local server(CentOS) i got the
below error:
The mysql driver is not currently installed
I have installed and enabled pdo_mysql on php.ini, but it is not effected my phpinfo.
Phpinfo only show pdo_sqlite not see pdo_mysql.
Another issue in my machine is phpinfo shows PHP version 5.2.8 and from terminal it shows PHP 5.1.6. Are there two php version running my machine?
Help is highly appreciated.
Check your phpinfo() output for the location of the php.ini file used and make sure to adapt that file. It's perfectly possible to have multiple versions of php running on a single computer.
It will show near the top of the output as (here's mine):
Loaded Configuration File /etc/php5/apache2filter/php.ini
that would be the location of the file you need to edit to affect your webserver instance php behaviour.
make sure to extension=php_pdo_mysql.so in it to load the mysql pdo driver
finally also make sure that extension_dir points to the directory where your libraries are found, using an absolute path; you can find that in phpinfo() under Core (and in your php.ini when you want to adapt it obviously)
I've been incrementally setting up a web server for research and testing purposes. The "server" is running Windows XP and I initially installed Apache Server 2.2 and PHP 5.3. That's been working great for a while. I am now needing to setup MySQL which I downloaded and installed MySQL v5.5. I am able to interact with MySQL via the command-line interface. In the process of setting up phpMyAdmin, I have encountered difficulties getting PHP and Apache to play nice with MySQL. Here's what I've discovered and tried:
In the php.ini file, when I attempt to uncomment either the php_mysql.dll or the php_mysqli.dll extension and restart the Apache server, the server crashes when it starts. The Windows event viewer says Apache failed to start due to "faulting module php5ts.dll".
The extension_dir parameter is set to ".\ext" and the php_mysql.dll and php_mysqli.dll files are in that directory.
I have also tried copying the libmysql.dll file from the lib folder of the MySQL directory to the Windows\System32 directory (with no change in behavior).
I'm at a bit of a loss to figure out what the next step is. Any suggestions?
The extension it's looking for is an extension output by php at compile time based on your configured build options. It is not looking for the header files from mysql itself.
Also, ".\ext" is a relative path that may or may not be valid in your installation. You may need to re-compile php to include mysql and mysqli (you should also compile PDO support) into your php build (Or whatever the windows equivalent of re-compiling is).
Also, you should make extension_dir an absolute path not relative.
I have a Windows Vista PC with IIS7, I have managed to manually install PHP on it.
And managed to load one of my custom extension for PHP, as well as mbstring extension.
But my mysql extension does not load when I check through phpinfo, I checked all the path variable, uncommented requied lines in php.ini file, also verified that the file exists.
My question is, does it require mysql server to be working on the local host for the mysql extension to load? or what could be wrong?
No, but you do need the appropriate MySQL client libraries to be available.
No, php_mysql.dll simply adds the various mysql functions into PHP. How could the .dll know where your server is? Or how you connect to it? Or what if you've got multiple seperate servers?
Until you actually try to connect to the server, the .dll will happily stay idle and not do anything.
If you're not stuck with using IIS, you could investigate installing WAMP - that'll give you MySQL, PHP, and Apache with a nice unified installer, without forcing you to mess around with .dll installation/customization.