<table width="100%" cellpadding="5" cellspacing="0" border="0">
	<tr><td class="nav"><a href="index.php?section=home">Home</a>&nbsp;&gt;&nbsp;<a href="index.php?section=javascript&theme=<?php echo $data["theme"] ?>">JavaScript</a></td></tr>
	<tr><td>
	<table cellpadding="0" cellspacing=3" border="0" align="center">
		<form action='index.php' method='post'>
		<input type='hidden' name='section' value='javascript'>
			<tr>
				<td class="body">Select Theme:</td>
				<td><?php
				$options = $data["themes"];
				admin_form_element( array ("type" => "select", "name" => "theme", "options" => $options, "value" => $data["theme"]) );
				?></td>
			<td align="center" colspan="2"><?php
			admin_form_element( array ("type" => "button", "value" => "Load") );
			?></td></tr>
		</form>	
	</table>
	</td></tr>
	<tr><td>
		<table cellpadding="5" cellspacing="2" border="0" align="center">
		<form action="index.php" method="post">
		<input type="hidden" name="section" value="javascript">
		<input type="hidden" name="action" value="save">
		<input type="hidden" name="theme" value="<?php echo $data["theme"]; ?>">		
			<?php
			while(list($key,$val) = each($data["pages"])){
				?><tr><td class="form_cell"><?php echo $val; ?></td></tr>
				<tr><td class="form_cell"><table cellpadding="0" cellspacing="3" border="0">
					<tr><td class="body">Onload:</td><td class="highlight"><?php
					admin_form_element( array ("type" => "input", "size" => 75, "name" => "onloads[".$key."]", "value" => $data["javascripts"][$key][onload]) );
					?></td></tr>
					<tr><td class="highlight" valign="top">JS Code:</td><?php
					?><td class="highlight"><?php
					admin_form_element( array ("type" => "textarea", "wrap" => "off", "rows" => 5, "cols" => 76, "name" => "codes[".$key."]", "value" => $data["javascripts"][$key][code], "nostrip" => 1) );
					?></td></tr>
				</table></td></tr><?php
			}//while
			?>
			<tr><td colspan="2" align="center"><?php
			admin_form_element( array ("type" => "button", "value" => "Save") );
			?></td></tr>
		</form>
		</table>
	</td></tr>	
</table>