diff --git a/dbd/sql/mysql/schema/system_page.sql b/dbd/sql/mysql/schema/system_page.sql index 871cd6b..5f180f5 100644 --- a/dbd/sql/mysql/schema/system_page.sql +++ b/dbd/sql/mysql/schema/system_page.sql @@ -8,4 +8,4 @@ CREATE TABLE `system_page` ( PRIMARY KEY (`id`, `div`, `group`) ) COLLATE='utf8_unicode_ci' -ENGINE=InnoDB; +ENGINE=InnoDB; \ No newline at end of file diff --git a/files/sys/system.js b/files/sys/system.js index bc195bb..aa7e965 100644 --- a/files/sys/system.js +++ b/files/sys/system.js @@ -150,9 +150,9 @@ SYSTEM.prototype.back = function(){ window.history.back();}; SYSTEM.prototype.forwad = function(){ window.history.forward();}; -SYSTEM.prototype.reload = function(){ - //window.location.reload(); - this.go_state(this.cur_state(),true); +SYSTEM.prototype.reload = function(href){ + if('#!'+this.cur_state() === href){ + this.go_state(this.cur_state(),true);} }; SYSTEM.prototype.language = function(lang){ diff --git a/sai/page/js/sai.js b/sai/page/js/sai.js index 4e784fc..ee5ff3d 100644 --- a/sai/page/js/sai.js +++ b/sai/page/js/sai.js @@ -1,11 +1,11 @@ $(document).ready(function() { - new SYSTEM('./api.php',42,'start'); + new SYSTEM('./sai.php',42,'start'); $('#sai_navbar ul li a, #project_navbar ul li a').click(function () { $('#sai_navbar li, #project_navbar li').each(function(){ $(this).removeClass('active');}); $(this).parent().addClass('active'); - system.reload(); + system.reload($(this).attr('href')); }); $('#sai_navbar li, #project_navbar li').each(function(){