Pls Any1 Help in solving this Problem of Rss News

Started on the old forum in July 2009 · view the original in the archive · old links redirect here

10 replies · 621 views · started 17 years ago · 1 min read

4 participants
prajwal Junior · 19 posts #1

Hi Coders ,, pls Help me 2 solve dis problem i hav added RSS News Script in my site Wats d Problem Is news of 1st link in any 1 of feed vil be common 2 all links fetched ..

See here for ex: go 2 1st news link in abov page and also check next links all will hav same Title & news content

DEMO: World NEWS

🙁 😐 Pls HELP ME Guys Modify it and make it Work properly as dis link GEOPAK 24x7 RSS NEWS

Here is its Script of d Page:

<?
header("Content-Type: text/html; charset=ISO-8859-1");

echo "<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?>\n";
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" >
<head>
<link rel="stylesheet" type="text/css" href="./Style.css" />
<title>GEOPAK 24x7 RSS NEWS</title>
</head>

<body>
<div class="top">
<img src="./logo.gif" alt="" />
</div>

<div>
<b><small>World News</small></b>
</div>

<div class="content">
<?
$url = "http://newsrss.bbc.co.uk/rss/newsonline_uk_edition/world/rss.xml";
$nocache = rand(0000, 9999);
$Id = $_GET["id"];

if ($Id != "")
{
  $fp = @fopen($url, "r");
  while (!feof($fp))
    $raw .= @fgets($fp, 4096);
  fclose($fp);

  if (eregi("<item>(.*)</item>", $raw, $rawitems))
  {
    $items = explode("<item>", $rawitems[0]);

    for ($i = 0; $i < 1; $i++)
    {
      eregi("<title>(.*)</title>", $items[$id + 1], $title);
      eregi("<description>(.*)</description>", $items[$id + 1], $description);
      eregi("<link>(.*)</link>", $items[$id + 1], $link);
	  echo "Title: " . $title[1] . " <br />\n";

      echo "News: \n";
	  echo $description[1] . " <br />\n\n";
	  echo "<p align=\"center\">\n";
	  echo "<a href=\"./news.php?nocache=" . $nocache . "\">< Back</a>\n";
	  echo "</p>\n";
    }
  }
} else
{
  $fp = @fopen($url, "r");
  while (!feof($fp))
    $raw .= @fgets($fp, 4096);
  fclose($fp);

  if (eregi("<item>(.*)</item>", $raw, $rawitems))
  {
    $items = explode("<item>", $rawitems[0]);

    for ($i = 0; $i < count($items) - 1; $i++)
    {
      eregi("<title>(.*)</title>", $items[$i + 1], $title);
      echo "<a href=\"./news.php?nocache=" . $nocache . "&id=" . $i . "\"><img src=\"./link.gif\" alt=\"\" />" . $title[1] . "</a> <br />\n";
    }
  }
}
?>
</div>

<div class="foot">
<a href="http://Geopakwap.com"><font color="#FFFFFF"><small>HOME</small></font></a>
</div>
</body>

</html>
capofret Developer · 225 posts #2

try to use spiderwap script posted here in the forum, it works fine.

LDSWAPWORLD site closed. im busy with other things in life like facebook , send me PM so i can add you 🙂 www.pinoySG.com

don't ask for help if you're not even helping yourself! i am tired of seeing the line "best site", i want to see something NEW and UNIQUE. maybe if i find one, ill go back to my wap life again.

External image (may be gone)

prajwal Junior · 19 posts #5

brentg wrote: I have the exact same problem

Ya guys this script posted in many forums hav prob . But some of d good n efficient coders hav modified it n using dis in der site pls help me guys by sharing dat ex. Lik dis. News HeadLines

My frnd suggested 2 use horoscope script n change its feed..but using horoscope script will hav some prob.. still i need script like above link .In horoscope script der is an disadvantage if der is a large content in each news d page becomes lengthy . . Visitors will nt go to nxt pages n dey will nt hav any option to select interesting news wat they want they hav to go through each page.. So i m asking here otherwise i wouldnt Pls provide script lik dis pls pls.. 🙂 🙁

capofret Developer · 225 posts #6

edit:

i tried the code u posted, its working fine in my site. i just put it in the public_html folder see this demo

so the script is fine. maybe u have a problem with your hosting

LDSWAPWORLD site closed. im busy with other things in life like facebook , send me PM so i can add you 🙂 www.pinoySG.com

don't ask for help if you're not even helping yourself! i am tired of seeing the line "best site", i want to see something NEW and UNIQUE. maybe if i find one, ill go back to my wap life again.

External image (may be gone)

prajwal Junior · 19 posts #7

capofret wrote: edit: i tried the code u posted, its working fine in my site. i just put it in the public_html folder see this demo so the script is fine. maybe u have a problem with your hosting

i donno why it happens 2me .but did u made any changes lik chmod to 777 lik dat anything .Pls tell me Were hav hosted ur domain i wan2 change mine now.,. I hav hosted mine in manashosting.com there evn youtube script also didnt supported 4me. I donno wats d prob ,i think may be fsockopen & fopen r required which is nt supported in my hosting server.

capofret Developer · 225 posts #8

prajwal wrote: i donno why it happens 2me .but did u made any changes lik chmod to 777 lik dat anything .Pls tell me Were hav hosted ur domain i wan2 change mine now.,. I hav hosted mine in manashosting.com there evn youtube script also didnt supported 4me. I donno wats d prob ,i think may be fsockopen & fopen r required which is nt supported in my hosting server.

I didnt do anything except I just put the script in public_html, and yes my host can also use the youtube script. I got mine from fastnext, reseller account. Free hosts usually have limitations. Just find a good host.

LDSWAPWORLD site closed. im busy with other things in life like facebook , send me PM so i can add you 🙂 www.pinoySG.com

don't ask for help if you're not even helping yourself! i am tired of seeing the line "best site", i want to see something NEW and UNIQUE. maybe if i find one, ill go back to my wap life again.

External image (may be gone)

prajwal Junior · 19 posts #9

capofret wrote: I didnt do anything except I just put the script in public_html, and yes my host can also use the youtube script. I got mine from fastnext, reseller account. Free hosts usually have limitations. Just find a good host.

mine is nt free host i gav 3000rs for 1year for 5gb but then i found many hosts 4 cheap rates . . I did a great mistak dey evn nt refund also.. Its of great loss 2me. . K i ll try out in fastnext .Ur reseller can wit stand how many domains .. n wats d cost,. Give me some details is it fast....

Write your reply now; next you create a free account (or sign in) and it is posted right away. Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close