I am creating API from demo version of
http://code.google.com/apis/base/samples/php/php-sample.html
with itemtype='Products'
The problem is where can I obtain link with the rel="next" for item
feeds?
My code is :
function getItems($token) {
$ch = curl_init(); /* Create a CURL handle. */
global $developerKey, $itemsFeedURL;
curl_setopt($ch, CURLOPT_URL, $itemsFeedURL . "?max-results=50");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, array(
'Content-Type: application/atom+xml',
'Authorization: AuthSub token="' . trim($token) . '"',
'X-Google-Key: key=' . $developerKey
));
$result = curl_exec($ch); /* Execute the HTTP command. */
curl_close($ch);
/* Parse the resulting XML. */
$xml_parser = xml_parser_create();
xml_set_element_handler($xml_parser, "startElement", "endElement");
xml_set_character_data_handler($xml_parser, "characterData");
xml_parse($xml_parser, $result);
xml_parser_free($xml_parser);
}
To list items I have used max-results=50 as above but I have round
about 1000 products. I want to display 100 products per page. How can
I do that?
If any one know the solution of this problem then please send a reply.
I really thankful to you.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Base Data API" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/google-base-data-api?hl=en
-~----------~----~----~----~------~----~------~--~---