Skip to content

This is a simple URL Router module for Scriptor CMS.

Notifications You must be signed in to change notification settings

bigin/SimpleRouter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 

Repository files navigation

SimpleRouter

The SimpleRouter module provides URL routing functionality for your Scriptor application.

Usage

To create custom routes for your application, follow these steps:

  1. Open the _routes.php file.
  2. Use the Route::add() method to add new routes.
  3. Provide the route (path), the closure or controller method to execute when the route is matched, and the associated HTTP verb(s) as parameters to the Route::add() method.

Example:

<?php
use Scriptor\Modules\SimpleRouter\Route;

// Add a route for the root URL
Route::add('/', function() {
    echo 'Welcome to SimpleRouter for Scriptor CMS!';
}, 'GET');

// Execute the router
Route::run();

For more examples and information, you can visit the SimpleRouter documentation.

About

This is a simple URL Router module for Scriptor CMS.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages