This is a small php which will read the youtube RSS feed. What I want to do is convert it into object oriented. Using class and function. I am new to object oriented, can some body show me a way how and where to start with? I have read the acticle from php dot net but still I am a bit confuse.
a small example will be appreciate
thank you for your help
<?php
$html = "";
$url = "http://gdata.youtube.com/feeds/api/users/Sindrannaras/uploads";
$xml = simplexml_load_file($url);
for($i = 0; $i < 10; $i++){
$author = $xml->entry[$i]->author->name;
$id = $xml->entry[$i]->id;
$id = str_replace("http://gdata.youtube.com/feeds/api/videos/","",$id);
$title = $xml->entry[$i]->title;
$content = $xml->entry[$i]->content;
$html .= "<div><h3>$title</h3>";
$html .= " $id<br /> $content<br />";
$html .= "<hr /></div>";
}
echo $html;
?>