function languageDropChange ()
{
//      if (!optionTest) return;
        // Gotta change this to check for the form name
        var box = document.registerform.country_id;
        var country = box.options[box.selectedIndex].value;
        if (country == "") return;

        // Check if country is in the list of NROs
        // if not, then make it general
        var list = store["general"];
        for(i=0;i<nro_country.length;i+=1)
        {
            if(country == nro_country[i]) {
               list = store[country];
               break;
            }
        }

        var box2 = document.registerform.register_id;
        box2.options.length = 0;
        // Check if site language is listed in NRO languages
        // and if not include it in the local choices
        var foundMatch;
        for(i=0;i<list.length;i+=2)
        {
                box2.options[i/2] = new Option(list[i],list[i+1]);
                if(list[i] == store["general"][0]) foundMatch = true;
        }

        if(!foundMatch) {
//                alert("Not found match "+foundMatch);
               box2.options[i/2] = new Option(store["general"][0],store["general"][1]);
        }
//        alert("i is "+i);
}



function isemail () {
       if ((document.registerform.email.value.indexOf('@') < 1 ||

(document.registerform.email.value.indexOf('.',document.registerform.email.value.indexOf('@')+2) < 0)
          || (document.registerform.email.value.length < document.registerform.email.value.indexOf('.',document.registerform.email.value.indexOf('@')+2) + 3 ))
          && (document.registerform.email.value.length > 0) )
       {
          document.registerform.email.focus()
          document.registerform.email.select()
          return false;
       }
       else {
          return true;
       }
    }

    function isblank(s) { for(var i = 0; i < s.length; i++) { var c =
       s.charAt(i); if ((c != ' ') && (c != '\n') && (c != '\t')) {
       return false; } } return true; }

    function verify() {
       if (!isemail() || isblank(document.registerform.email.value)) {
          document.registerform.email.focus()
          document.registerform.email.select()
          alert("Please enter a valid email Address (e.g. activist@supporters.com)");
          return false;
       }
       if (document.registerform.country_id.value == "general") {
          alert("Please choose a country");
          return false;
       }
       return true;

    }