Line 12: | Line 12: | ||
<script> | <script> | ||
var page = decodeURIComponent((new RegExp('[?|&]([^&;]+?)(&|#|;|$)').exec(location.search) || [null, ''])[1].replace(/\+/g, '%20')) || "Page-1"; | var page = decodeURIComponent((new RegExp('[?|&]([^&;]+?)(&|#|;|$)').exec(location.search) || [null, ''])[1].replace(/\+/g, '%20')) || "Page-1"; | ||
+ | console.log(page); | ||
window.history.replaceState(null, null, page.replace(/\*/g, "/") + ".html"); | window.history.replaceState(null, null, page.replace(/\*/g, "/") + ".html"); | ||
Revision as of 02:15, 23 October 2017