@@ -25,7 +25,7 @@ discard block |
||
25 | 25 | // wrap with JSONP callback if requested |
26 | 26 | if (filter_input(INPUT_GET, 'callback', FILTER_SANITIZE_STRING)) { |
27 | 27 | header("Content-type: application/javascript; charset=utf-8"); |
28 | - echo filter_input(INPUT_GET, 'callback', FILTER_UNSAFE_RAW) . "(" . json_encode($data) . ");"; |
|
28 | + echo filter_input(INPUT_GET, 'callback', FILTER_UNSAFE_RAW)."(".json_encode($data).");"; |
|
29 | 29 | return; |
30 | 30 | } |
31 | 31 | |
@@ -88,7 +88,7 @@ discard block |
||
88 | 88 | 'vocabularies' => 'onki:hasVocabulary', |
89 | 89 | 'id' => 'onki:vocabularyIdentifier', |
90 | 90 | 'uri' => '@id', |
91 | - '@base' => $this->getBaseHref() . "rest/v1/vocabularies", |
|
91 | + '@base' => $this->getBaseHref()."rest/v1/vocabularies", |
|
92 | 92 | ), |
93 | 93 | 'uri' => '', |
94 | 94 | 'vocabularies' => $results, |
@@ -105,7 +105,7 @@ discard block |
||
105 | 105 | // convert to vocids array to support multi-vocabulary search |
106 | 106 | $vocids = ($vocabs !== null && $vocabs !== '') ? explode(' ', $vocabs) : array(); |
107 | 107 | $vocabObjects = array(); |
108 | - foreach($vocids as $vocid) { |
|
108 | + foreach ($vocids as $vocid) { |
|
109 | 109 | $vocabObjects[] = $this->model->getVocabulary($vocid); |
110 | 110 | } |
111 | 111 | $parameters->setVocabularies($vocabObjects); |
@@ -144,7 +144,7 @@ discard block |
||
144 | 144 | if ($request->getQueryParam('labellang')) { |
145 | 145 | $ret['@context']['@language'] = $request->getQueryParam('labellang'); |
146 | 146 | } elseif ($request->getQueryParam('lang')) { |
147 | - $ret['@context']['@language'] = $request->getQueryParam('lang');; |
|
147 | + $ret['@context']['@language'] = $request->getQueryParam('lang'); ; |
|
148 | 148 | } |
149 | 149 | return $ret; |
150 | 150 | } |
@@ -211,7 +211,7 @@ discard block |
||
211 | 211 | 'prefLabel' => 'skos:prefLabel', |
212 | 212 | 'title' => 'dct:title', |
213 | 213 | '@language' => $request->getLang(), |
214 | - '@base' => $this->getBaseHref() . "rest/v1/" . $vocab->getId() . "/", |
|
214 | + '@base' => $this->getBaseHref()."rest/v1/".$vocab->getId()."/", |
|
215 | 215 | ), |
216 | 216 | 'uri' => '', |
217 | 217 | 'id' => $vocab->getId(), |
@@ -261,7 +261,7 @@ discard block |
||
261 | 261 | 'subTypes' => array('@id' => 'void:class', '@type' => '@id'), |
262 | 262 | 'count' => 'void:entities', |
263 | 263 | '@language' => $request->getLang(), |
264 | - '@base' => $this->getBaseHref() . "rest/v1/" . $request->getVocab()->getId() . "/", |
|
264 | + '@base' => $this->getBaseHref()."rest/v1/".$request->getVocab()->getId()."/", |
|
265 | 265 | ), |
266 | 266 | 'uri' => '', |
267 | 267 | 'id' => $request->getVocab()->getId(), |
@@ -335,7 +335,7 @@ discard block |
||
335 | 335 | 'language' => 'void-ext:language', |
336 | 336 | 'properties' => 'void:propertyPartition', |
337 | 337 | 'labels' => 'void:triples', |
338 | - '@base' => $this->getBaseHref() . "rest/v1/" . $request->getVocab()->getId() . "/", |
|
338 | + '@base' => $this->getBaseHref()."rest/v1/".$request->getVocab()->getId()."/", |
|
339 | 339 | ), |
340 | 340 | 'uri' => '', |
341 | 341 | 'id' => $request->getVocab()->getId(), |
@@ -372,7 +372,7 @@ discard block |
||
372 | 372 | $types[] = $type; |
373 | 373 | } |
374 | 374 | |
375 | - $base = $request->getVocab() ? $this->getBaseHref() . "rest/v1/" . $request->getVocab()->getId() . "/" : $this->getBaseHref() . "rest/v1/"; |
|
375 | + $base = $request->getVocab() ? $this->getBaseHref()."rest/v1/".$request->getVocab()->getId()."/" : $this->getBaseHref()."rest/v1/"; |
|
376 | 376 | |
377 | 377 | $ret = array_merge_recursive($this->context, array( |
378 | 378 | '@context' => array( |
@@ -530,10 +530,10 @@ discard block |
||
530 | 530 | |
531 | 531 | $format = $this->negotiateFormat(array_keys($urls), $request->getServerConstant('HTTP_ACCEPT'), $request->getQueryParam('format')); |
532 | 532 | if (!$format) { |
533 | - return $this->returnError(406, 'Not Acceptable', "Unsupported format. Supported MIME types are: " . implode(' ', array_keys($urls))); |
|
533 | + return $this->returnError(406, 'Not Acceptable', "Unsupported format. Supported MIME types are: ".implode(' ', array_keys($urls))); |
|
534 | 534 | } |
535 | 535 | |
536 | - header("Location: " . $urls[$format]); |
|
536 | + header("Location: ".$urls[$format]); |
|
537 | 537 | } |
538 | 538 | |
539 | 539 | private function returnDataResults($results, $format) { |
@@ -587,7 +587,7 @@ discard block |
||
587 | 587 | |
588 | 588 | $format = $this->negotiateFormat(explode(' ', self::SUPPORTED_FORMATS), $request->getServerConstant('HTTP_ACCEPT'), $request->getQueryParam('format')); |
589 | 589 | if (!$format) { |
590 | - return $this->returnError(406, 'Not Acceptable', "Unsupported format. Supported MIME types are: " . self::SUPPORTED_FORMATS); |
|
590 | + return $this->returnError(406, 'Not Acceptable', "Unsupported format. Supported MIME types are: ".self::SUPPORTED_FORMATS); |
|
591 | 591 | } |
592 | 592 | |
593 | 593 | $vocid = $vocab ? $vocab->getId() : null; |