# ページヘッダーの先頭にスクリプトを追加する方法

**URL:** <https://meta.discourse.org/t/how-to-add-a-script-at-the-beginning-of-page-header/211513>\
**Category:** Product Support\
**Created:** [2021 年 12 月 8 日午後 4:41 UTC](https://meta.discourse.org/t/how-to-add-a-script-at-the-beginning-of-page-header/211513 "2021-12-08T16:41:20Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![SchweizerSchoggi](https://avatars.discourse-cdn.com/v4/letter/s/c6cbf5/32.png) [@SchweizerSchoggi](https://meta.discourse.org/u/SchweizerSchoggi)\
**Post date:** [2021 年 12 月 13 日午後 2:10 UTC](https://meta.discourse.org/t/how-to-add-a-script-at-the-beginning-of-page-header/211513/3 "2021-12-13T14:10:56Z")

</div>

@cocococosti ありがとうございます。  
はい、半自動ブロック スクリプトは選択肢になり得ますが、Discourse 管理ツールのどこに配置すればよいでしょうか？

セクションに挿入しようとしました。  
カスタマイズ =\> テーマ =\> CSS/HTML の編集 =\> Body

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

しかし、その場合挿入が遅すぎます。body タグの直後に統合されるべきですが、実際には body タグが閉じる直前に挿入されています。

---

_[View the full topic](https://meta.discourse.org/t/how-to-add-a-script-at-the-beginning-of-page-header/211513)._
