 function getOptions4Category(url, id) {
   var myAjax = new Ajax.Request
     (
       url,
       {
         method: "get",
         parameters : "type=manufacturer&categoryId="+id,
         onSuccess: function transResult (response) {
           document.getElementById('manufacturer').innerHTML=response.responseText;
         },
         onFailure: function transResult (response) {
           alert ('Failure'+response.responseText);
         }
       }
     );
   var myAjax = new Ajax.Request
     (
       url,
       {
         method: "get",
         parameters : "type=productType&categoryId="+id,
         onSuccess: function transResult (response) {
           document.getElementById('productType').innerHTML=response.responseText;
         },
         onFailure: function transResult (response) {
           alert ('Failure'+response.responseText);
         }
       }
     );
     return false;
 }


 function showBanner(banner,windowClose){
    bannerpreview = window.open("","", "width=400, height=595 resizable=No");
    bannerpreview.document.write("<html><body leftmargin='0' topmargin='0'><img src="+banner+".jpg width='400' alt='"+windowClose+"' onClick='self.close();' style='cursor:pointer;'></body></html>");
}

 // This function checks/unchecks all check box input fields of the specified group (groupPath + n).
function setAllChecked(groupPath, groupListSize, checked) {
    for (var i = 1; i <= groupListSize; i++) {
        var groupCheckBox = document.getElementById(groupPath + i);
        if (groupCheckBox != null) {
            groupCheckBox.checked = checked;
        }
    }
}