简体   繁体   English

从网页创建RSS提要/从外部网页显示更改

[英]Create RSS feed from webpage/ Display changes from external webpage

I am Creating a web application that will get homework from schools website. 我正在创建一个Web应用程序,它将从学校网站上获得作业。 I have been creating rss feeds for the website using dapper Creating an rss feed converting that into html and then putting that into an Iframe on my website. 我一直在使用dapper为网站创建rss提要。创建一个rss提要,将其转换为html,然后将其放入我网站上的iframe中。 I think there has to be a better way to do this. 我认为必须有一种更好的方法来做到这一点。 I don't care what language this would be done in but i would prefer to do it client-side with php or javascript. 我不在乎将使用哪种语言,但是我更愿意在客户端使用php或javascript。 I'm intermidiete level php and not so good at java script. 我是中级php,不太擅长Java脚本。 If you could provide detailed explanation with some code that would be great. 如果您可以提供一些代码的详细说明,那将是很好的。 also I have legal permission from my school which will be the first for this to go live to get the homework. 我还获得了学校的法律许可,这将是第一个为此目的而开展的作业。

I'm assuming you are about create an php application to retrieve the rss from external site (which already have a specific url). 我假设您要创建一个php应用程序以从外部站点(已经有特定的URL)检索rss。 Well, i think its better to build a public API first at the source app/external site, to get more multimedia support. 好吧,我认为最好先在源应用程序/外部站点上构建公共API,以获得更多的多媒体支持。

But if you're have no problem with parsing an xml format into html directly, then you can use cURL instead iFrame(or if you didnt have cURL installed in your php, you can modify lil bit and use my Proxy Library ,a PHP class which enables you to make call to internal and external site with general HTTP request by opening a socket connection to the remote host, originally writen as Codeigniter Library.) 但是,如果您直接将xml格式解析为html没问题,则可以使用cURL代替iFrame(或者如果您的php中没有安装cURL,则可以修改lil位并使用我的Proxy Library ,一个PHP类通过打开到远程主机的套接字连接(最初写为Codeigniter库),您可以使用常规HTTP请求调用内部和外部站点。)

That way, it will be easier to presenting a html view/page rather than proccess it via iFrame. 这样,呈现html视图/页面比通过iFrame进行处理要容易得多。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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