Skip to content

PHP Class for working with zotero items in the ATOM response from zotero's API

Notifications You must be signed in to change notification settings

patrickmj/ZItem

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Classes in ZItem are meant to help work with the Zotero items that appear in the ATOM response. (See http://www.zotero.org/support/dev/server_api)
Part of the goal is to make them work well in conjunction with Jeremy Boggs' phpZotero class http://github.com/clioweb/phpZotero


An item can be passed either as a string of XML or as the DOMElement.

If you use the ARC framework for RDF (http://arc.semsol.org), the getItemAsRdf method will build BIBO-based rdf for the item 

phpZoteroEntry


Methods:

getFields()
returns the array of the fields in the form array('fieldName' => 'fieldValue')


fieldExists($field)
checks if the field exists


getFieldValue($field)
gets the value of the field

getFieldsAsJSON()
returns the fields as a JSON object


getItemAsJSON()
returns all information about the item as a JSON object

getItemAsRdf($itemURI, $format)
$itemURI is the uri to assign to the item
$format is the serialization format for the RDF, one of 'rdf/xml' (default) , 'rdf/json', 'ntriples', 'turtle'



phpZoteroEntries:
 

About

PHP Class for working with zotero items in the ATOM response from zotero's API

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages