Created
June 6, 2011 08:16
-
-
Save ludofleury/1009919 to your computer and use it in GitHub Desktop.
Use multiple routing files.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Default rules =============================================================== | |
homepage: | |
url: / | |
param: | |
module: home | |
action: index | |
sf_format: html | |
<?php foreach(glob(dirname(__FILE__).DIRECTORY_SEPARATOR.'routing'.DIRECTORY_SEPARATOR.'*.yml') as $yml){ require($yml); echo "\n"; } ?> |
Your tips on "\n" is awesome, I had some prob which forced me to make the new line into my separate routing files ;)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I think it's better to use :
require is faster than require_once and echo "\n"; is there to enforce new line :)