Project

General

Profile

1
<?php
2

    
3
defined('_JEXEC') or die('Access denied');
4

    
5
jimport('joomla.environment.uri');
6
jimport('joomla.methods');
7

    
8
$document = JFactory :: getDocument();
9
$document -> addStyleSheet(JRoute :: _(JUri :: base() . 'components/com_openaire/css/tabcontent.css'));
10
$document -> addScript(JRoute :: _(JUri :: base() . 'components/com_openaire/js/tabcontent.js'));
11

    
12
?>
13

    
14
<div class="searchBox">
15
	<ul class="tabs">
16
		<li><a href="<?php echo(JRoute :: _('index.php?option=com_openaire&view=search&Itemid=' . $this -> itemId . '&noscroll=true#alltab')); ?>"><?php echo(JText :: _('ALL')); ?></a></li>
17
		<li><a href="<?php echo(JRoute :: _('index.php?option=com_openaire&view=advancedsearchpublications&Itemid=' . $this -> itemId . '&noscroll=true#publtab')); ?>"><?php echo(JText :: _('PUBLICATIONS')); ?></a></li>
18
		<li><a href="<?php echo(JRoute :: _('index.php?option=com_openaire&view=advancedsearchprojects&Itemid=' . $this -> itemId . '&noscroll=true#projtab')); ?>"><?php echo(JText :: _('PROJECTS')); ?></a></li>
19
		<li><a href="<?php echo(JRoute :: _('index.php?option=com_openaire&view=advancedsearchpeople&Itemid=' . $this -> itemId . '&noscroll=true#peopletab')); ?>"><?php echo(JText :: _('PEOPLE')); ?></a></li>
20
		<li class="selected"><a rel="orgtab"><?php echo(JText :: _('ORGANIZATIONS')); ?></a></li>
21
		<li><a href="<?php echo(JRoute :: _('index.php?option=com_openaire&view=advancedsearchdatasources&Itemid=' . $this -> itemId . '&noscroll=true#dtsrctab')); ?>"><?php echo(JText :: _('DATASOURCES')); ?></a></li>
22
	</ul>
23
	<div class="tabcontents">
24
		<div class="tabcontent" id="orgtab">
25
			<form method="get" action="<?php echo(JRoute :: _('index.php')); ?>">
26
				<input type="hidden" name="option" value="com_openaire"/>
27
				<input type="hidden" name="view" value="advancedsearchorganizations" />
28
				<input type="hidden" name="Itemid" value="<?php echo ($this -> itemId)?> "/>
29
				<input type="hidden" name="noscroll" value="true" />
30
				<div class="flowWrapper">
31
					<?php if (($this -> keywords != NULL) && ($this -> fields != NULL) && ($this -> constraints != NULL)) {
32
						for ($i = 0; ($i < count($this -> keywords)) && ($i < count($this -> fields)) && ($i < count($this -> constraints)); $i++) { ?>
33
							<div class="srchNavTextAdvancedFilter">
34
								<input type="text" name="keyword[]" class="textsearch" placeholder="<?php echo(JText :: _('SEARCH_KEYWORDS')); ?>" value="<?php echo($this -> keywords[$i]); ?>" /><input type="submit" value="<?php echo(JText :: _('SEARCH')); ?>" class="search-button" />
35
								<select name="field[]" class="fieldSelector">
36
									<option value="<?php echo(OpenAireViewAdvancedSearchOrganizations :: ALL); ?>"<?php echo(($this -> fields[$i] == OpenAireViewAdvancedSearchOrganizations :: ALL) ? ' selected="selected"' : ''); ?>><?php echo(JText :: _('ALL_FIELDS')); ?></option>
37
									<option value="<?php echo(OpenAireViewAdvancedSearchOrganizations :: NAME); ?>"<?php echo(($this -> fields[$i] == OpenAireViewAdvancedSearchOrganizations :: NAME) ? ' selected="selected"' : ''); ?>><?php echo(JText :: _('NAME')); ?></option>
38
									<option value="<?php echo(OpenAireViewAdvancedSearchOrganizations :: SHORT_NAME); ?>"<?php echo(($this -> fields[$i] == OpenAireViewAdvancedSearchOrganizations :: SHORT_NAME) ? ' selected="selected"' : ''); ?>><?php echo(JText :: _('SHORT_NAME')); ?></option>
39
								</select>
40
								<select name="constraint[]" class="wordTypeSelector">
41
									<option value="<?php echo(OpenAireViewAdvancedSearchOrganizations :: ALL); ?>"<?php echo(($this -> constraints[$i] == OpenAireViewAdvancedSearchOrganizations :: ALL) ? ' selected="selected"' : ''); ?>><?php echo(JText :: _('ALL_WORDS')); ?></option>
42
									<option value="<?php echo(OpenAireViewAdvancedSearchOrganizations :: ANY); ?>"<?php echo(($this -> constraints[$i] == OpenAireViewAdvancedSearchOrganizations :: ANY) ? ' selected="selected"' : ''); ?>><?php echo(JText :: _('ANY_WORDS')); ?></option>
43
								</select>
44
								<div class="addNewFilter">
45
									<img src="<?php echo(JUri :: base() . 'components/com_openaire/images/addElementSelector.png'); ?>" width="25" height="25" />
46
								</div>
47
								<div class="removeNewFilter">
48
									<img src="<?php echo(JUri :: base() . 'components/com_openaire/images/removeElementSelector.png'); ?>" width="25" height="25"<?php echo(((count($this -> keywords) == 1) || (count($this -> constraints) == 1) || (count($this -> fields) == 1)) ? ' style="display: none;"' : ''); ?> />
49
								</div>				
50
							</div>
51
						<?php }
52
					} else { ?>			
53
						<div class="srchNavTextAdvancedFilter">
54
							<input type="text" name="keyword[]" class="textsearch" placeholder="<?php echo(JText :: _('SEARCH_KEYWORDS')); ?>" /><input type="submit" value="<?php echo(JText :: _('SEARCH')); ?>" class="search-button" />
55
							<select name="field[]" class="fieldSelector">
56
								<option value="<?php echo(OpenAireViewAdvancedSearchOrganizations :: ALL); ?>"><?php echo(JText :: _('ALL_FIELDS')); ?></option>
57
								<option value="<?php echo(OpenAireViewAdvancedSearchOrganizations :: NAME); ?>"><?php echo(JText :: _('NAME')); ?></option>
58
								<option value="<?php echo(OpenAireViewAdvancedSearchOrganizations :: SHORT_NAME); ?>"><?php echo(JText :: _('SHORT_NAME')); ?></option>
59
							</select>
60
							<select name="constraint[]" class="wordTypeSelector">
61
								<option value="<?php echo(OpenAireViewAdvancedSearchOrganizations :: ALL); ?>"><?php echo(JText :: _('ALL_WORDS')); ?></option>
62
								<option value="<?php echo(OpenAireViewAdvancedSearchOrganizations :: ANY); ?>"><?php echo(JText :: _('ANY_WORDS')); ?></option>
63
							</select>
64
							<div class="addNewFilter">
65
								<img src="<?php echo(JUri :: base() . 'components/com_openaire/images/addElementSelector.png'); ?>" width="25" height="25" />
66
							</div>
67
							<div class="removeNewFilter">
68
								<img src="<?php echo(JUri :: base() . 'components/com_openaire/images/removeElementSelector.png'); ?>" width="25" height="25" style="display: none;" />
69
							</div>				
70
						</div>
71
					<?php } ?>			
72
					<div class="advancedPageResults">
73
						<?php echo(JText :: _('RESULTS_PER_PAGE_')); ?>
74
						<select name="size" class="resultsSelections">
75
							<?php for ($size = OpenAireViewAdvancedSearchOrganizations :: MIN_SIZE; $size <= OpenAireViewAdvancedSearchOrganizations :: MAX_SIZE; $size += OpenAireViewAdvancedSearchOrganizations :: SIZE_STEP) { ?>
76
								<option value="<?php echo($size); ?>"<?php echo(($size == $this -> size) ? ' selected="selected"' : ''); ?>><?php echo($size); ?></option>
77
							<?php } ?>
78
						</select>
79
						
80
					</div>
81
				</div>
82
				<div class="flowWrapper">
83
					<div class="advancedSearchOpt">
84
						<a href="<?php echo(JRoute :: _('index.php?option=com_openaire&view=searchorganizations&Itemid=' . $this -> itemId . '&noscroll=true#orgtab')); ?>"><?php echo(JText :: _('SIMPLE_SEARCH_')); ?></a>
85
					</div>
86
				</div>
87
				<?php if ($this -> statistics == NULL) { ?>
88
					<div class="error"><?php echo(JText :: _('ERROR_RETRIEVING_STATISTICS')); ?></div>
89
				<?php } else { ?>
90
					<div class="compileAdvancedSearchFilters">
91
						<div class="resultDisplayElement">
92
							<div class="header">
93
								<h3>
94
									<span class="limitLabel"><?php echo(JText :: _('LIMITS')); ?></span>
95
									<span id="noLimits" class="limitNoValue"><?php echo(JText :: _('___NONE')); ?></span>
96
								</h3>
97
								<a id="clearAll" class="editClear"><?php echo(JText :: _('_CLEAR_ALL_')); ?></a>
98
							</div>
99
							<div class="filters">
100
								<p id="countryLimits" style="float: none;">
101
									<?php echo(JText :: _('COUNTRIES_')); ?>
102
									<span></span>
103
								</p>
104
								<p id="typeLimits" style="float: none;">
105
									<?php echo(JText :: _('ORGANIZATION_TYPES_')); ?>
106
									<span></span>
107
								</p>
108
							</div>
109
						</div>
110
						<?php if (($this -> result != NULL) && ($this -> result -> organizations != NULL)) { ?>
111
							<div class="viewmore">
112
								<a><?php echo(JText :: _('VIEW_ADD_FILTERS')); ?></a>
113
							</div>
114
						<?php } ?>
115
						<div class="leftAdvanced">
116
							<div id="country" class="filterItem">
117
								<?php if ($this -> statistics['country'] -> data == NULL) { ?>
118
									<div class="box-info"><?php echo($this -> statistics['country'] -> error); ?></div>
119
								<?php } else { ?>
120
									<a class="editRef">
121
										<h2><?php echo($this -> statistics['country'] -> title); ?></h2>
122
										<div class="editClearOptions">
123
											<?php echo(JText :: _('EDIT')); ?>
124
										</div>
125
									</a>
126
									<div class="hiddenAdvancedSearch flowWrapper">
127
										<?php foreach ($this -> countries as $country) { ?>
128
											<input type="hidden" name="country[]" value="<?php echo($country); ?>" />
129
										<?php } ?>
130
										<div class="updateFilters">
131
											<input type="button" value="<?php echo(JText :: _('OK')); ?>" class="button-default okElement" />
132
											<input type="button" value="<?php echo(JText :: _('CANCEL')); ?>" class="button-default cancelElement" />
133
										</div>
134
										<div class="filterLimits">
135
											<input class="filterLimits" type="text" placeholder="<?php echo(JText :: _('START_TYPING_TO_LIMIT_YOUR_SELECTIONS')); ?>" />
136
										</div>
137
										<div class="valueSelector">
138
											<a class="selectAll"><?php echo(JText :: _('SELECT_ALL')); ?></a>&nbsp;|&nbsp;<a class="deselectAll"><?php echo(JText :: _('DESELECT_ALL')); ?></a>
139
										</div>
140
										<div class="filterListingBlock">
141
											<?php foreach ($this -> statistics['country'] -> data as $row) { ?>
142
												<div class="filterRow">
143
													<input type="checkbox" value="<?php echo($row -> id); ?>"<?php echo(in_array($row -> id, $this -> countries, TRUE) ? ' checked="checked"' : ''); ?> />
144
													<label><?php echo($row -> name); ?></label>
145
												</div>
146
											<?php } ?>
147
										</div>
148
									</div>
149
								<?php } ?>
150
							</div>
151
						</div>
152
						<div class="rightAdvanced">
153
							<div id="type" class="filterItem">
154
								<?php if ($this -> statistics['type'] -> data == NULL) { ?>
155
									<div class="box-info"><?php echo($this -> statistics['type'] -> error); ?></div>
156
								<?php } else { ?>
157
									<a class="editRef">
158
										<h2><?php echo($this -> statistics['type'] -> title); ?></h2>
159
										<div class="editClearOptions">
160
											<?php echo(JText :: _('EDIT')); ?>
161
										</div>
162
									</a>
163
									<div class="hiddenAdvancedSearch flowWrapper">
164
										<?php foreach ($this -> types as $type) { ?>
165
											<input type="hidden" name="type[]" value="<?php echo($type); ?>" />
166
										<?php } ?>
167
										<div class="updateFilters">
168
											<input type="button" value="<?php echo(JText :: _('OK')); ?>" class="button-default okElement" />
169
											<input type="button" value="<?php echo(JText :: _('CANCEL')); ?>" class="button-default cancelElement" />
170
										</div>
171
										<div class="filterLimits">
172
											<input class="filterLimits" type="text" placeholder="<?php echo(JText :: _('START_TYPING_TO_LIMIT_YOUR_SELECTIONS')); ?>" />
173
										</div>
174
										<div class="valueSelector">
175
											<a class="selectAll"><?php echo(JText :: _('SELECT_ALL')); ?></a>&nbsp;|&nbsp;<a class="deselectAll"><?php echo(JText :: _('DESELECT_ALL')); ?></a>
176
										</div>
177
										<div class="filterListingBlock">
178
											<?php foreach ($this -> statistics['type'] -> data as $row) { ?>
179
												<div class="filterRow">
180
													<input type="checkbox" value="<?php echo($row -> id); ?>"<?php echo(in_array($row -> id, $this -> types, TRUE) ? ' checked="checked"' : ''); ?> />
181
													<label><?php echo($row -> name); ?></label>
182
												</div>
183
											<?php } ?>
184
										</div>
185
									</div>
186
								<?php } ?>
187
							</div>
188
						</div>
189
					</div>
190
				<?php } ?>
191
			</form>
192
		</div>
193
	</div>
194
</div>
(2-2/4)