Let Wordpress share the same domain root, side-by-side, with Laravel
avexsoft/laravel-sidepress is a Laravel package for let wordpress share the same domain root, side-by-side, with laravel.
It currently has 3 GitHub stars and 13 downloads on Packagist (latest version 1.0.0).
Install it with composer require avexsoft/laravel-sidepress.
Discover more Laravel packages by avexsoft
or browse all Laravel packages to compare alternatives.
Last updated
A Laravel package to let Wordpress share the same domain root, side-by-side.
php artisan down also brings down Wordpress frontend pages| URI | Remarks | |:----|:-----| | https://example.com/ | Can be handled by Laravel or Wordpress | | https://example.com/home | Can be handled by Laravel or Wordpress | | https://example.com/about | Can be handled by Laravel or Wordpress |
PHP is used by 79.1% of all the websites
-- https://w3techs.com/technologies/details/pl-php, 6th Mar 2021
Wordpress is used by... 40.5% of all websites.
-- https://w3techs.com/technologies/details/cm-wordpress, 6th Mar 2021
Codewise, Laravel and Wordpress were built very differently and seemed quite impossible to co-exist until now. Given the numerous other attempts to marry them, we consider ourselves lucky to have chanced upon this approach.
The main benefit here is to include the Wordpress community in our Laravel projects. This package hopes to serve as a progressive step to assimilate Wordpress projects into Laravel.
sidep=1 and performs a redirect()sidep=1, Laravel's public/index.php sends it off to Wordpress/blog, Wordpress now sits on the root domain as a 1st class citizen (almost!).Take a look at contributing.md to see a to do list.
public/.htaccess and break Laravel, monitor this file closelyindex.php will be blocked by Laravel's VerifyCsrfToken middleware, i.e. HTTP 419, and that is actually a good thing. You can add to the middleware's $except list to workaround this. Wordpress comments will work without modification as it POST via wp-comments-post.phpVia Composer
$ composer require avexsoft/laravel-sidepress
# Patch Laravel and create the Wordpress installation shell script
$ php artisan sidepress:install
# Install and configure Wordpress
$ ./sidepress-install.sh
Please see the changelog for more information on what has changed recently.
No tests yet, feel free to submit PRs
$ composer test
Please see contributing.md for details and a todolist.
If you discover any security related issues, please email author email instead of using the issue tracker.
We recommend having a separate database for Wordpress to mitigate any malicious/vunerable plugins.
The MIT License (MIT). Please see the license file for more information.