Do GitHub pages support PHP?

后端 未结 4 2090
说谎
说谎 2020-12-01 18:33

Thank you for taking the time to review my request for help.

I\'ve been using gh-pages to work on a build for a static site and thee server has worked amazing for m

相关标签:
4条回答
  • 2020-12-01 18:44

    I had the job to re-work on a PHP page to be capable with GitHub so it's all AJAX now. Use Ajax instead or similar stuff.
    However, you can provide PHP code as a new committed file/gist/repo if you want to provide only the code instead of running it like what this guy did... And if you want to show a demo of your working PHP code, then

    • use an online environment 3v4l.org
    • or add demos to your repos using package managers like Packagist, Composer

    Just general info.

    0 讨论(0)
  • 2020-12-01 18:57

    Github pages currently do not support PHP as it only supports static website.

    However, if you want to display some dynamic content on your website, you can simply use iframe to display that content, but again it has to be hosted somewhere else.

    Here is something that might be helpful to you: Guide to use Github Pages

    0 讨论(0)
  • 2020-12-01 19:00

    You cannot use php on Github Pages.

    But if you want to use a form on your site, give a try to services like https://formspree.io or http://www.jotform.com/.

    0 讨论(0)
  • 2020-12-01 19:07

    A static site cannot by definition support PHP.

    • Static websites serve content directly from the web-server’s file-system exactly as stored.

    • Dynamic websites generate content live per each request. The request is delegated to a running web-application that builds the content.

    What is a Static Website

    You might be interested in PieCrust. It is a static site generator.

    0 讨论(0)
提交回复
热议问题