简体   繁体   English

重定向到网页没有发生

[英]Redirection to the web page not happening

I have been trying to redirect the other web page from the home page in the node server. 我一直在尝试从节点服务器的主页中重定向其他网页。 Redirect is not happening to the link./idea.html where the relevant web page (HTML file)idea.html to be linked is also present. 重定向未发生在link./idea.html上,其中也存在要链接的相关网页(HTML文件)idea.html。 can you guys help me whether there is any error in the code or any special function to be added 你们可以帮助我代码中是否有错误或要添加的任何特殊功能

<!DOCTYPE html>
<html lang="en">
<head>
<div>
<a href="https://www.sports_tournament/apple.com">apple</a>
</div>
</body>
</html>

idea.html idea.html

<!DOCTYPE html>
<html lang="en">
<head>
 <title>thenewboston></title>
 <link rel="stylesheet" href="CSS/style.css" />
</head>
<body>
<link rel="Registration" href="C:/Users/web/Mongodb/home.html" />
</body>
</html>

It works when idea.html is the in same folder as that of index.html. 当idea.html与index.html所在的文件夹位于同一文件夹中时,它将起作用。 There is no need for any function as such. 不需要任何此类功能。 You should put some content in idea.html to see if that works. 您应该在idea.html中放入一些内容,以查看是否可行。

在同一页面上,为什么必须重定向我认为您必须在其中使用href =“#”

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM