Project

General

Profile

1 19426 thanos.pap
<?php
2
3
defined('_JEXEC') or die('Access denied');
4
5
jimport('joomla.methods');
6
7
JView :: loadHelper('PagingHelper');
8
JView :: loadHelper('DatasetHelper');
9
10
if ($this -> result == NULL) { ?>
11
	<div class="error"><?php echo(JText :: _('ERROR_PERFORMING_SEARCH')); ?></div>
12
<?php } else if ($this -> result -> datasets == NULL) { ?>
13
	<div class="box-info"><?php echo(JText :: _('NO_DATASETS_FOUND')); ?></div>
14
<?php } else { ?>
15
	<div class="pageController">
16
		<span class="totalof"><?php JText :: printf('N_DATASETS_PAGE_N_OF_N', $this -> result -> totalDatasets, $this -> page, $this -> totalPages); ?></span>
17 23853 thanos.pap
		<?php $baseUrl = 'index.php?option=com_openaire&view=searchdatasets&Itemid=' . $this -> itemId . '&keyword=' . $this -> keyword;
18 19426 thanos.pap
		foreach ($this -> filters as $filter)
19 23853 thanos.pap
			$baseUrl .= '&' . urlencode($filter -> name) . '=' . urlencode(($filter -> value === TRUE) ? 'true' : (($filter -> value === FALSE) ? 'false' : $filter -> value));
20
		$baseUrl .= '&size=' . $this -> size . '&noscroll=true&page=';
21 27140 yannis.str
		echo(PagingHelper :: formatPaging($this -> page, $this -> totalPages, $this -> pagingStart, $this -> pagingEnd, $baseUrl, '')); ?>
22 19426 thanos.pap
	</div>
23
	<div class="searchResults">
24
		<?php foreach ($this -> result -> datasets as $dataset) {
25
			echo(DatasetHelper :: formatDataset($dataset, $this -> itemId));
26
		} ?>
27
	</div>
28
	<div class="pageController">
29 27140 yannis.str
		<?php echo(PagingHelper :: formatPaging($this -> page, $this -> totalPages, $this -> pagingStart, $this -> pagingEnd, $baseUrl, '')); ?>
30 19426 thanos.pap
	</div>
31
<?php } ?>