Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

localhost doesn't work on Yosemite

Tags:

osx-yosemite

I have just today upgraded to Yosemite. I've not had a mac long. But with the update my localhost doesn't work. Chrome returns This webpage is not available. I've tried

sudo apachectl start to try and get it back but no luck. I'm a new mac user and haven't had to undergo an OS update, so not really sure where to start.

like image 651
Jonnny Avatar asked Jul 21 '26 06:07

Jonnny


1 Answers

I've stolen the following from https://github.com/liip/php-osx/issues/75 and http://php-osx.liip.ch/#uninstall

1. reinstall PHP

homebrew helps with this

brew update
brew upgrade
brew uninstall --force php54
brew unlink php54
brew uninstall --force php55
brew unlink php55
rm -rf /usr/local/php5*
brew install php55

2. where is libphp5.so?

please comment out the existing 'LoadModule php5_module' in /private/etc/apache2/httpd.conf and add this

LoadModule php5_module /path/to/lib/libphp5.so

3. delete +php-osx.conf and +entropy-php.conf

delete the files

+php-osx.conf
+entropy-php.conf 

in

/etc/apache2/other

4. testing if everything works

try to start apache with

sudo apachectl start
like image 91
martinenzinger Avatar answered Jul 26 '26 05:07

martinenzinger



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!