xml


Posted on 16th Feb 2014 07:03 pm by admin

<?php

echo "<h1>XML Articles</h1>";

Did you know?Explore Trending and Topic pages for more stories like this.
$home="http://xml.x-alt.com/";
// load the studentphones.xml file
$channel = simpleXML_load_file('http://xml.x-alt.com/');




// draw a table and column headers
echo "<table border="1">";

//echo "<th>Grade</td><th>Result</th>n";


// iterate through the grade nodes displaying the contents
foreach ($channel->item as $channel) {

echo "<tr>";
echo "<td><a href=" . $home . $channel->link . ">" . $channel->title . "</a>" . "</td>" ;
echo "</tr>";

echo "<tr>";
echo "<td>{$channel->category}</td>";
echo "</tr>";

echo "<tr>";
echo "<td>{$channel->description}</td>";
echo "</tr>";

echo "<tr>";
echo "<td>{$channel->link}</td>";
echo "</tr>n";
}
echo "</table>";
?>

Here I am using a rss feed to display list of articles and the title of the artcles are links that directs the user to the original destination of the article and displays it in full, but i want to display the artcles in my webpage. How can I do this? Do i need to use SOAP?
No comments posted yet

Your Answer:

Login to answer
324 Like 51 Dislike
Previous forums Next forums
Other forums

why preg_match_all does not return the number of matches
My regex looks like

X[^x{4e00}-x{9fa5}]*Y

(where X and Y are two Chinese characters)

this code is not working????
it says this error.. Warning: Division by zero in ..

the variables are correct, so why is th

Problem with the Update command used with a sqldataadapter
I'm connected to a database on an SQL Server and I'm using a sqldataadapter, sqlconnection, sqldatas

what are '%S%', '%E%'
for example when i see Code: [Select]printf("Hello %srn", $name);
what does %s means

Retrieving Data from Two Different Databases
Hello All,

Ran into another problem and would appreciate some help! I have two datab

Help please - How to validate from 2 possible answers
Hi

I hope somebody can help me with what will probably be really simple, I'm pulling my hair

Where is my php.ini???
Hi

First off - apologies - i'm not a coder so this may sound very amateur.

I'm having

Save username into DB
OkaY so I got my blog to actually save the posts and whatever, all I need now is for it to keep the

How to sum these output values
Hi

I need sum the month totals
SELECT region_name, area_name ,SUM (CASE WHEN S

insert/update functions for mysql, what do you think?
I am working on two really simple functions that automatically generate (and execute) insert and upd

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash