Download the PHP package dgtlss/columbus without Composer
On this page you can find all versions of the php package dgtlss/columbus. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package columbus
🧭 Columbus
Columbus is a lightweight composer package that allows you to quickly and easily generate sitemaps for your Laravel application.
Installation
You can install the package via composer:
Once installed you can publish the config file and generate the middleware required for Columbus to work. The middleware tells Columbus which routes should be added to the sitemap, and which should be ignored.
Once you have initialised Columbus you will need to add the middleware to your app/Http/Kernel.php
file. You can do this by adding the following line to the $routeMiddleware
array:
Now that the middleware has been added to your laravel application you can generate your sitemap by running the following command:
This will generate a sitemap.xml
file in your public directory. This will now be available by going to yourdomain.test/sitemap
Usage
Now that we have successfully installed and configured Columbus you can start adding routes to your sitemap. You can do this by adding the Mappable
middleware to the routes that you want to be included in the sitemap.xml
file. When Columbus initialised it added a premade route group & middleware to your routes/web.php
file. You can add routes to this group like so:
Notes
-
By default Columbus will only add
GET
routes to your sitemap. If you want to change this you can do so inside ofconfig/columbus.php
- Please note: Routes with variables currently do not work with Columbus. This is something that will be added in the future.