/*
 * Author(s): Tricia Woodruff
 * Date: 2004-Aug-10
 * Copyright: Classified Ventures
 * Description: provides error message text 
 */

 
/* 
 * Error message constants
 */
var unrecoverable_error_header = "<div class='errorhdr'>Sorry, our servers had a problem fulfilling your request.</div>";

var error_header = "<div class='errorhdr'>Please fix the following problems before continuing.</div>";

var validation_error_header = "The following field(s) contain invalid or incomplete information:" ;

var required_error_header = "The following field(s) are required:"; 

var error_start_text = "<table class='hardErrorBox' border='0' cellspacing='0' cellpadding='0'><tr><td>";

var warning_error_start_text = "<table class='softErrorBox' border='0' cellspacing='0' cellpadding='0'><tr><td>";

var alert_error_start_text = "<table class='softErrorBox alertBox' border='0' cellspacing='0' cellpadding='0'><tr><td>";

var session_time_out_start_text = "<div class='errorhdr'>Your session has expired, or you tried to access a page that is otherwise no longer available.</div>";

var expired_story_start_text = "<div class='errorhdr'>You tried to access a page that is no longer available.</div>";

/*search results header*/
var no_search_results_start_text = "<div class='errorhdr'>Your search returned no results.</div>";
var too_many_search_results_start_text = "<div class='errorhdr'>Your search returned too many results.</div>";

var error_end_text = "</td></tr></table>";


/*
 * Create an array defining labels, error codes and associated messages for each field 
 */

/* Registration form fields */
var error = new Array();


//make
error["required,select_criteria"] = "Please make at least one selection (i.e. a vehicle, author or date range) before submitting your search for reviews.";

//publication date
error["publicationDateRange,date_out_of_range"] = "The publication data range supplied is invalid.  Please make sure the earlier date appears first."

/*dealer locator search form*/
error["zc,label"] = "Zip Code"
error["zc,ERR_INV_ZC"] = "This field must be a 5-digit U.S. ZIP code (like 94043).";
error["zc,NO_DL_ZIP"] = "Please enter a valid ZIP code.";
error["make,label"] = "Vehicle Make";
error["make,ANY_PLUS_MAKE"] = "Please select either 'Any' or a make, but not both.";

error["photos,ERR_BAD_PHOTOURL"] = "One or more of the vehicle photos could not be displayed";
error["photos,ERR_NO_PHOTOS"] = "Photos and video are not available for this vehicle";
error["search,NO_RESULTS"] = "Sorry, the vehicle you requested was not found. It is possible that the vehicle has been sold or otherwise removed from our database. Please try a <a href=\"/go/buyIndex.jsp\" target=\"_self\">new search</a>, or go back to the <a href=\"javascript:history.back()\">previous</a> page.";

//Lead forms
error["PHONE,label"] = "Phone number";
error["email,label"] = "Email"; 
error["firstName,label"] = "First Name";
error["lastName,label"] = "Last Name";
error["zipCode,label"] = "ZIP code";
error["offerTradeIn,label"] = "Trade-in";
error["tradeInYear,label"] = "Trade-in Year";
error["tradeInMileage,label"] = "Trade-in Mileage";


error["email,invalid_email_address"] = "The email address is invalid";
error["email,www_found"] = "The email address is invalid";
error["zipCode,invalid_zipcode"] = "The ZIP code is invalid";
error["PHONE,invalid_phone_number"] = "The phone number is invalid";
error["offerTradeIn,missing_fields"] = "The trade-in information is incomplete";
error["tradeInYear,invalid_year"] = "The trade-in year is invalid";
error["tradeInMileage,invalid_mileage"] = "The trade-in mileage is invalid";