Properties

$suwpExport

$suwpExport : 

boolean

Type

$hyperlinkBase

$hyperlinkBase : 

boolean

Type

$wikindx

$wikindx : 

boolean

Type

$preview

$preview : 

boolean

Type

$output

$output : 

boolean

Type

$rtfBibExport

$rtfBibExport : 

boolean

Type

$dir

$dir : 

$dir is the path to STYLEMAP.php etc.

Type

$items

$items : 

array

Type

Methods

__construct()

__construct(  output = html) : 

CITEFORMAT

Parameters

output

Default is 'html'

Returns

initialise()

initialise() : 

Some system initialisation

Returns

citationToArrayEndnoteStyle()

citationToArrayEndnoteStyle() : 

Reformat the array representation of citation into a more useable format - Endnote style citations

Returns

citationToArrayInTextStyle()

citationToArrayInTextStyle() : 

Reformat the array representation of citation into a more useable format - In-text style citations

Returns

parseIndependent()

parseIndependent( array) : 

Parse independent strings of templates

Parameters

array

Returns

process()

process() : \Complete

Loop through $this->items

Returns

\Complete —

string ready for printing to the output medium.

endnoteStyle()

endnoteStyle() : \Complete

Endnote style citations

Returns

\Complete —

string ready for printing to the output medium.

inTextStyle()

inTextStyle() : \Complete

In-text style citations

Returns

\Complete —

string ready for printing to the output medium.

subsequentSentenceCheck()

subsequentSentenceCheck() : 

Use subsequentTemplate only if creator surname, title or shortTitle exists in same sentence as citation

Returns

sameSentence()

sameSentence(  text) : 

Discover if creator name(s) is in same sentence and split citation if requested.

Parameters

text

Returns

checkTemplateFields()

checkTemplateFields(mixed||string|int  template) : 

For any replacement templates used for in-text citations, check we have fields to populate it with. If not, return FALSE to indicate that we use original $this->template

Parameters

mixed||string|int template

Returns

disambiguate()

disambiguate() : 

Disambiguate any ambiguous citations

Returns

findAlternates()

findAlternates(mixed||string|int  typeArray) : 

Find alternate fields dependent on previous or following fields and deal with accordingly.

Parameters

mixed||string|int typeArray

Returns

map()

map(mixed||string|int  template) : 

Map the $item array against the style array and produce a string ready to be formatted for bold, italics etc.

Parameters

mixed||string|int template

Returns

ready for printing to the output medium.

formatCitationId()

formatCitationId(  pre,   post) : 

Format the citation ID for endnote-style citations

Parameters

pre

pre-characters

post

post-characters

Returns

createStyleSheet()

createStyleSheet() : 

Create RTF stylesheet

Returns

rtfPageNumbers()

rtfPageNumbers(  session) : 

Format RTF Page numbers

Parameters

session

Returns

hyperLink()

hyperLink(  citation) : 

Format hyperlinks and clean up citation

Parameters

citation

Returns

ready for printing to the output medium.

formatNames()

formatNames(mixed||string|int  creators,   citationId) : 

Format creator name lists (authors, editors, etc.)

Parameters

mixed||string|int creators

Multi-associative array of creator names e.g. this array might be of the primary authors:

array([0] => array(['surname'] => 'Grimshaw', ['firstname'] => Mark, ['initials'] => 'N', ['prefix'] => ),
   [1] => array(['surname'] => 'Witt', ['firstname'] => Jan, ['initials'] => , ['prefix'] => 'de'))
citationId

Returns

checkInitials()

checkInitials(mixed||string|int  creator,   initialsStyle,   firstNameInitial) : 

Handle initials.

Parameters

mixed||string|int creator

Associative array of creator name e.g.

array(['surname'] => 'Grimshaw', ['firstname'] => Mark, ['initials'] => 'M N G', ['prefix'] => ))

Initials must be space-delimited.

initialsStyle
firstNameInitial

Returns

Formatted string of initials.

formatShortTitle()

formatShortTitle(  pString,   delimitLeft = FALSE,   delimitRight = FALSE) : 

Format a shortTitle. Anything enclosed in $delimitLeft...$delimitRight is to be left unchanged

Parameters

pString

Raw title string.

delimitLeft

Default FALSE

delimitRight

Default FALSE

Returns

Formatted title string.

formatTitle()

formatTitle(  pString,   delimitLeft = FALSE,   delimitRight = FALSE) : 

Format a title. Anything enclosed in $delimitLeft...$delimitRight is to be left unchanged

Parameters

pString

Raw title string.

delimitLeft

Default FALSE

delimitRight

Default FALSE

Returns

Formatted title string.

formatUrl()

formatUrl(  url) : 

Format URL.

Parameters

url

Returns

formatPrePostText()

formatPrePostText(  preText,   postText) : 

Format preText and postText.

[cite]23:34-35|see ` for example[/cite] (as used by WIKINDX)

Parameters

preText
postText

Returns

formatPages()

formatPages(  start,   end = FALSE) : 

Format pages.

$this->style['pageFormat']: 0 == 132-9 1 == 132-39 2 == 132-139

Parameters

start

Page start.

end

Page end.

Returns

of pages.

formatYear()

formatYear(  year) : 

Format publication year.

$this->style['yearFormat']: 0 == 1998 1 == '98 2 == 98

Parameters

year

Returns

of year.

multiple()

multiple(mixed||string|int  multiples) : 

Format multiple citations

Parameters

mixed||string|int multiples

Citations

Returns

processEndnoteBibliography()

processEndnoteBibliography(mixed||string|int  rows, mixed||string|int  ids) : 

Collate and format the bibliography for endnote-style citations. Must be processed in the same order as $ids.

Where the id nos. are the same for each resource (endnote-style citations), store the bibliographic id order with an incrementing citation id no.

Parameters

mixed||string|int rows

multiple array of raw bibliographic data to be processed by $this->bibStyle

mixed||string|int ids

resource ids giving order of processing bibliography

Returns

endnoteRemovePunc()

endnoteRemovePunc(  entry) : 

Removing trailing spaces and punctuation for endnote-style bibliographic entries.

Parameters

entry

Returns

processIntextBibliography()

processIntextBibliography(mixed||string|int  row) : 

Format the bibliography for in-text-style citations.

Parameters

mixed||string|int row

array of raw bibliographic data for one resource to be processed by $this->bibStyle

Returns

collateIntextBibliography()

collateIntextBibliography() : 

Collate the bibliography array for in-text-style citations.

Returns

printEndnoteBibliography()

printEndnoteBibliography(  pString) : 

Print the bibliography for endnote-style citations.

Parameters

pString

Returns

endnoteProcess()

endnoteProcess() : 

Format the endnotes for endnote-style citations

Returns

loadArrays()

loadArrays() : 

Localisations etc.

Returns