Task #29977

URIs should be lower case by default

Added by Bastian Waidelich almost 4 years ago. Updated almost 4 years ago.

Status:Resolved Start date:2011-09-18
Priority:Should have Due date:
Assigned To:Bastian Waidelich % Done:

100%

Category:MVC - Routing
Target version:TYPO3 Flow Base Distribution - 1.0.0
Sprint: Has patch:
PHP Version: Complexity:

Description

Currently you can force generated URIs to be lower cased by adding "toLowerCase" to the Route configuration.
This should be the default though. The configuration option could be renamed to "keepCase" (This works for the whole route and for individual RouteParts)

Associated revisions

Revision 755a7352
Added by Bastian Waidelich almost 4 years ago

[!!!][TASK] Create lower cased URIs by default

The routing framework is capable of creating case sensitive
URIs so it is possible to resolve different actions depending
on the case of URI segments.

This changes the behavior to convert URIs to lower case by
default as that is the most common requirement.

If you want to keep the case, you can achieve that by setting
toLowerCase to FALSE. This can be done for the whole route or
for specific Route Parts:

-
name: 'Case sensitive Route'
uriPattern: 'posts/{post}/{category}'
defaults:
'@package': 'TYPO3.Blog'
'@controller': 'Post'
'@action': 'index'
'@format': 'html'
toLowerCase: false

-
name: 'Case sensitive Route Part'
uriPattern: 'posts/{post}/{category}'
defaults:
'@package': 'TYPO3.Blog'
'@controller': 'Post'
'@action': 'index'
'@format': 'html'
routeParts:
post:
toLowerCase: false

Note: This is a breaking change in the sense that dynamic route
parts are now resolved to a lower cased string by default.

Change-Id: I572b51af2992e2599b37db3d0e5b31cbb395ece1
Resolves: #29977

History

#1 Updated by Bastian Waidelich almost 4 years ago

  • Subject changed from Routes should be lower case by default to URIs should be lower case by default

#2 Updated by Bastian Waidelich almost 4 years ago

  • Tracker changed from Feature to Task

#3 Updated by Mr. Hudson almost 4 years ago

  • Status changed from Accepted to Under Review

Patch set 1 of change I572b51af2992e2599b37db3d0e5b31cbb395ece1 has been pushed to the review server.
It is available at http://review.typo3.org/5151

#4 Updated by Mr. Hudson almost 4 years ago

Patch set 2 of change I572b51af2992e2599b37db3d0e5b31cbb395ece1 has been pushed to the review server.
It is available at http://review.typo3.org/5151

#5 Updated by Bastian Waidelich almost 4 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

Also available in: Atom PDF