从模板访问文件

时间:2014-03-13 18:57:07

标签: django django-templates

我想知道是否有办法在我的Django中从模板(例如:mytemplate.html)访问/获取目录(例如:tmpdir)中文件(例如:myfile.pdb)的路径项目如下。我想的是,

{{ /tmpdir/myfile.pdb }} 

在模板文件中。

MyProject
|
|_myapp
|
|_tmpdir
|     |_myfile.pdb
|
|_templates
|     |_mytemplate.html

非常感谢提前。

0 个答案:

没有答案
相关问题