Jump to content

[SOLVED] problems with multiple checkboxes


aussiefly

Recommended Posts

hey guys!

 

just working on a multiple checkbox solution which also restricts the number of boxes selected and im having dramas getting the php/mysql to work. It just doesnt seem to restrict you clicking the options or popup the warning window...any ideas for a complete newb??

 

ok the php/form part

 

<?
$siz=$i;
for($i=0;$i<$siz;$i++){
?>
  <INPUT TYPE=CHECKBOX VALUE="<?
        print $ch["id"][$i];
?> onClick="return KeepCount()"
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
<?
        print $ch["title"][$i];
?><BR>

<?
}
?>

 

And now the section of javascript it should be calling:

 

function KeepCount() {

var NewCount = 0

if (document.NewUser.sel1[1].checked)
{NewCount = NewCount + 1}

if (document.NewUser.sel1[2].checked)
{NewCount = NewCount + 1}

if (document.NewUser.sel1[3]checked)
{NewCount = NewCount + 1}

if (NewCount == 4)
{
alert('Form Accepts 3 Selections Maximum')
document.NewUser; return false;
}
}

 

Any ideas why its not working??? do i have the onclick in the wrong place??

 

Link to comment
Share on other sites

Hmm, I have a better solution for this method, here's how the javascript would work:

 

function KeepCount() {

var NewCount = 0;
var i = 1;
for(i=1;i<5;i++){//get the current count
if (document.NewUser.sel1[i].checked)
{NewCount++;}
}

if (NewCount == 3){//3 have been checked so far... disabled the others

var i = 1;
for(i=1;i<5;i++){//let's disable all the others that have not been checked
if (!document.NewUser.sel1[i].checked){document.NewUser.sel[i].disabled = true;}
}
window.alert('You have selected 3 options, this is the form maximum.');
}

if(NewCount < 3){//less than 3 have been checked so far... undisable any that are disabled

var i = 1;
for(i=1;i<5;i++){//let's disable all the others that have not been checked
document.NewUser.sel[i].disabled = false;
}

}

}

 

Here's how the html looks: (or rather, php echoing html)

 

<?
$siz=$i;
for($i=0;$i<$siz;$i++){
?>
  <INPUT TYPE=CHECKBOX VALUE="<?
        print $ch["id"][$i];
?> onClick="KeepCount();"
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
<?
        print $ch["title"][$i];
?><BR>

<?
}
?>

 

This method works in this way: we will loop through all the checkboxes, see how many have been checked off. Once 3 have been checked off, it will disable all the other checkboxes that are not checked. If less than 3 are checked off, it undisables all checkboxes (if any were disabled, you can uncheck, and click a different one ;-o)

Link to comment
Share on other sites

yup that really does look like a great solution to grey the checkboxes out.

 

I've plugged the code in but unfortunately it still doesnt seem to work. Its almost like the onclick is not being called when they select a checkbox. I can literally select all the boxes without getting an alert window.

 

Any idea why?

 

here is the signup page in its entirety after inserting your suggestions

 

<?
unset($login,$pwrd,$id);
session_start();
session_register("login","pwrd","id");

require('config_inc.php');
require('error_inc.php');


//require('error_inc.php');
//require('config_inc.php');

$ref=intval($ref);

if($REQUEST_METHOD=="POST"){
        if(isset($add)){

//print "Name:$name";
        ?>

<HTML><HEAD><TITLE></TITLE></HEAD><FRAMESET Rows='30,*' BORDER='0'><FRAME MARGINHEIGHT='0' MARGINWIDTH='0' SRC='addframe.php?name=<?=$name;?>&email=<?print $email;?>&share=<?print $share;?>&site=<?print $site;?>&language=<?print $language;?>&ref=<?print $ref;?>&sel[1]=<?print $sel[1];?>&sel[2]=<?print $sel[2];?>&sel[3]=<?print $sel[3];?>&sel1[1]=<?print $sel1[1];?>&sel1[2]=<?print $sel1[2];?>&sel1[3]=<?print $sel1[3];?>&pass=<?print $pass;?>&url=<?print $url;?>' SCROLLING='No' NORESIZE NAME='top' BORDER='0'><FRAME MARGINHEIGHT='0' MARGINWIDTH='0' SRC='<?print $url;?>' SCROLLING='AUTO' NORESIZE NAME='main' BORDER='0'></FRAMESET><noframes></noframes></HTML>
<?
        exit;
        }
}
$query = "select * from ".$t_language." order by language";
$result = MYSQL_QUERY($query);
$query1 = "select * from ".$t_cat." order by id";
$result1 = MYSQL_QUERY($query1);

require('header_inc.php');
?>
<SCRIPT language=javascript1.2 type=text/javascript>
function isEmail(str) {
  var supported = 0;
  if (window.RegExp) {
    var tempStr = "a";
    var tempReg = new RegExp(tempStr);
    if (tempReg.test(tempStr)) supported = 1;
  }
  if (!supported)
    return (str.indexOf(".") > 2) && (str.indexOf("@") > 0);
  var r1 = new RegExp("(@.*@)|(\\.\\.)|(@\\.)|(^\\.)");
  var r2 = new RegExp("^.+\\@(\\[?)[a-zA-Z0-9\\-\\.]+\\.([a-zA-Z]{2,3}|[0-9]{1,3})(\\]?)$");
  return (!r1.test(str) && r2.test(str));
}

function KeepCount() {

var NewCount = 0;
var i = 1;
for(i=1;i<5;i++){//get the current count
if (document.NewUser.sel1[i].checked)
{NewCount++;}
}

if (NewCount == 3){//3 have been checked so far... disabled the others

var i = 1;
for(i=1;i<5;i++){//let's disable all the others that have not been checked
if (!document.NewUser.sel1[i].checked){document.NewUser.sel[i].disabled = true;}
}
window.alert('You have selected 3 options, this is the form maximum.');
}

if(NewCount < 3){//less than 3 have been checked so far... undisable any that are disabled

var i = 1;
for(i=1;i<5;i++){//let's disable all the others that have not been checked
document.NewUser.sel1[i].disabled = false;
}

}

}

function EvaluateField()
{
        var userName                = document.NewUser.name.value;
        var userEmail                = document.NewUser.email.value;
        var userEmail2                = document.NewUser.email1.value;
        var SiteName                = document.NewUser.site.value;
        var SiteURL                = document.NewUser.url.value;
        var SiteLanguage        = document.NewUser.language.selectedIndex;

        if(SiteLanguage==0 ){
                alert('You need to set your primary site language.');
                document.NewUser.language.focus();
                return false;
        }

        if(userName == "")
        {
                alert("The field \"Your name\" must be filled.");
                document.NewUser.name.focus();
                return false;
        }


        if(userEmail == "")
        {
                alert("The field \"Your E-mail address\" must be filled.");
                document.NewUser.email.focus();
                return false;
        }
        else
        {
                if(isEmail(userEmail) == false)
                {
                        alert(userEmail + " can not be used as an email address.");
                        document.NewUser.email.focus();
                        return false;
                }
        }

        if(userEmail != userEmail2)
        {
                alert("The fields \"Your E-mail address\" and \"Confirm your E-mail address\" must be identically.");
                document.NewUser.email.focus();
                return false;
        }



        if(SiteName == "")
        {
                alert("The field \"Your site name\" must be filled.");
                document.NewUser.site.focus();
                return false;
        }

        if(SiteURL == "")
        {
                alert("The field \"Your site URL\" must be filled.");
                document.NewUser.url.focus();
                return false;
        }

        if(SiteURL == "http://")
        {
                alert("The field \"Your site URL\" must be filled.");
                document.NewUser.url.focus();
                return false;
        }


        alert('We will now open your site to check that your URL is correct. Please follow the information on top of the next screen.')

        return true;

}
</SCRIPT>
<!-- Begin of table--><center><BR>
        <table border="0" cellpadding="5" cellspacing="5" width="700">
          <tr>

            <td>
<p align="center"><B>
After filling out the boxes, read and accept the terms & conditions.</b><BR>
</p>
<FORM name=NewUser action="" method=post>
<table width="" border="0" cellspacing="0" cellpadding="0" align="center">
  <tr>
     <td width="200" align="left">Your Name:</td>
     <td align="left" width="200">
       <input type="text" name="name" size="30">
    </td>
  </tr>
  <tr>
     <td width="200" align="left">Your E-mail address:</td>
     <td align="left" width="200">
       <input type="text" name="email" size="30">
    </td>
  </tr>
  <tr>
     <td width="200" align="left">Confirm E-mail address:</td>
     <td align="left" width="200">
       <input type="text" name="email1" size="30">
    </td>
  </tr>
  <tr>
     <td width="200" align="left">Share Your E-mail:</td>
     <td align="left" width="200">
        <SELECT name="share"><OPTION value=0 selected>No, Keep my
              email private</OPTION><OPTION value=1>Yes, show it to my up & down line</OPTION></SELECT>
    </td>
  </tr>
  <tr>
     <td width="200" align="left">Your Website Name:</td>
     <td align="left" width="200">
       <input type="text" name="site" size="30">
    </td>
  </tr>
  <tr>
     <td width="200" align="left">Your Website URL:</td>
     <td align="left" width="200">
       <input type="text" name="url" value="http://" size="30">
    </td>
  </tr>
    <tr>
      <td width="200" align="left" class="text" valign="top">Show Your Site In:</td>
      <td align="left" class="text" width="200">
<?
$i=0;
while($row = mysql_fetch_array($result1)){
        $ch["id"][$i]=$row["id"];
        $ch["title"][$i]=$row["title"];
        $i++;
}?>


<?
$siz=$i;
for($i=0;$i<$siz;$i++){
?>
<INPUT TYPE=CHECKBOX VALUE="<?
        print $ch["id"][$i];
?>
" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
<?
        print $ch["title"][$i];
?><BR>

<?
}
?>



      </td>
    </tr>
    <tr>
      <td width="200" align="left" class="text" valign="top">You Are Interested In:</td>
      <td align="left" class="text" width="200">
  

<BR>  <?
$siz=$i;
for($i=0;$i<$siz;$i++){
?>
  <INPUT TYPE=CHECKBOX VALUE="<?
        print $ch["id"][$i];
?> onClick="KeepCount();"
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
<?
        print $ch["title"][$i];
?><BR>

<?
}
?>



      </td>
  <tr><br>
     <td width="200" align="left">Your Websites Language is:</td>
     <td align="left" width="200">
   <select name="sel6[6]">
<?
while($row = mysql_fetch_array($result)){
?>
<OPTION value="<?print $row["id"];?>"><?print $row["language"];?></OPTION>

<?
}
@mysql_free_result($result);
?>
</SELECT>
    </td>
  </tr>
  <tr>
     <td align="left" width="450" colspan=2>
<br><BR>
<!--begin Terms-->

<b>Terms & Conditions </b><ul>
<li> Your site(s) does not contain any message boxes
<li> Your site(s) does not contain inappropriate contents
<li> Your site(s) does not break out of frames
<li> Your site(s) does not use site rotation
<li> Your site(s) does not use URL or domain forwarding
<li> Your account will be deleted if not used for 90 days
<li> Your account will be deleted if we can not send youemails
<li> Your account can be disable if it causes system any problems
<li> You are not allowed to have more than one (1) account 
<li> Your site(s) does not contain any popup windows
<!--end Terms-->
</ul>

<BR></td>
  </tr>
</table>
<center>

<INPUT onclick="return EvaluateField();" type=submit name="add" value="Accept Terms & Conditions">
</center>
<!-- End of table-->
</form>
</td></tr></table></center>
<?
require('footer_inc.php');
?>

 

 

I suspect its gotto do with teh INPUT calling onclick evaluate function right down the bottom.

 

any ideas

Link to comment
Share on other sites

ok this is the actual page source code:

 

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link href="styles.css" rel="stylesheet" type="text/css">
<style>
.searchBox {
  border : 1px solid #000000;
  background-color : #FFFFFF;
  color : #000000;
  font-size : 13px;
  font-family :  Verdana, Arial, Helvetica, sans-serif;
  font-weight: bold;
}

.searchButton {
  border : 1px solid #000000;
  font-size : 13px;
  font-family :  Verdana, Arial, Helvetica, sans-serif;
  font-weight: bold;
}

</style>
<style>
.catTable {
  background-color: #FFFFFF;
  
}
.catHeadText {
font-size : 11;
font-family : Verdana, Arial, Helvetica, sans-serif;
color : #000000;
text-decoration: none;
font-weight: bold;
}

.subCatText {
font-size : 11;
font-family : Verdana, Arial, Helvetica, sans-serif;
color : #000000;
text-decoration: none;
}

a.catHeadText {
font-size : 11;
font-family : Verdana, Arial, Helvetica, sans-serif;
color : #000000;
text-decoration: none;
font-weight: bold;
}

a.subCatText {
font-size : 11;
font-family : Verdana, Arial, Helvetica, sans-serif;
color : #000000;
text-decoration: none;
}

a.catHeadText:VISITED {
font-size : 11;
font-family : Verdana, Arial, Helvetica, sans-serif;
color : #000000;
text-decoration: none;
font-weight: bold;
}

a.subCatText:VISITED {
font-size : 11;
font-family : Verdana, Arial, Helvetica, sans-serif;
color : #000000;
text-decoration: none;
}

a.catHeadText:HOVER {
font-size : 11;
font-family : Verdana, Arial, Helvetica, sans-serif;
color : #000000;
text-decoration: underline;
}

a.subCatText:HOVER {
font-size : 11;
font-family : Verdana, Arial, Helvetica, sans-serif;
color : #000000;
text-decoration: underline;
}
</style>

</head>

<body topmargin="0" bgcolor="#dddddd" background="images/back.jpg">
<table width="750" border="0" align="center" cellpadding="0" cellspacing="0" bordercolor="#000000" bgcolor="#ffffff">
  <tr>

    <td bordercolor="#FFFFFF"><table width="780" border="0" cellspacing="0" cellpadding="0">
        <tr> 
          <td align="center"><img src="images/index1_r2_c1.jpg" width="780" height="149"></td>
        </tr>
        <tr> 
          <td align="center"><a href="index.php"><img src="images/index1_r1_c1.jpg"  border="0"></a><a href="signup.php"><img src="images/index1_r1_c2.jpg" border="0"></a><a href="login.php"><img src="images/index1_r1_c3.jpg" border="0"></a><a href="faq.php"><img src="images/index1_r1_c4.jpg"  border="0"></a><a href="tell_friend.php"><img src="images/index1_r1_c5.jpg" border="0"></a><a href="mailto:konrad@thetrafficempire.com"><img src="images/index1_r1_c6.jpg" border="0"></a><img src="images/index1_r1_c7.jpg" ></td>
        </tr>
        <tr> 
          <td><table width="750" border="0" align="center" cellpadding="0" cellspacing="0">
              <tr>

                <td><SCRIPT language=javascript1.2 type=text/javascript>
function isEmail(str) {
  var supported = 0;
  if (window.RegExp) {
    var tempStr = "a";
    var tempReg = new RegExp(tempStr);
    if (tempReg.test(tempStr)) supported = 1;
  }
  if (!supported)
    return (str.indexOf(".") > 2) && (str.indexOf("@") > 0);
  var r1 = new RegExp("(@.*@)|(\\.\\.)|(@\\.)|(^\\.)");
  var r2 = new RegExp("^.+\\@(\\[?)[a-zA-Z0-9\\-\\.]+\\.([a-zA-Z]{2,3}|[0-9]{1,3})(\\]?)$");
  return (!r1.test(str) && r2.test(str));
}

function KeepCount() {

var NewCount = 0;
var i = 1;
window.alert(document.NewUser.sel1[1]);
for(i=1;i<5;i++){//get the current count
if (document.NewUser.sel1[i].checked)
{NewCount++;}
}

if (NewCount == 3){//3 have been checked so far... disabled the others

var i = 1;
for(i=1;i<5;i++){//let's disable all the others that have not been checked
if (!document.NewUser.sel1[i].checked){document.NewUser.sel[i].disabled = true;}
}
window.alert('You have selected 3 options, this is the form maximum.');
}

if(NewCount < 3){//less than 3 have been checked so far... undisable any that are disabled

var i = 1;
for(i=1;i<5;i++){//let's disable all the others that have not been checked
document.NewUser.sel1[i].disabled = false;
}

}

}

function EvaluateField()
{
        var userName                = document.NewUser.name.value;
        var userEmail                = document.NewUser.email.value;
        var userEmail2                = document.NewUser.email1.value;
        var SiteName                = document.NewUser.site.value;
        var SiteURL                = document.NewUser.url.value;
        var SiteLanguage        = document.NewUser.language.selectedIndex;

        if(SiteLanguage==0 ){
                alert('You need to set your primary site language.');
                document.NewUser.language.focus();
                return false;
        }

        if(userName == "")
        {
                alert("The field \"Your name\" must be filled.");
                document.NewUser.name.focus();
                return false;
        }


        if(userEmail == "")
        {
                alert("The field \"Your E-mail address\" must be filled.");
                document.NewUser.email.focus();
                return false;
        }
        else
        {
                if(isEmail(userEmail) == false)
                {
                        alert(userEmail + " can not be used as an email address.");
                        document.NewUser.email.focus();
                        return false;
                }
        }

        if(userEmail != userEmail2)
        {
                alert("The fields \"Your E-mail address\" and \"Confirm your E-mail address\" must be identically.");
                document.NewUser.email.focus();
                return false;
        }



        if(SiteName == "")
        {
                alert("The field \"Your site name\" must be filled.");
                document.NewUser.site.focus();
                return false;
        }

        if(SiteURL == "")
        {
                alert("The field \"Your site URL\" must be filled.");
                document.NewUser.url.focus();
                return false;
        }

        if(SiteURL == "http://")
        {
                alert("The field \"Your site URL\" must be filled.");
                document.NewUser.url.focus();
                return false;
        }


        alert('We will now open your site to check that your URL is correct. Please follow the information on top of the next screen.')

        return true;

}
</SCRIPT>
<!-- Begin of table--><center><BR>
        <table border="0" cellpadding="5" cellspacing="5" width="700">
          <tr>

            <td>
<p align="center"><B>
After filling out the boxes, read and accept the terms & conditions.</b><BR>
</p>
<FORM name=NewUser action="" method=post>

<table width="" border="0" cellspacing="0" cellpadding="0" align="center">
  <tr>
     <td width="200" align="left">Your Name:</td>
     <td align="left" width="200">
       <input type="text" name="name" size="30">
    </td>
  </tr>
  <tr>
     <td width="200" align="left">Your E-mail address:</td>

     <td align="left" width="200">
       <input type="text" name="email" size="30">
    </td>
  </tr>
  <tr>
     <td width="200" align="left">Confirm E-mail address:</td>
     <td align="left" width="200">
       <input type="text" name="email1" size="30">

    </td>
  </tr>
  <tr>
     <td width="200" align="left">Share Your E-mail:</td>
     <td align="left" width="200">
        <SELECT name="share"><OPTION value=0 selected>No, Keep my
              email private</OPTION><OPTION value=1>Yes, show it to my up & down line</OPTION></SELECT>
    </td>

  </tr>
  <tr>
     <td width="200" align="left">Your Website Name:</td>
     <td align="left" width="200">
       <input type="text" name="site" size="30">
    </td>
  </tr>
  <tr>

     <td width="200" align="left">Your Website URL:</td>
     <td align="left" width="200">
       <input type="text" name="url" value="http://" size="30">
    </td>
  </tr>
    <tr>
      <td width="200" align="left" class="text" valign="top">Show Your Site In:</td>
      <td align="left" class="text" width="200">


<INPUT TYPE=CHECKBOX VALUE="1" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Arts & Humanities<BR>

<INPUT TYPE=CHECKBOX VALUE="2" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Auto, Boating & Aviation<BR>

<INPUT TYPE=CHECKBOX VALUE="3" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Computing & Technology<BR>

<INPUT TYPE=CHECKBOX VALUE="4" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Health & Fitness<BR>

<INPUT TYPE=CHECKBOX VALUE="5" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Internet & Online<BR>

<INPUT TYPE=CHECKBOX VALUE="6" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Leisure & Entertainment<BR>

<INPUT TYPE=CHECKBOX VALUE="7" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Lifestyle<BR>

<INPUT TYPE=CHECKBOX VALUE="8" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Reference, Media & News<BR>

<INPUT TYPE=CHECKBOX VALUE="9" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Personal<BR>

<INPUT TYPE=CHECKBOX VALUE="10" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Services<BR>

<INPUT TYPE=CHECKBOX VALUE="11" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Shopping<BR>

<INPUT TYPE=CHECKBOX VALUE="12" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Society & Culture<BR>

<INPUT TYPE=CHECKBOX VALUE="13" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Travel<BR>

<INPUT TYPE=CHECKBOX VALUE="14" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Work & Money<BR>

<INPUT TYPE=CHECKBOX VALUE="16" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Advertising<BR>

<INPUT TYPE=CHECKBOX VALUE="17" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Affiliate Programs<BR>

<INPUT TYPE=CHECKBOX VALUE="18" name="'sel[1]' , , 'sel[2]' , , 'sel[3]'">
Auctions<BR>




      </td>

    </tr>
    <tr>
      <td width="200" align="left" class="text" valign="top">You Are Interested In:</td>
      <td align="left" class="text" width="200">
  

<BR>    <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="1 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Arts & Humanities<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="2 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Auto, Boating & Aviation<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="3 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Computing & Technology<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="4 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Health & Fitness<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="5 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Internet & Online<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="6 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Leisure & Entertainment<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="7 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">

Lifestyle<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="8 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Reference, Media & News<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="9 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Personal<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="10 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">

Services<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="11 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Shopping<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="12 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Society & Culture<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="13 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">

Travel<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="14 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Work & Money<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="16 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Advertising<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="17 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">

Affiliate Programs<BR>

   <INPUT onClick="KeepCount();" TYPE=CHECKBOX VALUE="18 
" name="'sel1[1]' , , 'sel1[2]' , , 'sel1[3]' ">
Auctions<BR>




      </td>
  <tr><br>
     <td width="200" align="left">Your Websites Language is:</td>
     <td align="left" width="200">

   <select name="sel6[6]">
<OPTION value="6">English</OPTION>

<OPTION value="7">Other</OPTION>

</SELECT>
    </td>
  </tr>
  <tr>
     <td align="left" width="450" colspan=2>

<br><BR>
<!--begin Terms-->

<b>Terms & Conditions </b><ul>
<li> Your site(s) does not contain any message boxes
<li> Your site(s) does not contain inappropriate contents
<li> Your site(s) does not break out of frames
<li> Your site(s) does not use site rotation
<li> Your site(s) does not use URL or domain forwarding
<li> Your account will be deleted if not used for 90 days

<li> Your account will be deleted if we can not send youemails
<li> Your account can be disable if it causes system any problems
<li> You are not allowed to have more than one (1) account 
<li> Your site(s) does not contain any popup windows
<!--end Terms-->
</ul>

<BR></td>
  </tr>
</table>
<center>

<INPUT onclick="return EvaluateField();" type=submit name="add" value="Accept Terms & Conditions">
</center>
<!-- End of table-->
</form>
</td></tr></table></center>
</td>
              </tr>
            </table></td>
        </tr>
             </table>


</table>

</body>
</html>


Link to comment
Share on other sites

Have "onClick" be lower case: "onclick"

 

What's going on with the name="sel[1]...." for all those checkboxes?

 

Also, move all the javascript right inside the header, rather than the body. (In between <head></head> tags instead of <body></body> tags)

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.