src/Lootils/Geo/Location.php
public function DMSLongitude($format = '%d %d %F %s') {
    $long = $this->convertDecToDMS($this->longitude());

    $direction = 'E';
    if ($long['degrees'] < 0) {
      $direction = 'W';
    }

    return sprintf($format, $long['degrees'], $long['minutes'], $long['seconds'], $direction);
  }
public function DMSLongitude($format = '%d %d %F %s') {
    $long = $this->convertDecToDMS($this->longitude());

    $direction = 'E';
    if ($long['degrees'] < 0) {
      $direction = 'W';
    }

    return sprintf($format, $long['degrees'], $long['minutes'], $long['seconds'], $direction);
  }
Get the current longitude in Degrees, Minutes, Seconds notation.

@param string $format
The format string to use for the response. Defaults to %d %d %F %s

@return string
A string with the current longitude in DMS format.