From 0187548829334de6d6e3d871d60efc4435350362 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Sun, 13 Jan 2019 19:11:46 +0000 Subject: [PATCH] Converted ADIF pages to Bootstrap 4 and removed the dxcluster controller --- application/controllers/Adif.php | 8 +- application/controllers/Dxcluster.php | 116 ------------------ application/controllers/Install.php | 24 ---- application/views/adif/import.php | 39 ++++-- application/views/adif/import_success.php | 21 +++- application/views/interface_assets/header.php | 4 +- 6 files changed, 55 insertions(+), 157 deletions(-) delete mode 100644 application/controllers/Dxcluster.php delete mode 100644 application/controllers/Install.php diff --git a/application/controllers/Adif.php b/application/controllers/Adif.php index 2d35f091..837886b6 100644 --- a/application/controllers/Adif.php +++ b/application/controllers/Adif.php @@ -95,9 +95,9 @@ class adif extends CI_Controller { //exit(0); $data['error'] = $this->upload->display_errors(); - $this->load->view('layout/header', $data); + $this->load->view('interface_assets/header', $data); $this->load->view('adif/import'); - $this->load->view('layout/footer'); + $this->load->view('interface_assets/footer'); } else { @@ -129,9 +129,9 @@ class adif extends CI_Controller { unlink('./uploads/'.$data['upload_data']['file_name']); $data['page_title'] = "ADIF Imported"; - $this->load->view('layout/header', $data); + $this->load->view('interface_assets/header', $data); $this->load->view('adif/import_success'); - $this->load->view('layout/footer'); + $this->load->view('interface_assets/footer'); } } diff --git a/application/controllers/Dxcluster.php b/application/controllers/Dxcluster.php deleted file mode 100644 index 785f50f3..00000000 --- a/application/controllers/Dxcluster.php +++ /dev/null @@ -1,116 +0,0 @@ -load->view('layout/header', $data); - $this->load->view('dxcluster/main'); - $this->load->view('layout/footer'); - } - - /* loads custom spots based on band */ - public function custom($band) - { - $data['page_title'] = "DX Cluster"; - - $data['band'] = $band; - - $this->load->view('layout/header', $data); - $this->load->view('dxcluster/custom'); - $this->load->view('layout/footer'); - } - - /* returns formatted json for all spots */ - public function all_spots() { - - $jsonurl = "http://www.dxcluster.co.uk/api/all"; - - $json = @file_get_contents($jsonurl,0,null,null); - $json_output = json_decode($json); - - //print_r($json_output); - $i = 0; - foreach ($json_output as $name => $value) { - - echo ''; - echo "".$value->mytime.""; - echo "".$value->call.""; - echo "".$value->freq.""; - echo "".$value->dxcall.""; - echo "".htmlspecialchars($value->comment).""; - echo ""; - $i++; - } - } - - /* returns formatted json for custom spots */ - public function custom_spots($band) { - - $jsonurl = "http://www.dxcluster.co.uk/api/data_band/".$band; - - $json = @file_get_contents($jsonurl,0,null,null); - $json_output = json_decode($json); - - //print_r($json_output); - $i = 0; - foreach ($json_output as $name => $value) { - - echo ''; - echo "".$value->mytime.""; - echo "".$value->call.""; - echo "".$value->freq.""; - echo "".$value->dxcall.""; - echo "".htmlspecialchars($value->comment).""; - echo ""; - $i++; - } - } -} - -function isDomainAvailible($domain) - { - //check, if a valid url is provided - if(!filter_var($domain, FILTER_VALIDATE_URL)) - { - return false; - } - - //initialize curl - $curlInit = curl_init($domain); - curl_setopt($curlInit,CURLOPT_CONNECTTIMEOUT,10); - curl_setopt($curlInit,CURLOPT_HEADER,true); - curl_setopt($curlInit,CURLOPT_NOBODY,true); - curl_setopt($curlInit,CURLOPT_RETURNTRANSFER,true); - - //get answer - $response = curl_exec($curlInit); - - curl_close($curlInit); - - if ($response) return true; - - return false; - } - - - -/* End of file dxcluster.php */ \ No newline at end of file diff --git a/application/controllers/Install.php b/application/controllers/Install.php deleted file mode 100644 index 4903fb5b..00000000 --- a/application/controllers/Install.php +++ /dev/null @@ -1,24 +0,0 @@ - -

-

Important Log files must have the file type .adi

+
- +

ADIF Functions

- +
+
+ +
+
+
+

-

+

Important Log files must have the file type .adi

- +
+ + -
+ + +
+
+ +
+ +
+
+ ADIF Export +
+
+
Take your logbook file anywhere!
+

Exporting ADIFs allows you to import contacts into third party applications like LoTW, Awards or just for keeping a backup.

+ Export All QSOs +
+
+ diff --git a/application/views/adif/import_success.php b/application/views/adif/import_success.php index 7db3d229..fb7cca95 100644 --- a/application/views/adif/import_success.php +++ b/application/views/adif/import_success.php @@ -1,6 +1,21 @@ -
-

ADIF Imported

+
+
+ session->flashdata('message')) { ?> + +
+

session->flashdata('message'); ?>

+
+ + +
+
+ ADIF Imported +
+
+
Yay, its imported!
+

The ADIF File has been imported, and any dupes skipped.

+
+
-

The ADIF File has been imported, and any dupes skipped.

diff --git a/application/views/interface_assets/header.php b/application/views/interface_assets/header.php index 05c3adae..d5cd62ab 100644 --- a/application/views/interface_assets/header.php +++ b/application/views/interface_assets/header.php @@ -62,9 +62,9 @@ ADIF Import/Export - LoTW Import/Export + LoTW Import/Export - eQSL Import/Export + eQSL Import/Export Backup