<div class="col-sm-10"> <input type="genre" class="form-control" name="genre" placeholder="Enter Genre"> </div> </div> <div class="form-group"> <label class="control-label col-sm-2" for="parental_rating">Parental Rating:</label> <div class="col-sm-10"> <input type="parental_rating" class="form-control" name="parental_rating" placeholder="Enter Parental Rating"> </div> </div> <div class="form-group"> <label class="control-label col-sm-2" for="country">Country:</label> <div class="control-label col-sm-10"> <select class="input-medium form-control" name="country"> <?php $countries = countries_array(); foreach ($countries as $country) { echo "<option>" . $country . "</option>"; } ?> </select> </div> </div> <div class="form-group"> <label class="control-label col-sm-2" for="date">Date:</label> <div class="col-sm-10"> <input type="text" class="form-control" name="date" placeholder="Enter Date 'yyyy-mm-dd'"> </div> </div> <div class="form-group"> <label class="control-label col-sm-2" for="run_time">Runtime:</label>
/** * Get the country code for a pair of lat/long coordinates * * @param double $longitude decimal longitude * @param double $latitude decimal latitude * * @return string country code or empty */ function get_country($longitude, $latitude) { $countries = countries_array(); foreach ($countries as $country) { list($country_code, $country_boundary) = $country; if (pointInPolygon($longitude, $latitude, $country_boundary, $country_code)) { return $country_code; } } return ''; }