PHP Classes

WayMaker PHP Get Route Parameters: Parse request route path to extract its parameters

Recommend this page to a friend!
  Info   Documentation   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 12 All time: 11,395 This week: 673Up
Version License PHP version Categories
waymaker 1.0GNU General Publi...5HTTP, PHP 5, Parsers
Description 

Author

This class can parse the request route path to extract its parameters.

It can take a string with an HTTP route specification as a parameter and parses it to extract its parameters.

Currently, it can extract the route controller name and a list of parameter names that may define the actions that a controller may execute.

Picture of Ali YILMAZ
  Performance   Level  
Name: Ali YILMAZ <contact>
Classes: 16 packages by
Country: Turkey Turkey
Age: ???
All time rank: 249042 in Turkey Turkey
Week rank: 178 Up2 in Turkey Turkey Up
Innovation award
Innovation award
Nominee: 8x

Documentation

What is wayMaker ?

It is used to separate the way and parameters.

data:

$str = 'app/controller:insert@redirect';
// $str = 'app/controller:insert';
// $str = 'app/controller';

Out-of-class use:

code:

require_once('Mind.php');
$m = new Mind();
print_r($m::aliyilmaz('wayMaker')->wayMaker($str));

When using it in the class:

code:

print_r(self::aliyilmaz('wayMaker')->wayMaker($str));

output:

Array
(
    [way] => app/controller
    [params] => Array
        (
            [0] => insert
            [1] => redirect
        )

)

Dependencies

This package has no dependencies.

License

Instructions and files in this directory are shared under the GPL3 license.


  Files folder image Files (3)  
File Role Description
Files folder imagesrc (1 file)
Accessible without login Plain text file LICENSE Lic. License text
Accessible without login Plain text file README.md Doc. Documentation

  Files folder image Files (3)  /  src  
File Role Description
  Plain text file wayMaker.php Class Class source

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 100%
Total:12
This week:0
All time:11,395
This week:673Up