【问题标题】:Having issues with .php files and the GAE.php 文件和 GAE 存在问题
【发布时间】:2020-06-02 21:12:21
【问题描述】:

我正在尝试获取一份联系表来处理我的 GAE。我已经完成了 app.yaml,并且它适用于除 .php 文件之外的所有内容,当您尝试进入网页时,它会显示 No web page was found for the web address。这些文件都在正确的目录中。我最初的表单为 form.php,但在部署时显示:WARNING: The URL path "/form" is reserved and will not be matched. 所以我将其更改为contact.php,但仍然显示相同的错误。你们对我应该尝试什么有什么建议吗? contact.php 中有表单,我也有contact_control.php 来进行表单验证和发送电子邮件。

谢谢!

#service: default
service: test-landing
runtime: php55
api_version: 1
threadsafe: true

handlers:
- url: /
  static_files: www/index.html
  upload: www/index.html
  secure: always

- url: /(.+\.php)$
  script: assets/\1
  secure: always

- url: /home
  static_files: www/index.html
  upload: www/index.html
  secure: always

- url: /news
  static_files: www/news.html
  upload: www/news.html
  secure: always

- url: /terms
  static_files: www/terms.html
  upload: www/terms/news.html
  secure: always

- url: /privacy
  static_files: www/privacy.html
  upload: www/privacy.html
  secure: always

- url: /faq
  static_files: www/faq.html
  upload: www/faq.html
  secure: always

- url: /contact
  script: /contact.php
  secure: always
- url: /contact
  static_files: /contact.php
  upload: /contact.php
  secure: always

- url: /contact_control
  script: www/contact_control.php
  secure: always

- url: /(.*)
  static_files: www/\1
  upload: www/(.*)
  secure: always

【问题讨论】:

    标签: php html google-app-engine configuration yaml


    【解决方案1】:

    您似乎需要配置 app.yaml 以识别和使用 Google App Engine 上的 PHP 文件。

    我建议您查看以下有关如何配置您的 app.yaml 以使用 PHP 的文档。

    除此之外,还有以下文档,关于如何配置您的 App Engine 以与 PHP 一起正常工作,我建议您看一下 - 它们实际上是快速入门文档,这似乎是您的确切位置是。 :)

    如果这些信息对您有帮助,请告诉我!

    【讨论】:

      猜你喜欢
      • 2014-10-24
      • 2011-11-29
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-05-30
      • 2013-10-21
      • 2011-05-23
      相关资源
      最近更新 更多