mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-02-07 12:36:25 +00:00
Removing whitespace and adding some more documentation.
This commit is contained in:
parent
4c3736a68a
commit
025ba23886
1 changed files with 3 additions and 8 deletions
|
@ -300,7 +300,9 @@ class Router {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Specifies what named parameters CakePHP should be parsing. The most common setups are:
|
* Specifies what named parameters CakePHP should be parsing out of incoming urls. By default
|
||||||
|
* CakePHP will parse every named parameter out of incoming URLs. However, if you want to take more
|
||||||
|
* control over how named parameters are parsed you can use one of the following setups:
|
||||||
*
|
*
|
||||||
* Do not parse any named parameters:
|
* Do not parse any named parameters:
|
||||||
*
|
*
|
||||||
|
@ -342,8 +344,6 @@ class Router {
|
||||||
* @return array
|
* @return array
|
||||||
*/
|
*/
|
||||||
public static function connectNamed($named, $options = array()) {
|
public static function connectNamed($named, $options = array()) {
|
||||||
|
|
||||||
|
|
||||||
if (isset($options['argSeparator'])) {
|
if (isset($options['argSeparator'])) {
|
||||||
self::$named['separator'] = $options['argSeparator'];
|
self::$named['separator'] = $options['argSeparator'];
|
||||||
unset($options['argSeparator']);
|
unset($options['argSeparator']);
|
||||||
|
@ -385,7 +385,6 @@ class Router {
|
||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
public static function defaults($connect = true) {
|
public static function defaults($connect = true) {
|
||||||
|
|
||||||
self::$_connectDefaults = $connect;
|
self::$_connectDefaults = $connect;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -403,7 +402,6 @@ class Router {
|
||||||
* @return array Array of mapped resources
|
* @return array Array of mapped resources
|
||||||
*/
|
*/
|
||||||
public static function mapResources($controller, $options = array()) {
|
public static function mapResources($controller, $options = array()) {
|
||||||
|
|
||||||
$options = array_merge(array('prefix' => '/', 'id' => self::$__named['ID'] . '|' . self::$__named['UUID']), $options);
|
$options = array_merge(array('prefix' => '/', 'id' => self::$__named['ID'] . '|' . self::$__named['UUID']), $options);
|
||||||
$prefix = $options['prefix'];
|
$prefix = $options['prefix'];
|
||||||
|
|
||||||
|
@ -430,7 +428,6 @@ class Router {
|
||||||
* @return array A list of prefixes used in connected routes
|
* @return array A list of prefixes used in connected routes
|
||||||
*/
|
*/
|
||||||
public static function prefixes() {
|
public static function prefixes() {
|
||||||
|
|
||||||
return self::$_prefixes;
|
return self::$_prefixes;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -441,8 +438,6 @@ class Router {
|
||||||
* @return array Parsed elements from URL
|
* @return array Parsed elements from URL
|
||||||
*/
|
*/
|
||||||
public static function parse($url) {
|
public static function parse($url) {
|
||||||
|
|
||||||
|
|
||||||
if (!self::$_defaultsMapped && self::$_connectDefaults) {
|
if (!self::$_defaultsMapped && self::$_connectDefaults) {
|
||||||
self::__connectDefaultRoutes();
|
self::__connectDefaultRoutes();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue