Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yii2
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PSDI Army
yii2
Commits
54006fe1
Commit
54006fe1
authored
Oct 21, 2013
by
Alexander Makarov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
typos
parent
808b6579
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
url.md
docs/guide/url.md
+3
-3
No files found.
docs/guide/url.md
View file @
54006fe1
...
...
@@ -8,7 +8,7 @@ This approach allows you to adjust URLs in a single config file without touching
Internal route
--------------
Internal routes and parameters are what you're dealing with when implementing an application us
u
ing Yii.
Internal routes and parameters are what you're dealing with when implementing an application using Yii.
Each controller and its action has a corresponding internal route such as
`site/index`
. Here
`site`
is referred to as
controller ID while
`test`
is referred to as action ID. If controller belongs to a module, internal route is prefixed
...
...
@@ -19,7 +19,7 @@ Creating URLs
As was already mentioned, the most important rule is to always use URL manager to create URLs. Url manages is an
application component with
`urlManager`
id that is accessible both from web and console applications via
`\Yii::$app->urlManager`
and has two following URL creation methods availabe:
`\Yii::$app->urlManager`
and has two following URL creation methods availab
l
e:
-
createUrl($route, $params =
[
])
-
createAbsoluteUrl($route, $params =
[
])
...
...
@@ -97,7 +97,7 @@ Complimentary to creating URLs Yii is handling transforming custom URLs back int
### Strict URL parsing
By default if there's no custom rule for URL and URL matches default format such as
`/site/page`
Yii tries to run a
corresponding controller's action. This beahvior coul
e
be disabled so if there's no custom rule match, a 404 not found
corresponding controller's action. This beahvior coul
d
be disabled so if there's no custom rule match, a 404 not found
error will be produced immediately.
```
php
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment