Url rewriting netbeans插件?重写url
目前,我在glassfish服务器上运行的netbean项目显示Url rewriting netbeans插件?重写url,url-rewriting,netbeans-plugins,Url Rewriting,Netbeans Plugins,目前,我在glassfish服务器上运行的netbean项目显示http://localhost:8080/projectname/index.html 我需要将此更改为http://localhost:8080/homepage 如何在标题栏中更改此url 或者是生成需要通过在WEB-INF等中放置.htpasswd来加密的.htaccess文件的唯一方法,或者可能有一个插件 让我知道,提前谢谢 Dave我通过在HTML5history.pushstate(null,“title”,newUR
http://localhost:8080/projectname/index.html
我需要将此更改为http://localhost:8080/homepage
如何在标题栏中更改此url
或者是生成需要通过在WEB-INF等中放置.htpasswd来加密的.htaccess文件的唯一方法,或者可能有一个插件
让我知道,提前谢谢
Dave我通过在HTML5
history.pushstate(null,“title”,newURL)中使用解决了这个问题。
这仅重命名了index.html index-1等。因此,在netbeans中,如果右键单击项目-->转到属性-->并转到运行…您可以更改上下文路径并删除项目文件夹,从而获得http://localhost:8080/homepage
非http://localhost:8080/project/homepage.
为了遵循这一点,我需要一些谷歌没有提供的进一步建议。我想重定向到页面中的锚定标记,如href=“/index6.html#content”
。但是使用history.pushstate()意味着锚定标记将被忽略,并将始终将页面指向pushstate值。这是怎么回事
致意
大卫