-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
7 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ | |
/** | ||
* | ||
* @package Mind | ||
* @version Release: 6.0.1 | ||
* @version Release: 6.0.2 | ||
* @license GPL3 | ||
* @author Ali YILMAZ <[email protected]> | ||
* @category Php Framework, Design pattern builder for PHP. | ||
|
@@ -2369,9 +2369,9 @@ public function is_blood($blood, $donor = null){ | |
* @param float|int|string $latitude | ||
* @return bool | ||
*/ | ||
public function is_latitude($latitude){ | ||
$lat_pattern = '/\A[+-]?(?:90(?:\.0{1,18})?|\d(?(?<=9)|\d?)\.\d{1,18})\z/x'; | ||
|
||
public function is_latitude($latitude) { | ||
$lat_pattern = '/\A[+-]?(?:90(?:\.0+)?|(?:[0-8]?\d(?:\.\d+)?|90(?:\.0+)?))\z/'; | ||
if (preg_match($lat_pattern, $latitude)) { | ||
return true; | ||
} else { | ||
|
@@ -2384,9 +2384,10 @@ public function is_latitude($latitude){ | |
* @param float|int|string $longitude | ||
* @return bool | ||
*/ | ||
public function is_longitude($longitude){ | ||
$long_pattern = '/\A[+-]?(?:180(?:\.0{1,18})?|(?:1[0-7]\d|\d{1,2})\.\d{1,18})\z/x'; | ||
public function is_longitude($longitude) { | ||
|
||
$long_pattern = '/\A[+-]?(?:180(?:\.0+)?|(?:1[0-7]\d|\d{1,2})(?:\.\d+)?)\z/'; | ||
|
||
if (preg_match($long_pattern, $longitude)) { | ||
return true; | ||
} else { | ||
|