# 在 vdom 升级后添加头部链接

**URL:** https://meta.discourse.org/t/adding-header-links-post-vdom-upgrade/43284
**Category:** Support
**Created:** [2016年四月26日 23:44 UTC](https://meta.discourse.org/t/adding-header-links-post-vdom-upgrade/43284 "2016-04-26T23:44:31Z")
**Posts on this page:** 7
**Page:** 2

<div class="post-metadata">

### Author: ![Yuun](https://avatars.discourse-cdn.com/v4/letter/y/977dab/32.png) [@Yuun](https://meta.discourse.org/u/Yuun)
#### Post date: [2017年五月25日 21:37 UTC](https://meta.discourse.org/t/adding-header-links-post-vdom-upgrade/43284/21 "2017-05-25T21:37:01Z")

</div>

What did you try? The second chunk of code in the OP still should work just fine.

---

<div class="post-metadata">

### Author: ![MikesCafe](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mikescafe/32/188727_2.png) [@MikesCafe](https://meta.discourse.org/u/MikesCafe)
#### Post date: [2017年五月26日 18:58 UTC](https://meta.discourse.org/t/adding-header-links-post-vdom-upgrade/43284/22 "2017-05-26T18:58:29Z")

</div>

The scipt form @Ben worked for me, was just looking in the wrong place…  
Any chance the older code for adding the “[+ new topic](https://meta.discourse.org/t/adding-new-topic-button-on-every-page/38922)” button next to the search icon can be combined with the code? I really would appriciate it!

---

<div class="post-metadata">

### Author: ![jlippiner](https://avatars.discourse-cdn.com/v4/letter/j/cab0a1/32.png) [@jlippiner](https://meta.discourse.org/u/jlippiner)
#### Post date: [2017年六月11日 13:56 UTC](https://meta.discourse.org/t/adding-header-links-post-vdom-upgrade/43284/23 "2017-06-11T13:56:18Z")

</div>

> [@BenRoe](#):
>
> .d-header .title {  
> display: flex;  
> align-items: center;  
> justify-content: center;  
> margin-top: 0;  
> }
> 
> #header-links {  
> max-width: 50%;  
> font-size: 1.2rem;  
> margin-left: 30px;  
> margin-top: 4px;  
> }

This is great! But @codinghorror don’t you think the ability to edit / add links to the header area like this should be part of the theme customize? When I edit the “header” I kind of expected to be editing this area, but I was really editing the “before header” area. Just a thought.

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [2017年六月11日 19:54 UTC](https://meta.discourse.org/t/adding-header-links-post-vdom-upgrade/43284/24 "2017-06-11T19:54:58Z")

</div>

We wanted to add it to the setup wizard but ran out of time.

---

<div class="post-metadata">

### Author: ![jlippiner](https://avatars.discourse-cdn.com/v4/letter/j/cab0a1/32.png) [@jlippiner](https://meta.discourse.org/u/jlippiner)
#### Post date: [2017年六月11日 19:57 UTC](https://meta.discourse.org/t/adding-header-links-post-vdom-upgrade/43284/25 "2017-06-11T19:57:45Z")

</div>

I would recommend adding it to the customize section for themes.

---

<div class="post-metadata">

### Author: ![spacle2xl](https://avatars.discourse-cdn.com/v4/letter/s/48db29/32.png) [@spacle2xl](https://meta.discourse.org/u/spacle2xl)
#### Post date: [2017年十月16日 08:11 UTC](https://meta.discourse.org/t/adding-header-links-post-vdom-upgrade/43284/26 "2017-10-16T08:11:11Z")

</div>

Ive tried various options to add +New Topic Button to the header or at lease every page but it isn’t working… Please any work around on this?

---

<div class="post-metadata">

### Author: ![JammyDodger](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jammydodger/32/254611_2.png) [@JammyDodger](https://meta.discourse.org/u/JammyDodger)
#### Post date: [2024年六月8日 12:44 UTC](https://meta.discourse.org/t/adding-header-links-post-vdom-upgrade/43284/27 "2024-06-08T12:44:05Z")

</div>

该主题已在 2964 天后自动关闭。不再允许回复。

[上一頁](https://meta.discourse.org/t/adding-header-links-post-vdom-upgrade/43284.md?page=1)
