phpでrssの情報を抜き出したい場合は、titleやlinkの要素は以下の通りで抜き出せます。
<?php // Load and parse the XML document
$rss = simplexml_load_file('http://partners.userland.com/nytRss/nytHomepage.xml');
$title = $rss->channel->title;
?>
…
根本的な解決ではないかもしれませんが、「Cannot use object of type stdClass as array」エラーが出る場合は、配列の扱い方を以下のように変更する事で解決しました。
$row[“catID”]
↓
$row->catID
graffiti on the web
この投稿へのコメント
コメントはまだありません。