Location: PHPKode > projects > Decider > decider/Initial_Questionaire/initialquizform.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><link rel="stylesheet" type="text/css" href="../common/styles.css" />
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
<!-- help code-->
<script language="javascript">
var id;
var txtname;
function handleSearchSuggest(txt) {
var str;

			id=txt;
			txtname=txt;		
			var ss = document.getElementById("help");
			ss.innerHTML = '';
			if(id=="initialqustionhelp"){
		    str = "This is the starting of analysis phase. You can use this questionnaire to initially identify the client organization and what they need. Just select the client organization and proceed";
			}
			
			var suggest = '<div onmouseover="javascript:helpOver(this);" ';
			suggest += 'onmouseout="javascript:helpOut(this);" ';
			suggest += 'onclick="javascript:closeBox(this.innerHTML);" ';
			suggest += 'class="suggest_link">'+ str + '</div>';
			ss.innerHTML += suggest;
			}

//Mouse over function
function helpOver(div_value) {
	div_value.className = 'help_over';
}
//Mouse out function
function helpOut(div_value) {
	div_value.className = 'help_out';
}
//Click function
function closeBox(value) {
	document.getElementById("help").innerHTML = '';
}

</script>
</head>

<body>


<div class="topic">Initial Questions</div>



<form  action="initialquizformtab.php" method="post">
<table><tr><td class="label">Client Organization Name:</td><td><select  id="client_Name" name="client_Name" class="select">
			<?php
			require("../common/database.php");
			 $result = mysql_query( "SELECT * FROM client");
			 while($row=mysql_fetch_array($result)){
			 	?>
				<option value="<?php echo $row['Name']?>"><?php echo $row['Name']?></option>
				
				<?php
			 }
			 
			?>
	</select></td><td><img src="../common/HelpIcon.gif" height="30" width="30" type="" name="Submit"  id="initialqustionhelp" onClick="handleSearchSuggest(this.id)" class="pointer"><div id="help" class="length" > </div>
</td></tr></table>

<hr width="500px;" align="left" />

<table>
		<?php
		//require("../common/database.php");
		$result = mysql_query( "SELECT * FROM initial_quiz");
		$i=0;
			 while($row=mysql_fetch_array($result)){
					$i++;
		?>
				<tr valign="top"><td class="label"><?php echo $i.". "?></td>
				<td class="label" width="500px" align="justify"><?php echo $row['Question']?></td>
				</tr><tr><td></td>
				<?php $textarea="textarea".$i;
				$id=id.$i;
				?>
				
<!-- creating text boxes -->
				  <td class="label"><textarea  cols="40" class="textboxarea" id="<?php echo $textarea;?>" name="<?php echo $textarea;?>" ></textarea >
				  <input type="hidden" id="<?php echo $id?>" name="<?php echo $id?>" value="<?php echo $row['Id'];?>">
				  
				  </td>
				</tr><tr><td></td></tr>
				
			<?php
			 }
			 
			?>
			<input type="hidden" name="no_of_quiz" id="no_of_quiz" value="<?php echo $i;?>">
			<tr><td></td><td><input type="submit" class="button" value="     Ok    " id="add" name="add"/></td></tr>
  </table>
  
  
</form>
</body>
</html>
Return current item: Decider