PHP file security on webserver

前端 未结 4 1609
北恋
北恋 2021-02-10 17:16

I\'m slowly learning PHP, MySQL, along with some HTML, using localhost as my webserver. However, I\'m starting to wonder how my .php files are going to be secured if I put this

4条回答
  •  萌比男神i
    2021-02-10 17:40

    No. the php is parsed if the page is requested over HTTP. The person would have to know a vulnerability in your app, Apache or PHP or have some other access such as FTP.

    You can move the files out of your wwwroot and reference them elsewhere. Also, never name your include files as .inc. always name them `.php.

提交回复
热议问题