简体   繁体   中英

Facebook app landing page to be index.php

I am looking to execute some php code on the default landing page for my Facebook app but the app url currently only searches for index.html. Is there a way in which this landing page can be a php page instead of just being an html page?

Update: How about being able to use: www.example.com/index.php

The configuration under Canvas Page only looks for a URL address with a / at the end of it so does not need a ending page instead just needs a folder.

Maybe I am missing something here.

Thanks.

在此输入图像描述

As @MozMorris showed, you can include '?' to tell facebook that the url is of a dynamic page and not a static one. But you can always set the order in which the server looks for the file to serve in case it was not specific.

In apache for example you can use the .htaccess file for that, as explained in Set Your Directory Index (Homepage) Using .htaccess . That way you can still end the url in the settings with '/' and have it served by index.php and not index.html .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM