[英]Redirect from an HTML page to another page to a title
Is it possible to set up a button link to redirect to another page to a title?是否可以设置按钮链接以重定向到另一个页面的标题?
For example in menu I have page "Realised projects" and want to redirect to page "Welcome" where I have my portfolio with title "Realised projects".例如,在菜单中,我有“已实现项目”页面,并希望重定向到“欢迎”页面,其中我的作品集标题为“已实现项目”。 Is it possible to do it with script that Im using now?
是否可以使用我现在使用的脚本来做到这一点?
<script>
setTimeout(function(){location.href="http://example.com/alternate_url.html"} , 0);
</script>
I need something like this but for redirect after load the page: <a href="http://example.com/alternate_url.html" title="test">test</a>
我需要这样的东西,但在加载页面后重定向:
<a href="http://example.com/alternate_url.html" title="test">test</a>
The question is little bit tricky.这个问题有点棘手。 But I am using website builder that is shitty af and wont lt me edit the button code, and let me edit only html body script:)
但我使用的是糟糕的网站构建器,不会让我编辑按钮代码,让我只编辑 html 正文脚本:)
This worked:)这有效:)
<script>
setTimeout(function(){location.href="http://example.com/alternate_url.html",title="test"} , 0);
</script>
<h2 id="test">Title</h2>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.