網頁

2011年7月1日 星期五

Python Config Yaml File

Last Update: 2011/07/01 17:32+08
Type: Note


• Static Page/File and so on:

- url: /common/menu.html
static_files: common/menu.html
upload: common/menu.html



• Static Directory

- url: /css
static_dir: css



• Script

- url: /product
script: script/product.py



• Extension/Regular on one directory
\1 : url 的 regular

- url: /(common/.*\.(html|png))
static_files: \1
upload: (common/.*\.(html|png))

#Rewrite Path
- url: /(.*\.(html|png))
static_files: common/\1
upload: common/(.*\.(html|png))