diff --git a/frontend/views/category/view.php b/frontend/views/category/view.php index 36f29ee..46efa2c 100755 --- a/frontend/views/category/view.php +++ b/frontend/views/category/view.php @@ -164,11 +164,6 @@ _________________________________________________________ --> - -
-

-
- +
+

+
diff --git a/frontend/web/js/script.js b/frontend/web/js/script.js index fe37cfb..e91ea18 100755 --- a/frontend/web/js/script.js +++ b/frontend/web/js/script.js @@ -347,17 +347,22 @@ $(function() { .val(); console.log(max, min); var href = window.location.href; + var question = href.indexOf('?'); + if (question !== -1) { + var queryString = href.substr(question); + href = href.substr(0, question); + } var count = 0; var pos = -1; while ((pos = href.indexOf('/', pos + 1)) !== -1) { count++; } if (count === 5) { - window.location.href = href + '/price-' + min + '-' + max; + window.location.href = href + '/price-' + min + '-' + max + queryString; } else { - var result = window.location.href.match(/\/[^\/]*price-(\d+)-(\d+)$/); + var result = href.match(/\/[^\/]*price-(\d+)-(\d+)$/); if (result) { - window.location.href = window.location.href.replace(/(\/[^\/]*)price-\d+-\d+$/, '$1price-' + min + '-' + max); + window.location.href = href.replace(/(\/[^\/]*)price-\d+-\d+$/, '$1price-' + min + '-' + max) + queryString; } } }); -- libgit2 0.21.4