Jump to content



Issue Information

  • #000507

  • 0 - None Assigned

  • Won't Fix

  • 2.3.2

  • -

Issue Confirmations

  • Yes (1)No (0)
Photo

catalog/advanced_search_results error in test wrt to dob string

Posted by Juto on 14 September 2012 - 21:34

In the test of a valid dob string at the top of the file current code is:


    (isset($_GET['dfrom']) && (empty($_GET['dfrom']) || ($_GET['dfrom']  == DOB_FORMAT_STRING))) &&
    (isset($_GET['dto']) && (empty($_GET['dto']) || ($_GET['dto']  == DOB_FORMAT_STRING))) &&


I do believe it should test for an invalid dob string like so:

 
    (isset($_GET['dfrom']) && (empty($_GET['dfrom']) || ($_GET['dfrom'] != DOB_FORMAT_STRING))) &&
    (isset($_GET['dto']) && (empty($_GET['dto']) || ($_GET['dto'] != DOB_FORMAT_STRING))) &&


Sara

changed status to: Won't Fix

That part is not actually checking if dfrom/dto is a valid date, but if it is equal to the format of a valid date. This was used in the input field as a placeholder in an older version.

For reference, here is the commit that removed the placeholder:

https://github.com/o...2161d8beb313c5c