Description

This function returns an array or an object of a single publication.

Usage

$publication = get_tp_publication( $id, $output_type );

Parameters

id

(int) The id of the publication.

output_type (optional)

(string) You can choice between:

  • OBJECT (default)
  • ARRAY_A
  • ARRAY_N

Return

(array or object)

An array or object containing all the publication data fields.

The fields returned are:

pub_id

(integer) ID of the publication

title

(string) Title of the publication

type

(string) Type of the publication

bibtex

(string) BibTeX key of the publication

author

(string) The name(s) of the author(s) (in the case of more than one author, separated by and)

editor

(string) The name(s) of the editor(s) (in the case of more than one editor, separated by and)

date

(string) Date of publishing (YYYY-MM-DD)

year

(string) Year of publishing (YYYY)

urldate

(string) Date of visiting (YYYY-MM-DD)

isbn

(string) The ISBN/ISSN number

url

(string) Some URLs

booktitle

(string) The title of the book, if only part of it is being cited

journal

(string) The journal or magazine the work was published in.

volume

(string) Volume of the journal where the work was published

number

(string) Number of the journal where the work was published

pages

(string) Page numbers

publisher

(string) Name of the publisher

address

(string) Publisher’s address (usually just the city, but can be the full address for lesser-known publishers)

edition

(string) Edition of the resource where the publication can be found

chapter

(string) Chapter of the resource where the publication can be found

institution

(string) The institution that was involved in the publishing, but not necessarily the publisher

organization

(string) The conference sponsor

school

(string) The school where the thesis was written

series

(string) The series of books the book was published in

crossref

(string) The key of the cross-referenced entry

abstract

(string) The abstract of the work

howpublished

(string) How it was published, if the publishing method is nonstandard

key

(string)  A hidden field used for specifying or overriding the alphabetical order of entries.

techtype

(string) Additional type of publication (e.g. „Research Note“ for techreport, „{PhD} dissertation“ for phdthesis, „Section“ for inbook/incollection)

note

(string) Miscellaneous extra information

is_isbn

(integer) Says if the type of the number in the isbn field is a ISBN or ISSN number (1|0)

image_url

(string) URL of a publication image

rel_page

(integer) ID of a WordPress post or page

Example

Display the abstract of a publication:

$publication = get_tp_publication( $id );
echo $publication->abstract;

Changelog

  • Since: 3.1.7