czy checkbox przy rejestracji to bariera ktorej bot nie pokona zeby sie zarejestrowac?
ponizszy kod uniemozliwia przejsc dalej jesli sie nie zannaczy checkbox'a. jak go przerobic aby pasowal do phpbb?
[xml]<html>
<head>
<script language="javascript" type="text/javascript">
var checkobj
function agreesubmit(el){
checkobj=el
if (document.all||document.getElementById){
for (i=0;i<checkobj.form.length;i++){
var tempobj=checkobj.form.elements[i]
if(tempobj.type.toLowerCase()=="submit")
tempobj.disabled=!checkobj.checked
}
}
}
function defaultagree(el){
if (window.checkobj&&checkobj.checked)
open_win()
else
alert("zaakceptuj najpierw regulamin")
return false
}
function open_win()
{
window.open("profile.php?mode=register&agreed=true")
}
</script>
</head>
<body>
<form name="agreeform" onSubmit="return defaultagree(this);">
tekst ktory trzeba zaakceptowac<br />
<input name="agreecheck" type="checkbox" onClick="agreesubmit(this)"><b>zgadzam sie powyzsze warukni</b><br>
<input type="submit" value="dalej" disabled>
</form>
<script>
document.forms.agreeform.agreecheck.checked=false
</script>
</body>
</html>[/xml]