开发者

symfony routing problem

I have mp3 catalog portal and I want to customize my urls. I used url for downloading songs - /download/song/:song_id But now I want url to look like /download/song:song_id - symfony doesn't recognize this pattern, :song_id parameter substitutes in url as is, so I get /download/song:son开发者_开发知识库g_id instead of f.e. /download/song14


Solved via adding empty separator_segment: options: { segment_separators: [/, ., -, ''] }

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜