public static function SetupLocationData($content) { $content['timezone'] = array('timezone' => $content['timezone']); $content = array_merge($content, Atlas::getCoordinates($content)); $content = array_merge_recursive($content, array('timezone' => Atlas::getTimeZone(time(), $content['timezone']['timezone']))); $content['timezone']['string'] = Atlas::getTimeZoneString($content['timezone']); $html = array(); $html[] = $content['long']['degrees'] . '°' . $content['long']['min'] . '′' . $content['long']['direction']; $html[] = ' '; $html[] = $content['lat']['degrees'] . '°' . $content['lat']['min'] . '′' . $content['lat']['direction']; $content['location_string'] = join('', $html); $content['city_string'] = sprintf('%s, %s, %s <small class="autocomplete">%s UTC %s</small>', $content['name'], $content['region_name'], $content['country_name'], $content['location_string'], $content['timezone']['string']); $content['city_string_home'] = sprintf('%s, %s, %s <small>%s UTC %s</small>', $content['name'], $content['region_name'], $content['country_name'], $content['location_string'], $content['timezone']['string']); return $content; }
private function setTodaysChart() { list($mm, $numday, $yyyy, $fullmonth, $dow, $hours, $minutes, $am_pm) = split('[/.-]', date("m.d.Y.F.w.g.i.a", $this->_Page['sun']['sunrise'])); $this->_TodaysChartInput['timezone'] = Atlas::getTimeZone($this->_Page['sun']['sunrise'], $this->_Page['placeSearch']['timezone']['timezone']); $this->_TodaysChartInput['longitude'] = $current_location['longitude']; $this->_TodaysChartInput['latitude'] = $current_location['latitude']; $this->_TodaysChartInput['day'] = $numday; $this->_TodaysChartInput['month'] = $mm; $this->_TodaysChartInput['year'] = $yyyy; $this->_TodaysChartInput['hour'] = $hours; $this->_TodaysChartInput['min'] = $minutes; $this->_TodaysChartInput['report_name'] = 'Todays Chart At Sunrise'; $this->_TodaysChartInput['city'] = $this->_Page['city']; $this->_TodaysChartInput['country'] = $this->_Page['country']; $this->_TodaysChartInput['am_pm'] = $am_pm; $this->_TodaysChartInput['sex'] = 'female'; $this->_TodaysChartInput['has_all_info'] = true; $todayTransits = new AstroReport($this->_TodaysChartInput); $this->_Page['todayPlanet'] = $todayTransits->getPlanets(); }