PhpBase - GoogleBaseに投稿するためのPHPライブラリ
2005年12月05日-
スポンサード リンク
PhpBase (php library for submiting to Google Base)

GoogleBaseに投稿するためのPHPライブラリが公開されました。
クラスベースで結構使いやすくなってるみたいです。内部的にはFTPを使ってるみたいなんですがGoogleBaseってFTPでUPできるんですかね。
次のように簡単なコードでGoogleBaseへの投稿が可能になります。

GoogleBaseに投稿するためのPHPライブラリが公開されました。
クラスベースで結構使いやすくなってるみたいです。内部的にはFTPを使ってるみたいなんですがGoogleBaseってFTPでUPできるんですかね。
次のように簡単なコードでGoogleBaseへの投稿が可能になります。
<?php
require_once('phpbase/PhpBase.php');
$PhpBase =& new PhpBase('Housing');
$PhpBase->setDomain('example.com');
$my_properties = array(
'12-LKF' =>
'title'=>'Nice house on the beach',
'description' => 'Nice house with views to bay,
It has an enormous deck for up to 10 boats' ),
'14-LKF' =>
'title'=>'Apartment in San Francisco',
'description' => 'Cute apartment for sublet in
downtown San Francisco'),
//.........more properties here
);
if($PhpBase->addItems($my_properties)){
if($PhpBase->send('username',
'password', 'filename')){
echo "Data was submitted
successfully to Google Base";
}else{
echo "There was an error on
the FTP connection to Google Base";
}
}else{
echo "Ooops, there where some
problems when preparing the data feed.
These are the attributes
where we found the problems ";
echo join($PhpBase->getAttributesWithProblems());
}
if(!$PhpBase->addItem($single_property_array)){
echo "There was an error on ".
$PhpBase->lastError();
}
$PhpBase->send('username',
'password', 'filename');
?>
スポンサード リンク
Advertisements
SITE PROFILE
最新のブログ記事(新着順)
- 2012年5月16日 管理人のブックマーク
- jQueryとCSS3を使ったPath風の円形メニューサンプル
- GoogleのPageRankをPHPから得られるPEARパッケージ「Services_PageRank」
- 2012年5月15日 管理人のブックマーク
- フリーのアイコンフォント10まとめ
- マウス位置が光源となりオブジェクトに陰影をつけるjQueryプラグイン「RealShadow」
- 2012年5月14日 管理人のブックマーク
- これは必見のWEBデザインの近未来。HTML5で構築されたサイト45
- クールなドアノブ風の%グラフを描画できるjQuery Knob
- 2012年5月11日 管理人のブックマーク
- 過去のエントリ



















間違いの指摘をしていただける方はメール、あるいはTwitter/FBでお願いします(クリック)



