public function head($url) {
    if(!$this->db) {
      throw new SagException('No database specified');
    }

    //The first char of the URL should be a slash.
    if(strpos($url, '/') !== 0) {
      $url = "/$url";
    }

    if($this->staleDefault) {
      $url = self::setURLParameter($url, 'stale', 'ok');
    }

    //we're only asking for the HEAD so no caching is needed
    return $this->procPacket('HEAD', "/{$this->db}$url");
  }
public function head($url) {
    if(!$this->db) {
      throw new SagException('No database specified');
    }

    //The first char of the URL should be a slash.
    if(strpos($url, '/') !== 0) {
      $url = "/$url";
    }

    if($this->staleDefault) {
      $url = self::setURLParameter($url, 'stale', 'ok');
    }

    //we're only asking for the HEAD so no caching is needed
    return $this->procPacket('HEAD', "/{$this->db}$url");
  }
public function head ( $ url ) { if ( ! $ this -> db ) { throw new SagException ( 'No database specified' ) ; } //The first char of the URL should be a slash. if ( strpos ( $ url , '/' ) !== 0 ) { $ url = "/$url" ; } if ( $ this -> staleDefault ) { $ url = self :: setURLParameter ( $ url , 'stale' , 'ok' ) ; } //we're only asking for the HEAD so no caching is needed return $ this -> procPacket ( 'HEAD' , "/{$this->db}$url" ) ; }
Performs an HTTP HEAD operation for the supplied document. This operation
does not try to read from a provided cache, and does not cache its
results.

@see http://wiki.apache.org/couchdb/HTTP_Document_API#HEAD

@param string $url The URL, with or without the leading slash.
@return mixed
Performs an HTTP HEAD operation for the supplied document . This operation does not try to read from a provided cache and does not cache its results .