> For the complete documentation index, see [llms.txt](https://gitbook.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://gitbook.com/docs/documentation/zh/guan-li-ni-de-zhan-dian/site-structure/site-sections.md).

# 分区

在一个已发布的站点中组织独立的产品、受众或主题。

{% hint style="info" %}
此功能适用于 Ultimate 网站方案。
{% endhint %}

<figure><img src="https://2111890564-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNkEGS7hzeqa35sMXQZ4X%2Fuploads%2FAfqBhbHbvEllbHg6s9I0%2Fsite_sections%402x.png?alt=media&amp;token=40811255-7158-49fb-9938-7ebb878b5296" alt="A GitBook screenshot showing sections on a docs site"><figcaption><p>带有分区的 GitBook 网站示例</p></figcaption></figure>

分区可让你将文档集中在一个网站中。可用它们来组织不同的产品。你也可以通过定制内容面向不同受众。

将分区分组，可在导航栏中创建一个下拉菜单。分组可为你的网站增加层级。

### 分区还是变体？

每个分区都包含自己的内容。使用分区来区分不同的文档区域。这些区域可以代表产品、受众或主题。

对于同一内容的不同版本，请使用 [内容变体](/docs/documentation/zh/guan-li-ni-de-zhan-dian/site-structure/variants.md)。变体包括本地化版本和历史产品版本。

### 添加分区

要添加分区：

1. 在网站侧边栏中，打开 **网站结构**.
2. 在表格下方，点击 **新分区**.
3. 选择要添加的内容。

该分区会显示在表格中。它也会作为一个选项卡显示在你发布的网站上。

<figure><img src="https://2111890564-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNkEGS7hzeqa35sMXQZ4X%2Fuploads%2FF2eMGMOFBOtjgd2ELMXE%2Fstructure%20tree%402x.png?alt=media&amp;token=83fe9dd0-bbfd-42a7-954c-52d895eae78a" alt="A GitBook screenshot showing site section structure"><figcaption><p>使用分区为你的文档添加结构。</p></figcaption></figure>

### 创建分区组

分区组会在一个标题下创建一个导航下拉菜单。分组后的分区可以带有可选描述。描述会显示在分区标题下方。

要创建分组：

1. 在 **新分区**旁边，点击箭头。
2. 选择 **新分区组**.
3. 输入组名称。
4. 点击 **添加分区**.
5. 添加现有分区或选择新内容。

如果你的网站支持多种语言，请翻译组标题、分区标题和描述。参见 [多语言分区](/docs/documentation/zh/guan-li-ni-de-zhan-dian/site-structure/multilingual-sections.md).

### 编辑分区

要编辑分区：

1. 在分区的表格行中，点击 **编辑**.
2. 更改名称、图标或 slug。
3. 点击 **保存**.

要删除分区，点击 **删除** 位于左下角。

{% hint style="info" %}
更改分区的 slug 会更改其规范 URL。GitBook 会从旧 URL 创建重定向。你也可以 [手动创建重定向](/docs/documentation/zh/fa-bu/site-redirects.md).
{% endhint %}

### 隐藏分区

**在网站导航中显示** 控制一个分区是否显示在你网站的顶部导航中。隐藏分区会将其从已发布的导航中移除。它不会删除该分区或其内容。

要隐藏分区：

1. 在网站侧边栏中，打开 **网站结构**.
2. 在分区的表格行中，点击 **编辑**.
3. 关闭 **在网站导航中显示**.
4. 点击 **保存**.

此设置控制分区的可见性。它不同于 **隐藏页面**，后者会将页面从分区的目录中隐藏。访客不会在已发布的网站导航中看到隐藏的分区。

### 重新排序分区

分区的顺序与 **网站结构** 表格中的顺序一致。要重新排序分区，请将其拖动把手向上或向下拖动。分区的内容会随之移动。新顺序会立即显示在你的网站上。

要使用键盘：

1. 按 **空格键** 选择一个分区。
2. 按方向键移动分区。
3. 按 **空格键** 以确认。

### 设置主页分区

访客打开你的网站时，会显示主页分区。它会加载在你网站的根 URL 上。其他分区会在根 URL 后附加一个 slug。

要设置主页分区：

1. 在分区的表格行中，打开 **操作** 菜单。
2. 点击 **设为主页**.

### 设置主页变体

如果一个分区有多个变体，请选择访客首先打开的变体。

要设置主页变体：

1. 打开 **网站设置**.
2. 点击 **结构**.
3. 点击要更新的分区。
4. 找到访客首先打开的变体。
5. 点击 **设为主页**.

### 移除分区

要移除分区：

1. 在网站侧边栏中，打开 **网站结构**.
2. 打开该分区的 **操作** 菜单。
3. 点击 **移除**.

{% hint style="success" %}
移除分区会取消发布该分区及其变体。它不会删除内容。你仍可在 [全部内容](/docs/documentation/zh/chuang-jian-nei-rong/content-structure/all-content.md).
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://gitbook.com/docs/documentation/zh/guan-li-ni-de-zhan-dian/site-structure/site-sections.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
