如何在html中的同一页面上创建指向各部分的链接(但不同的选项卡)
正如问题所述,我想在我的页面中制作超文本,其中包含4个选项卡(编织为HTML)。 我知道这种方法在没有不同选项卡的同一页面中很好地工作,但它与我不合适。
使用#id选择器 < p id =“打开”>超链接使用Web浏览器从一个页面移动到另一页...</p>
创建指向选择器的链接 < a href =“#打开”>带我去开头段落。</a>
您能帮我吗?
例如,在“家庭”选项卡中,我想要一个超文本,将用户引导到“关于我们”选项卡中的特定部分,
谢谢
,我正在使用html和r markdown使用html来编织文件。
As the question says I want to make hypertext in my page which contains 4 tabs (R Markdown file knitted as HTML).
I know this method works well within the same page that doesn't have different tabs but it didn't work with me.
Using the #id selector<p id="opening">Hyperlinks are utilized by a web browser to move from one page to another...</p>
Creating a link to the selector<a href="#opening">Take me to the opening paragraph.</a>
Can you please help me with that?
For example in the "home" tab I want a hypertext that directs the user to a specific section in "about us" tab
Thanks in advance
Btw, I am using HTML with R Markdown to knit the file.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这是您可以做的。您可以为
容器
分配一个宽度和高度,然后溢出:自动。每个儿童
必须具有与container
相同的高度和相同的宽度,因此,如果您有几个孩子,这将溢出。超链接
或选项卡
在单击时会做什么,它滚动以查看上述儿童
。This is something that you can do. You can assign a width and height for your
container
, then overflow: auto. Eachchildren
has to have the same height and same width as thecontainer
, therefore, if you have several children, this will overflow.What the
hyperlink
ortab
does when you click, it scroll to view on the saidchildren
.