What PHP version am I using

Hello everyone. I can use some serious help… :frowning_face:

Several years ago I was working on starting a business and because of the economy and some personal issues I had to put things on hold.

I went for a pretty serious PHP coder to zero.

Having been away from things for like 2-3 years, I don’t know where to begin?! :cry:

And to show you how screwed my situation is, I have this hunormous website that was just about completed, and now I’m not even sure what version of PHP it was written in?!

How can I determine which version of PHP I was working with?

Just run it with a current version of Php with error reporting turned on. You don’t want to continue with an old version. Php will be happy to tell you in the errors what needs updating.

Yeah, but I am trying to figure out things about my old environment so I know where to begin.

Another thing that happened in the past was my harddive crashed and I when I recovered things, I had to dump them into a backup folder.

I don’t even know how to run my code…

And when I went to open my webserver, it was trying to update, so that is why I am first trying to figure out what version of webserver and PHP I had.

I need to know how far behind I am before I take your advice.

This was developed on a Mac, so I use MAMP.

How do I figure out which version of MAMP I have and which version of PHP and MySQL I have?

God this is such a disaster!!

Run this to get the version

<?php
echo 'Current PHP version: ' . phpversion();

I guess my first problem is figuring out which version of MAMP I am running.

There are two instances in my Applications folder, so I am not even sure which one is launching when I click on the MAMP icon in the Dock.

This feels like a tornado hit my home and what was once orderly is no spread across two counties… :sob:

Does anyone here have experience with MAMP and Macs?

The simplest thing you can do is delete the MAMPS you have and install the current one and go from there.

@benanamen,

Thank you for trying to help out a new member!

After I calmed down, it occurred to me that if I went to MAMP > About MAMP that might be a good place to start!

It appears that I am currently running the following…

MAMP 3.5.2
***************
Apache 2.2.29
MySQL 5.5.38
PHP 7.0.8

Also, after digging around on MAMP’s website, it appears this is the latest version…

MAMP 5.1.1
***************
Apache 2.2.34
MySQL 5.7.23
PHP 7.0.30, 7.1.19, 7.2.7

After finding that out, I called my webhost and found out what is currently on my webserver.

Still not sure how to get all of my code running again, but one fire at a time!!

Sponsor our Newsletter | Privacy Policy | Terms of Service