<?php 
	include('/var/www/html/uclit/protected/common/login/check.php');
	include('/var/www/html/uclit/protected/common/css_login/css_head2.php');
	include('/var/www/html/uclit/protected/connections/db_comments.php');

	$today = "";
	$today = date("Y-m-d");

	//Select a database
	$db = mysql_select_db('comments', $commentsConn) or die("Couldn't select database. comments");

	//SQL statement
	$query= "SELECT DISTINCT Location FROM CommentCards ORDER BY Location";

	//execute SQL query and get result
	$sql_result = mysql_query($query, $commentsConn) or die ("Couldn't execute query <p>$query</p>");

	if (!$sql_result)
		echo "<p>couldn't get list! $sql_result</p>";
	else
	{
?>
<h2>Select Service Point Location</h2>
<form method='post' action='sel_commentbyloc.php'>
  <table CELLSPACING='3' CELLPADDING='3'>
    <tr>
      <td height='125' VALIGN=TOP><P><STRONG>Service Points:</STRONG><BR>
          <select name='comment_loc'>
            <option selected value=''>Select.......</option>
<?php
		while ($row = mysql_fetch_array($sql_result)) 
		{
			$locname = $row['Location'];
			echo "<option>$locname</option>";
		}
?>
          </select>
        <P>
          <INPUT TYPE='SUBMIT' NAME='submit' VALUE='Submit Service Point'>
        </P></td>
    </tr>
    <tr>
      <td width='904' height='125' VALIGN=TOP> <P>
        </td>
    </tr>
  </table>
</form>
<br />
<br />
<?php
	}
	include('/var/www/html/uclit/protected/common/css_login/css_foot2.php'); 
?>
