Skip to content

Commit

Permalink
Merge pull request #3042 from DanielBausset/sattimers_6_chars_grid
Browse files Browse the repository at this point in the history
Limit Grid square to 6 chars in request to df2et.de API
  • Loading branch information
magicbug authored Apr 2, 2024
2 parents 55d24cd + 2c3408e commit f8eeaab
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions application/controllers/Sattimers.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ public function index() {
$footerData['scripts'] = [
'assets/js/sections/sattimers.js?'
];
$url = 'https://www.df2et.de/tevel/api2.php?grid='.strtoupper($this->stations->find_gridsquare());
$data['gridsquare'] = substr(strtoupper($this->stations->find_gridsquare()), 0, 6);
$url = 'https://www.df2et.de/tevel/api2.php?grid=' . $data['gridsquare'];
$json = file_get_contents($url);
$data['activations'] = json_decode($json, true)['data'];
$data['gridsquare'] = strtoupper($this->stations->find_gridsquare());

$data['page_title'] = "Satellite Timers";

Expand Down

0 comments on commit f8eeaab

Please sign in to comment.