Move JS to separate file

This commit is contained in:
phl0
2026-03-05 09:06:25 +01:00
parent 9cab971888
commit 3541e079db
2 changed files with 25 additions and 0 deletions

View File

@@ -340,6 +340,10 @@ function stopImpersonate_modal() {
<script id="dxccmapjs" type="text/javascript" src="<?php echo $this->paths->cache_buster('/assets/js/sections/dxccmap.js'); ?>" tileUrl="<?php echo $this->optionslib->get_option('option_map_tile_server');?>"></script> <script id="dxccmapjs" type="text/javascript" src="<?php echo $this->paths->cache_buster('/assets/js/sections/dxccmap.js'); ?>" tileUrl="<?php echo $this->optionslib->get_option('option_map_tile_server');?>"></script>
<?php } ?> <?php } ?>
<?php if ($this->uri->segment(1) == "awards" && ($this->uri->segment(2) == "wae") ) { ?>
<script id="waejs" type="text/javascript" src="<?php echo $this->paths->cache_buster('/assets/js/sections/wae.js'); ?>"></script>
<?php } ?>
<?php if ($this->uri->segment(1) == "statistics" && $this->uri->segment(2) == "") { ?> <?php if ($this->uri->segment(1) == "statistics" && $this->uri->segment(2) == "") { ?>
<script type="text/javascript" src="<?php echo $this->paths->cache_buster('/assets/js/chart.js'); ?>"></script> <script type="text/javascript" src="<?php echo $this->paths->cache_buster('/assets/js/chart.js'); ?>"></script>
<script type="text/javascript" src="<?php echo $this->paths->cache_buster('/assets/js/chartjs-plugin-piechart-outlabels.js'); ?>"></script> <script type="text/javascript" src="<?php echo $this->paths->cache_buster('/assets/js/chartjs-plugin-piechart-outlabels.js'); ?>"></script>

21
assets/js/sections/wae.js Normal file
View File

@@ -0,0 +1,21 @@
$('#band2').change(function(){
var band = $("#band2 option:selected").text();
if (band != "SAT") {
$("#sats").val('All');
$("#orbits").val('All');
$("#satrow").hide();
$("#orbitrow").hide();
} else {
$("#satrow").show();
$("#orbitrow").show();
}
});
$('#band2').change(); // trigger the change on fresh-load to hide/show SAT-Params
$('#sats').change(function(){
var sat = $("#sats option:selected").text();
$("#band2").val('SAT');
if (sat != "All") {
}
});