@@ -107,7 +107,6 @@ |
||
| 107 | 107 | |
| 108 | 108 | /** |
| 109 | 109 | * Get PDF document list |
| 110 | - |
|
| 111 | 110 | * @return array of attachments |
| 112 | 111 | */ |
| 113 | 112 | protected function getAttachments() |
@@ -82,7 +82,7 @@ discard block |
||
| 82 | 82 | |
| 83 | 83 | } |
| 84 | 84 | |
| 85 | - $metadata = array(); |
|
| 85 | + $metadata = array (); |
|
| 86 | 86 | |
| 87 | 87 | $metadata = $this->doc->getTitleData($this->conf['pages']); |
| 88 | 88 | |
@@ -148,7 +148,7 @@ discard block |
||
| 148 | 148 | |
| 149 | 149 | $outArray['citation_title'][] = $values[0]; |
| 150 | 150 | |
| 151 | - $GLOBALS['TSFE']->page['title'] = $values[0]; |
|
| 151 | + $GLOBALS['TSFE']->page['title'] = $values[0]; |
|
| 152 | 152 | |
| 153 | 153 | } |
| 154 | 154 | |
@@ -180,8 +180,8 @@ discard block |
||
| 180 | 180 | break; |
| 181 | 181 | |
| 182 | 182 | case 'attachments': |
| 183 | - foreach($values as $attachment) { |
|
| 184 | - $conf = array( |
|
| 183 | + foreach ($values as $attachment) { |
|
| 184 | + $conf = array ( |
|
| 185 | 185 | 'useCacheHash' => 0, |
| 186 | 186 | 'parameter' => $this->conf['apiPid'], |
| 187 | 187 | 'additionalParams' => '&tx_dpf[qid]=' . $this->doc->recordId . '&tx_dpf[action]=attachment&tx_dpf[attachment]=' . $attachment['ID'], |
@@ -258,14 +258,14 @@ discard block |
||
| 258 | 258 | */ |
| 259 | 259 | protected function getAttachments() |
| 260 | 260 | { |
| 261 | - $attachments = array(); |
|
| 261 | + $attachments = array (); |
|
| 262 | 262 | |
| 263 | 263 | $xPath = 'mets:fileSec/mets:fileGrp[@USE="' . $this->conf['fileGrpDownload'] . '"]/mets:file'; |
| 264 | 264 | $files = $this->doc->mets->xpath($xPath); |
| 265 | 265 | |
| 266 | 266 | if (is_array($files)) { |
| 267 | 267 | foreach ($files as $key => $file) { |
| 268 | - $singleFile = array(); |
|
| 268 | + $singleFile = array (); |
|
| 269 | 269 | |
| 270 | 270 | foreach ($file->attributes('mext', 1) as $attribute => $value) { |
| 271 | 271 | $singleFile[$attribute] = $value; |
@@ -25,8 +25,7 @@ discard block |
||
| 25 | 25 | * @subpackage tx_dpf |
| 26 | 26 | * @access public |
| 27 | 27 | */ |
| 28 | -class MetaTags extends \tx_dlf_plugin |
|
| 29 | -{ |
|
| 28 | +class MetaTags extends \tx_dlf_plugin { |
|
| 30 | 29 | |
| 31 | 30 | /** |
| 32 | 31 | * @type \TYPO3\CMS\Core\Page\PageRenderer |
@@ -44,8 +43,7 @@ discard block |
||
| 44 | 43 | * |
| 45 | 44 | * @return string The content that is displayed on the website |
| 46 | 45 | */ |
| 47 | - public function main($content, $conf) |
|
| 48 | - { |
|
| 46 | + public function main($content, $conf) { |
|
| 49 | 47 | |
| 50 | 48 | $this->init($conf); |
| 51 | 49 | |
@@ -122,8 +120,7 @@ discard block |
||
| 122 | 120 | * |
| 123 | 121 | * @return string The metadata array ready for output |
| 124 | 122 | */ |
| 125 | - protected function printMetaTags(array $metadata) |
|
| 126 | - { |
|
| 123 | + protected function printMetaTags(array $metadata) { |
|
| 127 | 124 | |
| 128 | 125 | $output = ''; |
| 129 | 126 | |
@@ -245,8 +242,7 @@ discard block |
||
| 245 | 242 | * |
| 246 | 243 | * @return Formatted date |
| 247 | 244 | */ |
| 248 | - protected function safelyFormatDate($format, $date) |
|
| 249 | - { |
|
| 245 | + protected function safelyFormatDate($format, $date) { |
|
| 250 | 246 | return (strlen($date) == 4) ? $date : date($format, strtotime($date)); |
| 251 | 247 | } |
| 252 | 248 | |
@@ -256,8 +252,7 @@ discard block |
||
| 256 | 252 | |
| 257 | 253 | * @return array of attachments |
| 258 | 254 | */ |
| 259 | - protected function getAttachments() |
|
| 260 | - { |
|
| 255 | + protected function getAttachments() { |
|
| 261 | 256 | $attachments = array(); |
| 262 | 257 | |
| 263 | 258 | $xPath = 'mets:fileSec/mets:fileGrp[@USE="' . $this->conf['fileGrpDownload'] . '"]/mets:file'; |
@@ -55,18 +55,18 @@ discard block |
||
| 55 | 55 | |
| 56 | 56 | if (is_array($dpfTSconfig['settings.'])) { |
| 57 | 57 | |
| 58 | - \TYPO3\CMS\Core\Utility\ArrayUtility::mergeRecursiveWithOverrule($dpfTSconfig['settings.'], $this->conf, true, false); |
|
| 58 | + \TYPO3\CMS\Core\Utility\ArrayUtility::mergeRecursiveWithOverrule($dpfTSconfig['settings.'], $this->conf, TRUE, FALSE); |
|
| 59 | 59 | $this->conf = $dpfTSconfig['settings.']; |
| 60 | 60 | |
| 61 | 61 | } |
| 62 | 62 | |
| 63 | 63 | // Turn cache on. |
| 64 | - $this->setCache(true); |
|
| 64 | + $this->setCache(TRUE); |
|
| 65 | 65 | |
| 66 | 66 | // Load current document. |
| 67 | 67 | $this->loadDocument(); |
| 68 | 68 | |
| 69 | - if ($this->doc === null) { |
|
| 69 | + if ($this->doc === NULL) { |
|
| 70 | 70 | |
| 71 | 71 | // Quit without doing anything if required variables are not set. |
| 72 | 72 | return $content; |
@@ -185,7 +185,7 @@ discard block |
||
| 185 | 185 | 'useCacheHash' => 0, |
| 186 | 186 | 'parameter' => $this->conf['apiPid'], |
| 187 | 187 | 'additionalParams' => '&tx_dpf[qid]=' . $this->doc->recordId . '&tx_dpf[action]=attachment&tx_dpf[attachment]=' . $attachment['ID'], |
| 188 | - 'forceAbsoluteUrl' => true, |
|
| 188 | + 'forceAbsoluteUrl' => TRUE, |
|
| 189 | 189 | ); |
| 190 | 190 | $outArray['citation_pdf_url'][] = $this->cObj->typoLink_URL($conf); |
| 191 | 191 | } |