Yaf_Config::addConfig
(Since Yaf 1.0.0.5)
$routers_config一个Yaf_Config_Abstract的实例, 它包含了一簇路由协议的定义, 一个例子是:
例 11.83. INI路由协议簇的例子
;ini配置文件
[product]
routes.regex.type="regex"
routes.regex.route="#^list/([^/]*)/([^/]*)#"
routes.regex.default.controller=Index
routes.regex.default.action=action
routes.regex.map.1=name
routes.regex.map.2=value
routes.simple.type="simple"
routes.simple.controller=c
routes.simple.module=m
routes.simple.action=a
routes.supervar.type="supervar"
routes.supervar.varname=r
routes.rewrite.type="rewrite"
routes.rewrite.route="/product/:name/:value"
routes.rewrite.default.controller=product
routes.rewrite.default.action=info