The coordinates are for an airport in Guinea-Bissau. It should be noted that the library still calculates the correct latitude and longitude, so it works, but the warning poses a problem for anyone who converts warnings, notices, etc. into exceptions automatically (typically done when using a framework).
The warning is not emitted if you add zero-filled seconds to the coordinates:
PHP version: 7.4.6 Library version: 3.0.0
Passing a set of non-decimal coordinates without seconds to
CoordinateFactory::fromString()
will emit the following PHP warning:PHP Warning: A non-numeric value encountered in /home/../vendor/mjaschen/phpgeo/src/Factory/CoordinateFactory.php on line 177
Reproducible by the following code:
$coordinates = CoordinateFactory::fromString('11°17′N 15°50′W');
The coordinates are for an airport in Guinea-Bissau. It should be noted that the library still calculates the correct latitude and longitude, so it works, but the warning poses a problem for anyone who converts warnings, notices, etc. into exceptions automatically (typically done when using a framework).
The warning is not emitted if you add zero-filled seconds to the coordinates:
$coordinates = CoordinateFactory::fromString('11°17′00″N 15°50′00″W');
However the coordinates in question are of a valid format, so the library shouldn't be emitting the warning.