相关疑难解决方法(0)

在金字塔中通过 https 提供静态文件

我想通过 request.static_url('some_file') 在金字塔中提供静态文件。由于多项服务,我的模板有如下几行:

<script type="text/javascript" src="${request.static_url('dbas:static/first')}"></script>
<script type="text/javascript" src="${request.static_url('websocket:static/second')}"></script>
Run Code Online (Sandbox Code Playgroud)

但不幸的是,方法 static_url() 只提供带有http作为 url_scheme 的链接,但我想要https。我怎样才能做到这一点?

谢谢!

https static http url-scheme pyramid

2
推荐指数
1
解决办法
922
查看次数

标签 统计

http ×1

https ×1

pyramid ×1

static ×1

url-scheme ×1