一个URL的一部分,我有以下PHP变量PHP,删除变量
$currentUrl
这个PHP变量返回我当前的URL页面。例如:它返回:
http://example.com/test-category/page.html?_ore=norn&___frore=norian
我可以使用什么PHP代码将以此为URL链接,并删除“的.html”后,一切会回到我一个干净的URL链接,例如:
http://example.com/test-category/page.html
这将在一个新的变量$ clean_currentUrl返回
http://php.net/manual/en/function.parse-url.php – hjpotter92