PHP and XML with SimpleXml Object

Description

This Tutorial Shows You how To use Rss feed In php.

Reviews
Shared by: Harsh Gupta
Categories
Tags
Stats
views:
371
rating:
not rated
reviews:
0
posted:
4/13/2008
language:
English
pages:
0
File Name :- example.php channel as $pChild) { // Print our channel specific information, this should be // easy to understand, basically we're grabbing the // title, descripting and link nodes and outputting their values echo "

" . $pChild->title . "

\n"; echo "

\n"; echo $pChild->description . "
\n"; echo sprintf('Visit us at %s
' . "\n", $pChild->link, $pChild->link); echo "

\n"; // Now we want to loop through the items inside this channel foreach ($pFile->channel->item as $pItem) { echo "

\n"; // If this item has child nodes as it should, // loop through them and print out the data foreach ($pItem->children() as $pChild) { // We can check the name of this node using the getName() method. // We can then use this information, to, for example, embolden // the title or format a link switch ($pChild->getName()) { case 'title': echo "$pChild
\n"; break; case 'link': printf('\n"; break; } } echo "

\n"; } } ?> Now Xml File :- talkphp.xml TalkPHP http://www.talkphp.com Discuss PHP and other various web related topics in a knowledgeable and friendly community. en http://www.talkphp.com/images/misc/rss.jpg TalkPHP http://www.talkphp.com <![CDATA[G'day]]> http://www.talkphp.com/showthread.php?t=1107&goto=newpost Forum: Member Introductions Posted By: Shaun Post Time: 09-14-2007 at 01:15 PM AJAX File Uploader http://www.talkphp.com/showthread.php?t=1106&goto=newpost Forum: Javascript, AJAX, E4X Posted By: CreativeLogic Post Time: 09-13-2007 at 07:32 PM Some sites of mine... http://www.talkphp.com/showthread.php?t=1104&goto=newpost Forum: Show Off Posted By: Craddock Post Time: 09-13-2007 at 04:54 PM The Dangers of the Header Function http://www.talkphp.com/showthread.php?t=1102&goto=newpost Forum: Absolute Beginners Posted By: Wildhoney Post Time: 09-13-2007 at 02:32 PM Help Net Security: Remote Vulnerabilities Discovered in phpMyAdmin http://www.talkphp.com/showthread.php?t=1101&goto=newpost Forum: PHP Freaks Posted By: mike.fro Post Time: 09-12-2007 at 09:17 PM <![CDATA[Davey Shafik's Blog: PHP Streams Rock my World!]]> http://www.talkphp.com/showthread.php?t=1099&goto=newpost Forum: PHP Freaks Posted By: mike.fro Post Time: 09-12-2007 at 08:21 PM PradoSoft.com: PRADO/Wordpress/BBPress integration v1.0... http://www.talkphp.com/showthread.php?t=1100&goto=newpost Forum: PHP Freaks Posted By: mike.fro Post Time: 09-12-2007 at 08:21 PM ProadSoft.com: PRADO/Wordpress/BBPress integration v1.0... http://www.talkphp.com/showthread.php?t=1098&goto=newpost Forum: PHP Freaks Posted By: mike.fro Post Time: 09-12-2007 at 06:13 PM DevShed: Understanding Static Properties with PHP 5 http://www.talkphp.com/showthread.php?t=1097&goto=newpost Forum: PHP Freaks Posted By: mike.fro Post Time: 09-12-2007 at 05:17 PM <![CDATA[Clay Loveless' Blog:]]> http://www.talkphp.com/showthread.php?t=1096&goto=newpost Forum: PHP Freaks Posted By: mike.fro Post Time: 09-12-2007 at 04:12 PM WebReference.com: Class Inheritance with PHP http://www.talkphp.com/showthread.php?t=1095&goto=newpost Forum: PHP Freaks Posted By: mike.fro Post Time: 09-12-2007 at 03:22 PM Bullets not rendering http://www.talkphp.com/showthread.php?t=1094&goto=newpost Forum: XHTML, HTML, CSS Posted By: Haris Post Time: 09-12-2007 at 03:08 PM Community News: Latest PHPClasses.org Releases for 09.12.2007 http://www.talkphp.com/showthread.php?t=1092&goto=newpost Forum: PHP Freaks Posted By: mike.fro Post Time: 09-12-2007 at 02:11 PM <![CDATA[Dave Dash's Blog: SymfonyCamp]]> http://www.talkphp.com/showthread.php?t=1090&goto=newpost Forum: PHP Freaks Posted By: mike.fro Post Time: 09-12-2007 at 02:11 PM <![CDATA[Stefan Mischook's Blog: Object Oriented PHP Tutorial in PDF]]> http://www.talkphp.com/showthread.php?t=1091&goto=newpost Forum: PHP Freaks Posted By: mike.fro Post Time: 09-12-2007 at 02:11 PM

Other docs by Harsh Gupta
Zend framework tutorial
Views: 6939  |  Downloads: 373
PayPal_Sandbox_UserGuide
Views: 105  |  Downloads: 11
An Introduction to URL Rewriting - PHP
Views: 235  |  Downloads: 22
Protect you from session hacking
Views: 175  |  Downloads: 15
wright Portable Php code
Views: 236  |  Downloads: 7
PayPal_Sandbox_UserGuide
Views: 132  |  Downloads: 4
Writing Portable PHP Code.doc
Views: 202  |  Downloads: 5
An Introduction to URL Rewriting - PHP
Views: 180  |  Downloads: 11
How to protect Session Hacking
Views: 780  |  Downloads: 20
PHP and JAVA Conference Presentation
Views: 154  |  Downloads: 16
Related docs
AJAX and PHP
Views: 57  |  Downloads: 3
Advanced XML and Web Services in PHP
Views: 8  |  Downloads: 0
PHP
Views: 1073  |  Downloads: 125
PHP AND AJAX
Views: 412  |  Downloads: 113
Object-Oriented PHP
Views: 324  |  Downloads: 44
XML Tutorial
Views: 801  |  Downloads: 145
XML
Views: 46  |  Downloads: 9
Advanced XML and Web Services in PHP_1_
Views: 5  |  Downloads: 0
PHP and MySQL
Views: 314  |  Downloads: 74
mysql to xml
Views: 110  |  Downloads: 39
PHP and Databases
Views: 92  |  Downloads: 13