    
function openClose ( id )
{
      if ( document.getElementById(id).style.display == 'none')
      {
          document.getElementById(id).style.display = 'block';
      } else {
          document.getElementById(id).style.display = 'none';
      }
}

function confirmation( link, about)
{
  var answer = confirm(about);
  
	if (answer){
		window.location = link;
	} 

}

function enableField() {

  if ( document.getElementById('order').disabled == false)
	   document.getElementById('order').disabled=true;
	else
	   document.getElementById('order').disabled=false;
	   
}

function redsort()
{
  var link = document.getElementById('url').value;

  if ( document.getElementById('pag').value != '' )
    link = link + ',s,' + document.getElementById('pag').value;
 
  if ( document.getElementById('order').value != '' )
    link = link + ',o,' + document.getElementById('order').value;

window.location.href = link;
}

 // funkcja do wrzucania GET z okna szukania
function szukane(){
  var cc = document.getElementById('que').value;
  document.getElementById('form_search').action = "search?&query="+cc;
  //document.getElementById('form_search').action = "search,"+['query',cc];
	}
  


