Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
adding rss feeds to a webpage in php
Old 06-30-2008, 07:52 AM adding rss feeds to a webpage in php
Junior Talker

Posts: 1
Name: Helena
Trades: 0
Hello, i have developed a website and i am trying to add a rss feed to it. This is my first attempt at this. I found a helpful site on the internet that instructed me to download some files and upload them to my server and make a simple modification to my code which is adding this code to what i have: <?php include('http://www.yourserver.com/rss2html.php?XMLFILE=http://ww w.searchenginewatch.com/sew.xml&TEMPLATE=http://www.yourserver.or g/template1.html&MAXITEMS=20 target="_blank">'); ?>

i made sure everything was on the same line (i.e the parameter for the include function) and did the necessary substitution in the include function. i.e with my server url and stuff. I also uploaded the files to my server. The unfortunate thing is that when i view the page in the browser, i get this error:

Warning: include(rss2html.php?XMLFILE=http://www.searchenginewatch.com&TEMPLATE=template.html&M AXITEMS=1&target="_blank">) [function.include]: failed to open stream: Invalid argument in C:\Program Files\xampp\htdocs\test.php on line 2

Warning: include() [function.include]: Failed opening 'rss2html.php?XMLFILE=http://www.searchenginewatch.com&TEMPLATE=template.html&M AXITEMS=1&target="_blank">' for inclusion (include_path='.;C:\Program Files\xampp\php\pear\') in C:\Program Files\xampp\htdocs\test.php on line 2what do i do pls.

korkor
korkor is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 06-30-2008, 12:01 PM Re: adding rss feeds to a webpage in php
rogem002's Avatar
PHP Chap

Posts: 843
Name: Mike
Location: United Kingdom
Trades: 0
The code should be:
PHP Code:
<?php 
include('http://www.yourserver.com/rss2html.php?XMLFILE='.urlencode('http://ww w.searchenginewatch.com/sew.xml').'&TEMPLATE='.urlencode('http://www.yourserver.or g/template1.html').'&MAXITEMS=20'); 
?>
__________________
My Blog/Site:
Please login or register to view this content. Registration is FREE

Last edited by rogem002; 06-30-2008 at 12:02 PM..
rogem002 is offline
Reply With Quote
View Public Profile Visit rogem002's homepage!
 
Reply     « Reply to adding rss feeds to a webpage in php
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 1.01707 seconds with 12 queries