I found the solution. It turns out all my problems were irrelevant. For some reason, the PHP settings in my hosting account were reset, and all I had to do was switch the PHP version back to 5.4 to fix everything.
Moving Laravel outside of docroot gives me problems with php's chdir() and path('sys')
Pregunta
I've been using Laravel 3 on a live website for a while, and decided to move the app to outside of docroot, delete the public_html folder, and symlink the public folder to the public_html one. I followed solution 1 here.
Having done that, my site has stopped loading, giving a 500 error. When I checked the error log in public/error_log, this message appears:
[05-Feb-2013 08:07:25] PHP Warning: chdir() [<a href='function.chdir'>function.chdir</a>]: No such file or directory (errno 2) in /home4/indieweb/indiewebseries/paths.php on line 62
[05-Feb-2013 08:07:25] PHP Fatal error: require() [<a href='function.require'>function.require</a>]: Failed opening required '/home4/indieweb/indiewebseries/public/laravel/laravel.php' (include_path='.:/usr/lib64/php:/usr/lib/php:/usr/share/pear') in /home4/indieweb/indiewebseries/public/index.php on line 34
Just for reference:
// paths.php on line 62:
chdir(__DIR__);
// index.php line 34:
require path('sys').'laravel.php';
Any ideas?
EDIT: I tried @TheShiftExchange suggestion, moved everything outside of docroot, and renamed public to public_html. I now get these php errors:
[07-Feb-2013 05:38:25] PHP Warning: chdir() [<a href='function.chdir'>function.chdir</a>]: No such file or directory (errno 2) in /home4/indieweb/paths.php on line 62
[07-Feb-2013 05:38:25] PHP Fatal error: require() [<a href='function.require'>function.require</a>]: Failed opening required '/home4/indieweb/public_html/laravel/laravel.php' (include_path='.:/usr/lib64/php:/usr/lib/php:/usr/share/pear') in /home4/indieweb/public_html/index.php on line 34
Solución
Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow