<?php include("includes/config.php"); ?>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Career : Frontier Public High School</title>
<link rel="stylesheet" type="text/css" href="styles/my.css"  />
<script type="text/javascript" src="js/jquery-1.3.2.js"></script>
</head>

<body>
<!-- Wrapper Starts Here -->
<div id="wrapper">
<?php 
include("includes/header.php");
//include("includes/slideshow.php");
?>
<!-- Contents Starts -->
<div class="content">
<form action="career-next.php" method="post" enctype="multipart/form-data" name="career" id="career">
  <table border="0">
    <tr>
      <td scope="col">&nbsp;</td>
      <th colspan="2" scope="col">Career at Frontier Public School</th>
      </tr>
    <tr>
      <td width="8%" scope="col">&nbsp;</td>
      <td width="26%" scope="col">Name</td>
      <td width="66%" scope="col"><input type="text" name="name" id="name" required /></td>
      </tr>
    <tr>
      <td scope="col">&nbsp;</td>
      <td scope="col">Phone </td>
      <td scope="col"><input type="text" name="phone" id="phone" required /></td>
      </tr>
    <tr>
      <td scope="col">&nbsp;</td>
      <td scope="col">Email </td>
      <td scope="col"><input type="email" name="email" id="email" required /></td>
      </tr>
    <tr>
      <td scope="col">&nbsp;</td>
      <td scope="col">Address</td>
      <td scope="col"><label for="address"></label>
        <textarea name="address" id="address" cols="45" rows="5" required></textarea></td>
      </tr>
    <tr>
      <td scope="col">&nbsp;</td>
      <td scope="col">Education Level </td>
      <td scope="col"><input type="text" name="education" id="education" required /></td>
      </tr>
    <tr>
      <td scope="col">&nbsp;</td>
      <td scope="col">Attach CV</td>
      <td scope="col"><label for="cv"></label>
        <input type="file" name="cv" id="cv" required /></td>
      </tr>
    <tr>
      <td scope="col">&nbsp;</td>
      <td scope="col">&nbsp;</td>
      <td scope="col"><input type="submit" name="button" id="button" value="Submit" /></td>
      </tr>
  </table>
</form>
<script>
    var createAllErrors = function() {
        var form = $( this ),
            errorList = $( "ul.errorMessages", form );

        var showAllErrorMessages = function() {
            errorList.empty();

            // Find all invalid fields within the form.
            var invalidFields = form.find( ":invalid" ).each( function( index, node ) {

                // Find the field's corresponding label
                var label = $( "label[for=" + node.id + "] "),
                    // Opera incorrectly does not fill the validationMessage property.
                    message = node.validationMessage || 'Invalid value.';

                errorList
                    .show()
                    .append( "<li><span>" + label.html() + "</span> " + message + "</li>" );
            });
        };

        // Support Safari
        form.on( "submit", function( event ) {
            if ( this.checkValidity && !this.checkValidity() ) {
                $( this ).find( ":invalid" ).first().focus();
                event.preventDefault();
            }
        });

        $( "input[type=submit], button:not([type=button])", form )
            .on( "click", showAllErrorMessages);

        $( "input", form ).on( "keypress", function( event ) {
            var type = $( this ).attr( "type" );
            if ( /date|email|month|number|search|tel|text|time|url|week/.test ( type )
              && event.keyCode == 13 ) {
                showAllErrorMessages();
            }
        });
    };

    $( "form" ).each( createAllErrors );
</script>

</div>
<!-- Contents Ends -->
<?php
include("includes/sidebar.php");
include("includes/footer.php");
?>
</div>
<!-- Wrapper Ends -->
</body>
</html>
