cannot run the localhost with upgraded php version and mysql version - php

My localhost was running on wampserver 2.0 ( with php5.3.0 , mysql5.1.16 , Apache 2.2.11). I needed to upgrade php and mysql, so i downloaded php 5.6.16. and extracted in to directory "wamp/bin/php/php5.6.16" with 3 mandatory files ( php configuration file, phpForApache configuration file and wampserver.conf file) from existing php5.3.0 folder.
Then I got a mysql from my friend's (mysql5.6.12 64bit) wamp directory. didn't do any configurartion. I put it into my wamp/bin/mysql. then i exited from wamp and restart it again.
Then php and mysql versions look like this.
mysql version is not displayed here. and the existing version name is not selected. with these changes I executed the localhost on browser.
wamp server home page is displayed on the browser.
Then I could see this.
In above image, the updated Mysql version is displayed, but not displayed in wamp tray menu mentioned before.
After I tried to view phpmyadmin page. the page was not loaded.
When I'm trying to select mysql version5.1.36 from wamp tray menu, following error was occurred.
Special: after this error occurred, the wamp go offline and cannot open localhost.
And also when I select php version 5.6.16 from wamp tray menu and start localhost, but it goes for " unable to connect" page.
Then I removed the new mysql 5.6.12 folder from the wamp/bin/mysql directory. then restart services and try again.
Nothing changes happened. when start the localhost I could see mysql version again as before.(MySQL Version :
5.6.12 ). But I already removed it from the directory.
I explained everything that i faced.
I need to know what is going on here and how to fix these problems. and How do I install php and mysql versions in this wampserver 2.0.

A working WAMP install should come with included MySQL and PHP versions. That's the whole point of using a package such as WAMP instead of installing your own; you get a whole working stack with one installation instead of having to install each application individually and then configure them manually to work together. Therefore, I have no idea why you would want to copy a friend's MySQL application to your computer. Aside from the fact that you probably didn't copy all the system files (DLLs, library files, etc), you're probably introducing conflicts with the library files that PHP and WAMP use to access MySQL since it's expecting a particular version and now you're providing a different version.
Frankly, at this point it sounds like things are messed up enough that probably the only proper solution is to remove what you have and reinstall the WAMP package (or each individual component). Make sure you back up any relevant changes you've made (configuration, web files, and databases) first!

First of all take back up of all local website in WWW directory found in wamp folder.. This is a time consuming time as it has to back up and copy all files, so sit aside and be patient.
Now, the only solution for this error is to uninstall wamp from control panel and than get tne new version of wamp according to your needs wither from archive or directly the latest version with your preferred php, mysql and apache versions. Follow this steps for backing up and recovering your old projects.:-
Before uninstalling the crashed server copy the full folder as backup of all previous data. (Example: Take backup of "C:\wamp" folder)
Uninstall the Crashed server and install the new one.
Make sure your new server running and has no error.
If server is running make it Stop and Offline then close it.
Go to C:\wamp\bin\mysql\mysql5.0.45\data\
Its better to take a backup copy of this data folder.
Replace the files and folders with your previous server data.
Add your Previous Projects to the Root folder. (Example: "C:\wamp\www")
Restart the server and check whether your previous tables and data are reflecting in the new server. (Example: Check it Out here http://localhost/phpmyadmin/)
Enjoy with your Old Projects at new server.
Source:- mysql.com
From:- http://infinium-tech.com

Related

500 Internal Server Error and blank page after migrating PHP project from 5.6 to 7.3

I need to migrate a PHP project from 5.6 to 7.3.
I'm using XAMPP locally for mysql module and Apache module. I also needed to update XAMPP from an older version to XAMPP for Windows 7.3.15 which has 7.3 support. Before I did this I backed up the database and the htdocs file with my project files. I also updated NetBeans to the latest version since the one I had didn't support 7.3.
After installing the new version of XAMMP I copied the htdocs project folder back in the same directory and restored the database(which was easier sais that done because it was pretty big and it kept timing out and I had to meddle with some php.ini configuration settings).
Now I'm trying to open the index.php page but I'm getting the 500 Internal Server Error. Checked the apache error logs and php error logs and I couldn't find anything.
There might be a problem with the XAMMP installation because the control panel still says 3.2.4 and the http://localhost/dashboard/ greets me with Welcome to XAMPP for Windows 5.6.31.
Oh, and the phpmyadmin page works fine.
This is more of a PHP issue than NetBeans. Anyway, you can try adding the following lines at the beginning of your script:
error_reporting(E_ALL);
ini_set("display_errors", true);
Then try to reload the page, you should see the exact error and the line number.

Need help in configuring WAMP (phpMyAdmin)

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

Windows 10 uninstall Mamp - cannot find C:\MAMP\unins000.exe

Short backstory: Recently I've installed MAMP as I want to start learning PHP. I got version 4.1.1 from the MAMP homepage, Apache didn't start. This seems to be a common bug for that version, I found a solution in downloading version 4.1.0. Both servers started but the Open WebStart Page didn't work.
My Problem: I wanted to try reinstalling it, I deleted the MAMP folder, as I thought that would be sufficient, instead of deleting it in the system settings. Now when I download it again and start the installer it says
MAMP setup has detected existing MAMP installation. You need to remove existing installation before proceeding. Do you want to uninstall it now?
Clicking either yes or no gives me
MAMP setup will now exit and the existing MAMP installation will not be removed.
In the system settings I find
MAMP & MAMP PRO 4.1.0 version 4.1.0 (1.47 GB)
When trying to uninstall it it gives me this error
Windows cannot find 'C:\MAMP\unins000.exe'. Make sure you typed the name correctly, and then try again.
Is there any way, other than reinstalling my whole OS, to solve this problem or do I have to turn to a different web server app?
I just encountered this problem and I hope my solution works for you as well:
Just download the .exe file into another device and install the MAMP.
After a successful installation, just copy the folder to your original device that has the problem.
And then you should find a file with a name starting with "uni" meaning it is for uninstallation. Just run that file and then everything should be fine!
I had the same problem (on OS is windows 10).
I browse the web and found a way:
You can download the ccleaner and use it, it can delete the MAMP.

How to setup a PHP server?

I'm trying to set up a PHP server. We have an old server that runs a bunch of in house forms over an intranet that is coded in ASP, and I'm trying to rebuild that into a better system using PHP.
I'm starting fresh, as have been given a Win 2012 r2 server.
I first tried installing IIS 8. I installed downloaded the files for php (version 7). I was successful in being able to access index.html and any other files placed in the c/inetpub/wwwroot folder from a different PC via a browser (http://servername/file.php). However, I installed MariaDB and phpmyadmin. phpmyadmin gave the the message the mysqli extension is missing.
I ultimately uninstalled IIS, and PHP, and the MariaDB. I wanted to start from scratch, and tried with Apache
I was able to get Apache and PHP to work together, but I could not access files in the htdocs folder from a different PC (going to http://<servername>/file.php). I could only access it via localhost.
I had the same problems with phpmyadmin and mysqli.
I also noticed there was no php.ini file... rather I saw a php-ini-production and php-ini-development files.
How to I fix the phpmyadmin problem? Any advice for configuring apache so that I can access files place in the htdocs folder from a device other than the server itself (non-localhost)?
I recommend using XAMPP, then you'll have MySQL, and may be you could configure to use MariaDB as well.
If you use XAMPP, phpmyadmin is not available other than localhost, but that is configurable. If you want i can help you find a good video for that.
take the php-ini-production file and rename it to php.ini and find the line
;extension=php_mysqli.dll
and just remove the leading semicolon (;), save and restart apache.
Also you need to open the firewall on your machine to allow port 80 to accept all connections.

http://localhost/myphpadmin/index.php only shows code

I installed Apache onto my C: drive. (C:/Apache).
I then installed phpmyadmin and placed it inside a folder (htdocs) inside C:/Apache.
I followed a youtube installation example for Apache. When it asked me my domain name and server, I copied what the tutorial said to put, which was "localhost" for both fields.
After both Apache and phpmyadmin had been installed and set up, I tried accessing phpmyadmin, but all I got was a lot of code.
I am wondering, if, when I was installing Apache, if, I should have typed bravehost.com or my bravehost server name, instead of localhost.
When I try to access the Phpmyadmin login page (index.php), I only get a page full of code instead of the login page.
How can i do this ?
PhpMyAdmin will only work if you have PHP installed and linked to Apache as a recognized plugin by editing the httpd.conf file within Apache. If you have not done this, the browser has no way of knowing how to parse the PHP code. I advise directly downloading and using a WAMP Stack (like Zend, XAMPP or WAMPServer) which would have PHP, Apache, MySQL and phpmyadmin pre-configured. Would be easy for you to begin with.
Install php
Enable php and check through phpinfo()
Isntall mysql
Install phpmyadmin
After installation by default pma url is localhost/phpmyadmin (or what eve you setuped while installation). Remember that pma is only php scripts (it's not soft as apache\mysql\php).
If you see php code on pages it means that php is not working and apache give you 'raw' code. Re-check that your php is enabled and is working.

Categories