【问题标题】:Config Yaml for folders inside folders in App Engine为 App Engine 中文件夹内的文件夹配置 Yaml
【发布时间】:2019-03-11 10:06:34
【问题描述】:

我有这个应用引擎项目结构:

还有这个 yaml 文件:

但只有chicken.jpg 会出现在index.html 中,而不是img/catsimg/puppys 中的图像。

【问题讨论】:

  • 显示index.html
  • 好吧,它是一堆 ....
  • 最后一个
  • 控制台错误显示这个 加载资源失败:服务器响应状态为 404 ()puppys_1.jpg:1 .....加载资源失败:服务器响应状态为 404 ()puppys_12.jpg:1

标签: google-app-engine yaml


【解决方案1】:

/img 拦截其他人。按以下顺序放置您的 url 处理程序:

- url: /img/puppys
  static_dir: img/puppys

- url: /img/cats
  static_dir: img/cats

- url: /img 
  static_dir: img

【讨论】:

  • 这非常有用,但我发现了其他问题,puppys 和cats 文件夹中的图像是这样的,html 中的puppys_1.jpg 但文件夹内是puppys_1.JPG 这个问题我只在App Engine 中看到过.
  • 我想应用引擎对文件扩展名不区分大小写。
  • 区分大小写
  • 文件扩展名不区分大小写
猜你喜欢
  • 2012-11-19
  • 2015-05-10
  • 1970-01-01
  • 2012-09-06
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2022-01-07
相关资源
最近更新 更多