A polygon needs to have atleast 4 points.

This commit is contained in:
Madhura Jayaratne 2011-07-03 22:36:34 +05:30
parent ae88c2e758
commit cfeb031d1f

View File

@ -178,8 +178,8 @@ if(isset($_REQUEST['generate']) && $_REQUEST['generate'] == true) {
if ($type == 'MULTILINESTRING' && $no_of_points < 2) {
$no_of_points = 2;
}
if ($type == 'POLYGON' && $no_of_points < 3) {
$no_of_points = 3;
if ($type == 'POLYGON' && $no_of_points < 4) {
$no_of_points = 4;
}
if (isset($gis_data[$a][$type][$i]['add_point'])) {
$no_of_points++;