OSX Yosemite comes with PHP 5.5. OSX Mountain Lion comes with PHP 5.3. What if you wanted to run PHP 5.4 on both? Well, you can, with a dead simple installation;
curl -s http://php-osx.liip.ch/install.sh | bash -s 5.4
will install PHP 5.4.
Thanks to The coolest guide on the planet.
[EDIT: nov 6 2017: fixed dead link, added troubleshooting steps below]
Still not seeing the new version?
- The command above should install the old PHP 5 in /usr/local/php5 (which should be user-writable) and also write a new config file in /etc/apache2/other/+php-osx.conf, so please check and see if both exist.
If you installed PHP 7.x, the folder is /usr/local/php7, of course.
apachectl -t -D DUMP_INCLUDES and check if the new config file is loaded (should be /etc/apache2/other/+php-osx.conf)
apachectl configtest and see if any errors occurred
If you can’t get it to work, try alternate methods, like using the even older series of posts on How to set-up and maintain a development environment on osx, OR (even better!) use Local by Flywheel.
Tired of moving back and forth between user accounts just because you need a file from a second or third dropbox account? Sure you can use the web version but with three or more accounts, even that becomes tiresome.
Yeah, I could not think of a better name, but hey, it’s the thought that counts.
Do you want to know how to get more than one Dropbox account in sync on the same user, no switching, no web-apps, just functional? then read on.
Continue reading “Multiple Dropbox accounts – at once – no user switching”
After upgrading OSX to version 10.9 I find myself investigating why my development server no longer works. After 4 upgrades I now have a clear list of things to check and how to fix.
If you have not yet upgraded OSX, take the time to back-up your /etc/php.ini and /etc/apache2/httpd.conf. Also; OSX 10.9 Mavericks will upgrade PHP to PHP 5.4, so if you have projects incompatible with 5.4; a) don’t upgrade OSX, b) start upgrading your code or c) use a different AMP-stack.
Also; if you depend on your computer for your income, don’t rush into this!
The TODO list:
- Backup your system
- Upgrade OSX
- Upgrade Xcode and run it at least once, installing the commandline tools
- Reboot your system
- Follow the checklist :)
The checklist (things to check and maybe fix):
Continue reading “Repair OSX WebDevelopment server after OSX Upgrade”
Apache2 is already installed on any Mac and most setups (like MAMP or MacPorts) just ignore the built in Apache and install their own version. Shame. You wouldn’t ignore your own car just and get another one to pull a trailer while your own car can do the job perfectly.
Continue reading “Development WebServer on OSX Lion – HomeBrew/MariaDB/PECL”
It took me a while and finally found a working, but a bit ugly, solution. Not to bore you with the details, here are the step by step instruction on how to get HTTPS working on your development web server. Please note, this is not a good setup for live web servers, you will have to take security into account if you use this on a publicly available web server. Continue reading “SSL (HTTPS) on your Development WebServer”
A few command lines for managing the Virtual Memory on your Mac.
Please note; if you have a regular amount of memory, like 4 GB or 8 in recent models, you might want to consider NOT turning off Virtual Memory. But if you have ample RAM, give it a try, you will notice a big speed improvement. Why? Thats because Virtual Memory is ALWAYS used, even if you don’t really need it.
Continue reading “Virtual Memory Configuration”
[UPDATE]: Updated for OSX 10.10 Yosemite [/UPDATE]
In my attempts to run phpMyAdmin on my development Mac I found this tutorial but, alas, it didn’t work. It resulted in numerous errors (like this one: lipo: can’t figure out the architecture type of: /var/folders/v6/nrfc_5hn12g91vzw8vff44m00000gn/T//cchRI7wl.out) and, as you guessed, the mcrypt extension did not work.
Continue reading “Adding MCRYPT to your OSX based PHP server setup”