开发者

I wrote a php file that pulls data from my wordpress website. How do I create a static page that uses this PHP file to get updated periodically?

I wrote a php file that pulls the 5 most recent posts from my wordpress website. I don't 开发者_JAVA百科want the users to directly access this file because then it would query the database every time. How do I create a static page that gets updated using the php file, say, everyday and have the users access that?

This has got to be easy but I'm new to all of this and I'm seeking a solution.


Just create a script that generates the static HTML files, and use a cronjob to call it every night. That's an example.


What's wrong with using RSS? Much better than a custom php script. http://simplepie.org/

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜