firstly sorry for my english ...
I have written a code but the javascript as operand warning How do I get my screen to come?
codes are the following:
sayisal.php
<?php
$islemler = array('-','+');
$say1 = rand(10,20);
$say2 = rand(1,9);
$say3 = rand(0,1);
echo $say1.$islemler[$say3].$say2.' <form action="onay.php" method="post"> <input type="text" name="cevap"><input type="hidden" name="islem" value="'.$islemler[$say3].'"><input type="hidden" name="say1" value="'.$say1.'"><input type="hidden" name="say2" value="'.$say2.'">
</form> ';
?>
onay.php
<?php
if($_POST['islem']=='-'){
$deger = $_POST['say1'] - $_POST['say2'];
}else{
$deger = $_POST['say1'] + $_POST['say2'];
}
if($deger == $_POST['cevap']){
echo 'islem dogru';
}else{
echo 'islem yanlis';
}
?>