Services_Delicious
[ class tree: Services_Delicious ] [ index: Services_Delicious ] [ all elements ]

Class: Services_Delicious

Source Location: /Services_Delicious-0.6.0/Services/Delicious.php

Class Overview


Services_Delicious


Author(s):

Version:

  • 0.5

Variables

Methods


Inherited Variables

Inherited Methods


Class Details

[line 56]
Services_Delicious

Client for the REST-based webservice at http://del.ico.us

del.icio.us is a site for social bookmarking, that means that you bookmark your favourite sites, assign them to one or more topics (tags) and other users are able to browse through the bookmarks.

Services_Delicious allows you to

  • get
  • add
  • delete
your bookmarks from PHP.



[ Top ]


Class Variables

$_apiUrl =  'https://api.del.icio.us/v1'

[line 64]

URI of the REST API
  • Access: protected

Type:   string


[ Top ]

$_last_time =  null

[line 96]

Last accessed time
  • Access: protected

Type:   integer


[ Top ]

$_passwd =  null

[line 80]

password
  • Access: protected

Type:   string


[ Top ]

$_us =  null

[line 88]

XML_Unserializer, used to parse the XML
  • Access: protected

Type:   object XML_Unserializer


[ Top ]

$_user =  null

[line 72]

Username
  • Access: protected

Type:   string


[ Top ]



Method Detail

__construct (Constructor)   [line 105]

Services_Delicious __construct( string $user, string $passwd, [ $request = null])

Create a new client
  • Access: public

Parameters:

string   $user     username
string   $passwd     password
HTTP_Request2   $request     

[ Top ]

addPost   [line 393]

boolean addPost( string|array $url, [string $description = null], [string $extended = null], [string $tags = null], [string $date = null], [string $shared = null])

Add a post
  • Access: public

Parameters:

string|array   $url     url or all data for the post
string   $description     description
string   $extended     extended description
string   $tags     tags for the items
string   $date     datestamp
string   $shared     make the item private if "$shared = 'no'"

[ Top ]

deletePost   [line 434]

boolean deletePost( string|array $url, string 1, string 2)

Delete a post
  • Access: public

Parameters:

string   1     description
string   2     extended description
string|array   $url     url or all data for the post

[ Top ]

deleteTagsBundle   [line 230]

void deleteTagsBundle( string $bundle)

Delete a bundle

Parameters:

string   $bundle     bundle name

[ Top ]

getAllPosts   [line 363]

array getAllPosts( string|array 0, string 1)

Get all posts
  • Access: public

Parameters:

string|array   0     one or more tags
string   1     date

[ Top ]

getDates   [line 276]

array getDates( )

Get all dates on which posts have been added.

This will return an associative array containing dates in the keys and their occurences in the values:

  1.  Array
  2.  (
  3.     [2004-11-01=> 1
  4.     [2004-11-02=> 2
  5. )

  • Access: public

[ Top ]

getLastUpdate   [line 451]

string getLastUpdate( )

Returns the last update time for the user
  • Access: public

[ Top ]

getPosts   [line 299]

array getPosts( [string|array $tags = array()], [string $date = null])

Get posts
  • Access: public

Parameters:

string|array   $tags     one or more tags
string   $date     date

[ Top ]

getRecentPosts   [line 332]

array getRecentPosts( [string|array $tags = array()], [integer $max = 15])

Get recent posts
  • Access: public

Parameters:

string|array   $tags     one or more tags
integer   $max     maximum amount

[ Top ]

getTags   [line 147]

array getTags( )

Get all tags

This will return an associative array containing tags in the keys and their occurences in the values:

  1.  Array
  2.  (
  3.     [pear=> 1
  4.     [php=> 2
  5. )

  • Access: public

[ Top ]

getTagsBundles   [line 178]

array getTagsBundles( )

Retrieve all of a user's bundles

This will return an associative array containing bundles in the keys and their tags in the values:

  1.  Array
  2.  (
  3.     [music=> "ipod mp3 music"
  4.  )

  • Access: public

[ Top ]

renameTag   [line 249]

boolean renameTag( string $old, string $new)

Rename a tag
  • Access: public

Parameters:

string   $old     old name
string   $new     new name

[ Top ]

setRequest   [line 127]

void setRequest( $request)

  • Access: public

Parameters:

HTTP_Request2   $request     

[ Top ]

setTagsBundle   [line 207]

boolean setTagsBundle( string $bundle, string|array $tags)

Assign a set of tags to a single bundle
  • Access: public

Parameters:

string   $bundle     bundle name
string|array   $tags     list of tags

[ Top ]


Documentation generated on Wed, 06 Oct 2010 02:00:02 +0000 by phpDocumentor 1.4.3. PEAR Logo Copyright © PHP Group 2004.