Revision 596 (by dpavlin, 2004/11/16 17:59:54) lektura
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
	<title>HIDRA - Pojmovnik Eurovoc</title>
	<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2"/>
	<link rel="stylesheet" href="eurovoc.css" type="text/css">

	<script type="text/javascript" src="js/bfilter.js"></script>
	<script type="text/javascript" src="js/popup.js"></script>
	<script type="text/javascript" src="js/load_js.js"></script>
	<script type="text/javascript" src="js/cookies.js"></script>
	<script type="text/javascript" src="js/l2_unescape.js"></script>
	<script type="text/javascript" src="js/unac.js"></script>
	<script type="text/javascript" src="js/clear_last_search.js"></script>
	<script type="text/javascript">
// <!--

var lang2thes = {
	'hr' : 'DescriptorHR.js',
	'en' : 'DescriptorEN.js',
	'fr' : 'DescriptorFR.js',
	'ge' : 'DescriptorGE.js'
};

var lang = get_cookie('w2_lang');

var headlines = null;
self.document.myfilter = null;

function myfilter() {
//	self.document.getElementById('textfilter').focus();
//	self.document.getElementById('textfilter').caretPos=1;
//	self.document.getElementById('textfilter').select();
	self.document.myfilter = new BFilter(headlines);

	// define some regexps
	self.document.myfilter.star_regex = new RegExp(/ *#C# */i);
	self.document.myfilter.htmlent_regex = new RegExp(/(&[a-z][a-z]*;)/i);

	self.document.myfilter.text_ent = function (str) {
		if (str.match(this.htmlent_regex)) {
			var e = self.document.createElement("span");
			e.innerHTML = str;
			return e;
		} else {
			return self.document.createTextNode(str);
		}
	}

	self.document.myfilter.result = function (arr) {
		var r_div = element_id('results');
		if (r_div) {
			var li = self.document.createElement("li");
			var e = self.document.createElement("a");
			var pic = null;
			
			e.setAttribute("href","hijerarhija.html?o="+arr[1]+"#mfn"+arr[1]);
			if (arr[0].match(this.star_regex)) {
				e.appendChild(this.text_ent(arr[2].replace(this.star_regex,' ')));
				pic = self.document.createElement("img");
				pic.src = 'img/crovoc.png';
				pic.border = 0;
				e.appendChild(pic);
			} else {
				e.appendChild(this.text_ent(arr[2]));
			}
			li.appendChild(e);

			li.appendChild(self.document.createTextNode(" "));

			e = self.document.createElement("a");
			e.setAttribute("href","thes/"+arr[1]+".html");
			e.setAttribute("target","popup");
			e.onclick = function() { return popup(e) };
			pic = self.document.createElement("img");
			pic.src = 'img/listic.png';
			pic.border = 0;
			e.appendChild(pic);
			li.appendChild(e);

			li.appendChild(self.document.createElement("br"));

			// append li
			r_div.appendChild(li);

		} else {
			alert("can't find results div!");
		}
/*
		return '<li><a href="thes/'+arr[1]+'.html">'+arr[0]+'</a>'+
		'&nbsp;<a href="browse.html?o='+arr[1]+'">&curren;</a>' +
		'</li>';
*/
		return null;
	}

	// this function is called when updating innerHTML with results
	self.document.myfilter.display = function (html) {
		return null;
//		return '<ul>'+html+'</ul>';
	}

	self.document.myfilter.show_status = function (status) {
		var html;
		if (this.hits > 0) {
			html = "Pronađeno "+this.hits+" zapisa";
		} else {
			html = "Nije pronađen niti jedan zapis";
		}
		if (! status) {
			html = "Upišite najmanje "+this.min_len+" početna slova za pretraživanje.";
			status = "";
		} else {
			status = " za <em>"+status+"</em>.";
		}

		var el = this.element_id("status");
		el.innerHTML = html+status+"\n";
	}

	// time timeout to 500ms
	self.document.myfilter.timeout = 500;
}

function load_lang(lang) {
	// reset results
	if (self.document.myfilter) element_id('results').innerHTML = "";

	// default language or fallback from all to hr
	if (! lang || lang == 'all') lang = 'hr';

	if (! lang2thes[lang]) {
		alert("Jezik "+lang+" nije podržan");
	}

	set_cookie('w2_lang', lang);
	element_id('lang').disabled = true;
	element_id('textfilter').disabled = true;
	element_id('status').innerHTML = "Učitavanje podataka za jezik. Molimo, pričekajte...";

	self.document.myfilter = null;

	load_js(lang2thes[lang], 'headlines', 'load_lang_finished();' );
}

function do_filter(filter) {
	set_cookie('w2_lastsearch', filter);
	var f = l2_unescape(filter);
	if (! f) f='';
	if (f.length > 2) f = f.substr(0,2) + unac(f.substr(2,f.length-2));
	if (self.document.myfilter) {
		element_id('status').innerHTML = "Pretraživanje u tijeku...";
		self.document.myfilter.filter(f);
	}
}

function load_lang_finished() {
	//alert("loaded "+lang);
	myfilter();
	self.document.myfilter.arr=headlines;
	element_id('lang').disabled = false;
	element_id('textfilter').disabled = false;
	var q = element_id('textfilter').value;
	if (q && q.length >= self.document.myfilter.min_len) {
		do_filter(q);
	} else {
		self.document.myfilter.show_status();
	}
	return false;
}

function select_option(value,text,selected) {
	document.write('<option value="'+value+'"');
	if (value == selected) document.write(' selected');
	document.write('>'+text+'</option>');
}
// -->
</script>
<script type="text/javascript" src="js/hide.js"></script>
</head>

<body onload="load_lang(lang);">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
  	<td colspan="3" class="hdr" height="10">
	</td>
  </tr>
  <tr>
	<td class="logoHidra">
		<img src="img/euzajed.gif" border="0" alt="Europske zajednice">
	</td>
	<td class="logoHidra">
		<img src="img/hidra.gif" border="0" alt="HIDRA logo">
	</td>
  	<td class="logoEUV">
		<a href="index.html"><img src="img/eurovoc2.png" border="0" alt="Eurovoc"></a>
	</td>
  </tr>
  <tr>
  	<td class="hdr2" height="10" colspan="3">
	</td>
	
  </tr>
</table>


<table border="0" cellspacing="0" cellpadding="0" width="100%">
  <tr>
	<td class="hMenuL hMenu">
	<table width="160" cellspacing="0" cellpadding="0">
	<tr><td>
		<table border="0" cellspacing="0" cellpadding="0">
		   <tr>
			<td class="topLpl"></td>
	  		<td rowspan="2" class="hMenuTxt"><a class="lhM" href="eurovoc.html">Pojmovnik Eurovoc</a></td>
			<td nowrap class="topRpl"></td>
		   </tr>	
		   <tr>
		   	<td class="hMenuSide"></td>
		   	<td class="hMenuSide"></td>
		   </tr>
		   <tr>
			<td colspan="3" height="10"></td>
		   </tr>	
		</table>
	</td></tr>
	</table>
	</td>

	<td colspan="2" class="hMenu">	
<table border="0" cellspacing="0" cellpadding="0" align="left" width="520">
  <tr>
  	<td width="10">&nbsp;</td>
	<td>
		<table border="0" cellspacing="0" cellpadding="0">
		   <tr>
			<td class="topLpl"></td>
	  		<td rowspan="2" class="hMenuTxt"><a class="lhM" href="pretrazivanje.html">Pretraživanje</a></td>
			<td class="topRpl"></td>
		   </tr>	
		   <tr>
		   	<td class="hMenuSide"></td>
		   	<td class="hMenuSide"></td>
		   </tr>
		   <tr>
			<td colspan="3" height="10"></td>
		   </tr>	
		</table>
	</td>
  	<td width="10">&nbsp;</td>
	<td>
		<table border="0" cellspacing="0" cellpadding="0">
		   <tr>
			<td class="topLpl"></td>
	  		<td rowspan="2" class="hMenuTxt"><a class="lhM" href="hijerarhija.html">Hijerarhijski prikaz</a></td>
			<td class="topRpl"></td>
		   </tr>	
		   <tr>
		   	<td class="hMenuSide"></td>
		   	<td class="hMenuSide"></td>
		   </tr>
		   <tr>
			<td colspan="3" height="10"></td>
		   </tr>	
		</table>
	</td>
  	<td width="10">&nbsp;</td>
	<td>
		<table border="0" cellspacing="0" cellpadding="0">
		   <tr>
			<td class="topLpl"></td>
	  		<td rowspan="2" class="ActMenu">Abecedna kazala</td>
			<td class="topRpl"></td>
		   </tr>	
		   <tr>
		   	<td class="hMenuSide"></td>
		   	<td class="hMenuSide"></td>
		   </tr>
		   <tr>
			<td class="bottomLpl"></td>
	  		<td class="bkgPl"></td>
			<td class="bottomRpl"></td>
		   </tr>	
		</table>
	</td>
  	<td width="10">&nbsp;</td>
  </tr>
</table>

	</td>
  </tr>
  
  <tr>
  	<td width="200" class="menu">
	<table border="0" cellspacing="0" cellpadding="0" width="200">
	  <tr>
	  	<td colspan="3">&nbsp;</td>
	  </tr>
	  <tr>
		<td class="topLsv"></td>
		<td class="middle2 bkgSv"></td>
		<td class="topRsv"></td>
	  </tr>
	  <tr>
		<td colspan="3" class="menuItem2">Upute za prikaz <br>abecednih kazala</td>
	  </tr>
	  <tr>
		<td colspan="3" class="menuItem">
Odaberite jezik i upišite najmanje <em>dva početna slova</em> traženoga pojma.
		</td>
	  </tr>
	  <tr>
		<td colspan="3" class="menuItem">
Rezultat traženja je popis pronađenih deskriptora s pripadajućim potpojmovnikom, te nedeskriptora koji znakom &gt;&gt; upućuju na deskriptor. Navodi u popisu su ujedno veza prema hijerarhijski strukturiranomu prikazu.
		</td>
	  </tr>
	  <tr>
		<td colspan="3" class="menuItem">
Sličica <img src="img/listic.png">  otvara novi prozor s detaljnim prikazom deskriptora.	
		</td>
	  </tr>
	  <tr>
		<td colspan="3" class="menuItem">
	Sličica  <img src="img/crovoc.png"> označuje deskriptore i nedeskriptore Hrvatskoga dodatka.
		</td>
	  </tr>
	  <tr>
	  	<td class="bottomLsv"></td>
		<td class="middle2 bkgSv"></td>
	  	<td class="bottomRsv"></td>
	  </tr>
	</table>

	</td>
  
	
	<td class="bd2">

<h3>Abecedna kazala</h3>

<!--
<div style="float: right; width: 10em; text-align: center; margin: 0.5m">
 <a href="#" onclick="toggle_display('debug');">debug</a>
 <div style="text-align: left; border: 1px dashed #c0c0c0; display: none;" id="debug">
 </div>
</div>
-->

<form id="filterform" method="get" onsubmit="return false;" action="?" >
<div class="filters">
  <script type="text/javascript">
	// <!--
	document.write('<select id="lang" name="lang" onchange="load_lang(this.options[this.selectedIndex].value);">');
	select_option("hr","Hrvatski",lang);
	select_option("en","Engleski",lang);
	select_option("fr","Francuski",lang);
	select_option("ge","Njemački",lang);
	document.write('</select>');

	document.write('<input autocomplete="off" class="filters" id="textfilter" title="enter a regular expression to filter by" onkeyup="do_filter(this.value);" value="'+get_cookie('w2_lastsearch')+'"/>');
	// -->
  </script>
	<!-- this button is strictly for looks -->
	<!--
	<input class="filters" value="filter" type="button" disabled="true"/>
	-->
	<input class="submit" type="button" value="Obriši !" onClick="javascript:element_id('results').innerHTML = ''; self.document.myfilter.show_status(); return clear_last_search('filterform','textfilter');"/><br/>
</div>
</form>

<div id="status">
<!--
Enter few letters to filter by them
-->
</div>

<ul id="results">
</ul>

	</td>
</tr>
</table>	

</body>
</html>