<?
header("Content-type: text/html;charset=windows-1251;");
 
$atemps = 0;
if(strlen($question)<3){
    $atemp = "Вопрос имеет слишком мало символов.<br>";
    $atemps = 1;
}
if(!preg_match("([0-9]+)",$answer)){
    $atemp .= "Неверно задано число ответов.";
    $atemps = 1;
}
if($atemps==0){
?>
<input type="hidden" name="ajquestion" value="<?=iconv("UTF-8","CP1251",$question);?>">
<input type="hidden" name="ajanswer" value="<?=iconv("UTF-8","CP1251",$answer);?>">
<table cellpadding="2" cellspacing="2" border="0" width="100%" class="text" id="golos3">
   
    <tr>
    <td width="15%" align="right"></td>
    <td width="85%" colspan="3">
    <strong><?=iconv("UTF-8","CP1251",$question);?></strong>
   
    </td>
    </tr>
   
    <?
    for($i=0;$i<iconv("UTF-8","CP1251",$answer);$i++){
        ?>
        <tr>
        <td width="15%" align="right">Ответ №<?=$i+1?></td>
        <td width="85%" colspan="3">
        <input type="text" class="login" name="answer<?=$i?>">
        </td>
        </tr>
    <?
    }
    ?>   
   
 
</table>
<? }?>