# 在帖子页面隐藏分享/邀请按钮

**URL:** https://meta.discourse.org/t/hide-share-invite-buttons-on-post-pages/44233
**Category:** Support
**Created:** [2016年五月14日 11:06 UTC](https://meta.discourse.org/t/hide-share-invite-buttons-on-post-pages/44233 "2016-05-14T11:06:07Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![PatrickH](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/patrickh/32/116296_2.png) [@PatrickH](https://meta.discourse.org/u/PatrickH)
#### Post date: [2016年五月14日 11:06 UTC](https://meta.discourse.org/t/hide-share-invite-buttons-on-post-pages/44233/1 "2016-05-14T11:06:07Z")

</div>

I know that it is possible to hide the buttons: like - share - flag - etc in de post menu.  
But I want also to change/hide these buttons at the bottom of these pages.

Is that possible ?

 ![](https://global.discourse-cdn.com/meta/original/3X/3/5/354d63778df30f09bb5735247cbbd41019609efc.png)

---

<div class="post-metadata">

### Author: ![fefrei](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fefrei/32/119538_2.png) [@fefrei](https://meta.discourse.org/u/fefrei)
#### Post date: [2016年五月14日 11:43 UTC](https://meta.discourse.org/t/hide-share-invite-buttons-on-post-pages/44233/2 "2016-05-14T11:43:26Z")

</div>

Sure! In Admin `->` Customize, add a CSS rule with this code:

```plaintext
#topic-footer-main-buttons .share.btn {
    display: none;
}

```

---

<div class="post-metadata">

### Author: ![PatrickH](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/patrickh/32/116296_2.png) [@PatrickH](https://meta.discourse.org/u/PatrickH)
#### Post date: [2016年五月14日 18:22 UTC](https://meta.discourse.org/t/hide-share-invite-buttons-on-post-pages/44233/3 "2016-05-14T18:22:58Z")

</div>

Great thanks!  
Last question, and how about the invite button ? I cant find the proper ccs code ?

---

<div class="post-metadata">

### Author: ![fefrei](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fefrei/32/119538_2.png) [@fefrei](https://meta.discourse.org/u/fefrei)
#### Post date: [2016年五月14日 18:34 UTC](https://meta.discourse.org/t/hide-share-invite-buttons-on-post-pages/44233/4 "2016-05-14T18:34:11Z")

</div>

That’s more tricky. Because the button has no unique class, there’s no way to hide it specifically – but the following code hides the fourth button, which just happens to be the invite button _in the current Discourse version_ 😉

```plaintext
#topic-footer-main-buttons button:nth-child(4) {
    display: none;
}

```

---

<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:45 UTC](https://meta.discourse.org/t/hide-share-invite-buttons-on-post-pages/44233/5 "2024-06-08T12:45:41Z")

</div>

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