在我的网站上使用Html Anchor [英] Using Html Anchor on my web site

查看:142
本文介绍了在我的网站上使用Html Anchor的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用weebly站点构建器,因此只是Html代码的初学者。我有问题让锚点在我的页面上工作。他们似乎在某些系统上工作,而不是其他人,所以我认为必须有更好的方法。



这是我在做的事情



我有一个客人作者页面,我希望每个客人直接链接到他的网页部分。



我设置了一个锚点如下

然后用下面的链接给它
http://arthurvaso.weebly.com/guests2016.html/#smith2



在某些计算机/连接器上,这很好,但在其他计算机上,它只是转到页面顶部而不是我想要的部分。



我基本上有我想直接链接到的页面



诗歌1
诗人2
诗人3等



我在这里搜索,所有的帖子要么是几岁,要么不是我正在寻找的答案。看起来浏览器版本越新,我的方法就越少。

我非常感谢任何帮助,谢谢!

解决方案

它有一个小技巧,但它对你来说很简单。你的Anchor中缺少& nbsp;



更改:

 < a id =smith2> ;< / A> 



收件人:

 < a id =smith2>& nbsp;< / a> 

确保发布变更。



请注意,您的锚链应该是:

http:// arthurvaso.weebly.com/guests2016.html#smith2
不带/之后的.html


I am using weebly site builder and so just a beginner on Html coding. I am having issues making anchors work on my pages. They seem to work on some systems and not others, and so I think there must be a better method.

Here is what I am doing

I have a guest author page and I want each guest, to have a direct link to his section of the web page

I set up an anchor as follows

Then use the following link to it http://arthurvaso.weebly.com/guests2016.html/#smith2

On some computers/broswers this works just fine, in others, it just goes to the Top of the page instead of the section I want.

I basically have pages I want to make direct links to

Poet1 Poet2 Poet3 etc

I search here, an all the posts were either years old, or not exactly the answer I was looking for. It seems the newer the browser version, the less my method works.

I really appreciate any help, thanks!

解决方案

There is a little trick to it, but it's an easy fix for you. You are missing &nbsp; in your Anchor.

Change:

<a id="smith2"></a>


To:

<a id="smith2">&nbsp;</a>

Make sure to publish the changes.

And, note that your Anchor Link should be:
http://arthurvaso.weebly.com/guests2016.html#smith2 without the / after .html

这篇关于在我的网站上使用Html Anchor的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆