PEAR_REST::retrieveData

PEAR_REST::retrieveData() – Retrieve a remote REST resource

Synopsis

require_once '/REST.php';

string|array PEAR_REST::retrieveData ( string $url , array|false $accept = false , bool $forcestring = false )

Description

retrieve the contents of a remote resource.

Parameter

string $url

full URL to this resource

array|false $accept

contents of the accept-encoding header

boolean $forcestring

if TRUE, xml will be returned as a string, otherwise, xml will be parsed using PEAR_XMLParser

Throws

throws PEAR_Error objects are returned on error.

Note

This function can not be called statically.

Retrieve REST data, but always retrieve the local cache if it is available. (Previous) Save the value retrieved from a remote REST resource in the local cache. (Next)
Last updated: Sat, 16 Feb 2019 — Download Documentation
Do you think that something on this page is wrong? Please file a bug report.
View this page in:
  • English

User Notes:

There are no user contributed notes for this page.