<?php

session_start();
header("Content-type: text/html; charset=".$_SESSION['encodingmode']);
if($_SESSION['dbName']==""){
header("location:../index.php");
}
include("config.inc.php");

$connection = mysql_connect($config['dbServer'],$config['dbUser'],$config['dbPass']) or die("Could not connect to DB");
mysql_select_db($_SESSION['dbName'],$connection) or die("Could not find DB");

if(	$_SESSION['encodingmode'] == 'utf8' || $_SESSION['encodingmode'] == 'utf-8'){
	mysql_query("SET NAMES 'utf8'"); 
	mysql_query('SET CHARACTER SET utf8'); 
	mysql_set_charset('utf8', $connection);
}




	
$querysetup="select DecimalBase, DecimalBase1, DecimalBase2, base1, base2, grid_color1, grid_color2,maxperpage from setup";
$resultsetup=mysql_query($querysetup,$connection) or die(mysql_error());
while($rowsetup=mysql_fetch_array($resultsetup)){
	extract($rowsetup);
}
print <<<HERE
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> 
<meta name="viewport" content="width=device-width, initial-scale=1.0"> 
<LINK REL="stylesheet" TYPE="text/css" MEDIA="all" HREF="css/tabs.css">

 
<title>Manifest Correction</title>
<script>
</script>
<style type="text/css">

</style>

<link type="text/css" rel="stylesheet" href="dhtmlgoodies_calendar.css?random=20051112" media="screen"></LINK>
<SCRIPT type="text/javascript" src="dhtmlgoodies_calendar.js?random=20060118"></script>
<LINK REL="stylesheet" TYPE="text/css" MEDIA="all" HREF="tabs.css">

<link rel="stylesheet" type="text/css" media="all" href="css-v2/style.css">
</head>
<body >
<form name='fromcr' id='formcr' method='post' >
<input type=hidden name='mode' value='$mode'>
<input type=hidden name='message' value='$message'>
<input type=hidden name='manifest_auto' value='$manifest_auto'>
HERE;


echo"<table cellpadding='0' cellspacing='0' border='0'  align='center' class='layout-width'>";
include_once("header.php");
echo" <tr><td  valign='top'>";

include_once("sidemenu.php");
echo"  </td></tr>";


echo" <tr style='height:26px;'>
		<td  valign='top' id='content-top'>
			<table border='0' cellpadding='0' cellspacing='0' style='table-layout:fixed; height:26px;' class='layout-width'>
			<tr style='height:26px;'>
				<td style='width:38px; height:26px;'>&nbsp;</td>
				<td valign='middle' style='width:300px; height:26px;'><span class='title' style='text-transform: uppercase'>$title</span></td>
				<td class='message' valign='middle' style='height:26px;'>".htmlspecialchars($message, ENT_QUOTES)."</td>
			</tr></table>
		</td>
	  </tr>";
	  

echo"<tr>
		<td  height='34'  valign='top' id='content-top2'>
		<table border='0' cellpadding='0' cellspacing='0' class='layout-width'>
			<tr>
				<td width='38'  height='34'>&nbsp;</td>
				<td valign='middle' height='34' width='720px'>
					<button type='button' id='btnClear' name='btnClear' onclick='ClearPage(); return false;' title='Clear Page'><span><span>ClearPage</span></span></button>";
		echo "<button type='button' id='btnPost' name='btnPost' onclick='SubmitRecord(); return false;' title='Save Changes' ><span><span>Save</span></span></button>&nbsp;";
		echo "<button type='button' id='btnSearch' name='btnSearch' onclick=\"searchCR('$crfttype'); return false;\" title='Search' ><span><span>Search</span></span></button>&nbsp;";
				echo"</td>
				<td align='left' width='250px'>
					</td>
				<td align='left'></td>
			</tr>
		</table>
	</td>
</tr>
<tr>
	<td id='content-body'>
		<table border='0'  align='center' valign='top'  class='tablecontent' >
				<col width=65%>
				<tr bgcolor='#F7F7F7' >
					<td valign='top' align='left'>
						<table border='0' style='table-layout:fixed' align='left'  cellpadding='0' cellspacing='0' valign='top'>
							<col width=120><col width=155><col width=120><col width=155><col width=120><col width=155><col width=120><col width=155>
							<col width=120><col width=155><col width=120><col width=155><col width=120><col width=155><col width=120><col width=155>";
//header
echo "<tr bgcolor='#F7F7F7' height='25'>
			<td valign='center' align='left' ><span class='style1'>Voyage Year</span></td>
			<td align='left'><input type='text' name='voy_year' id='voy_year' value='".$voy_year."' readonly style='font-size:12px; width:40px; ' maxlength='2' /></td>
			<td valign='center' align='left' ><span class='style1'>No. BS</span></td>
			<td align='left'><span class='style1'>".$crft_reference." </span></td>
			<td valign='center' align='left' colspan='4'></td>
		</tr>";
									



echo "</table></td></tr>
	</table></td></tr>
	</td>
	</tr>";							
echo" 	</td></tr>";

echo" <tr height='30'><td align='center' id='content-bottom' ></td></tr>";
include("footer.php");	
echo" </table>  ";//end of last table menu		 



print <<<HERE
</form>
</body>

HERE;

?>














