Table of Contents | World Anvil Codex

Table of Contents

Restructuring the Codex

We are currently moving articles around and changing the general structure of the Codex. Please come back later if you get lost!
A Table of Contents (ToC) is an organized list that displays all items in a hierarchical list below a specific resource. There are three different types of TOCs on World Anvil. They can be added using BBCode. This means that they can be added anywhere where BBCode can be used.

Table of Contents: World

The table of contents of the entire world can be added with the BBCode [toc]. It is display on the world homepage and in the global navigation sidebar. This BBCode works anywhere within a world to display the contents as an interactive tree view. The example to the right is the table of contents of this world. The World Codex heading is always added and can only be hidden with CSS.

Table of Contents: Category

This feature is available to Master, Grandmaster and Sage guild members.
The table of contents for a particular category shows the tree view of all categories and articles added under that category. This table of contents does not have its own heading.   In the sidebar is an example of how the ToC looks under the Navigation heading. This is added in addition to the category TOC BBCode. Below is an example of the BBCode with the horizontal option. It looks like this [toc:6fba5523-5ebd-49c8-b659-81e3d7352f6a|horizontal].    

Table of Contents: Article

The article table of contents [articletoc] creates a table of contents for the article it is in. It is created based on all headers within the article vignette field. This can sometimes cause the list to contain unexpected headings from embedded articles. The article table of contents added to this article at the top of the sidebar contains all the categories from the horizontal category table of contents because that element uses headings for the text.   There are no configurations to change this behavior or to limit the size of the headings that the list picks up. It is possible to customize the output with CSS.


Please Login in order to comment!
Feb 16, 2021 09:52 by Nightly Seawave

I used

but there is a certain minor problem that I don't really like - I used the prompts bellow the main space to fill out the article and when I made the toc it worked fine, but when it sends you to the particular header you clicked, it shows what's beneath the header but not the header itself and it kinda ruins the presentation. It's nothing big but a "how to fix it" if it's fixable would be really appreciated, thanks!

Feb 18, 2021 11:52

This seems to be a bug, good catch! Can you report it using the "report a bug" button you'll find in the help page? You'll need a separate account for that because the bug tracker is a third-party service. Make sure to specify that the issue is with pre-defined field headers.   Thank you!

[they/them] Creator of Black Light, a science-fantasy universe.
Feb 20, 2021 10:39 by Nightly Seawave

Oh, cool, thank you. I've already reported bugs so I have an account.

Jun 23, 2022 20:06

Is there any way to have a ToC unfold automatically when shown?

Jun 24, 2022 08:43

Hi! If you mean having categories show their contents when loading, that currently not a feature we have. You can however request it in our community features voting board:

[they/them] Creator of Black Light, a science-fantasy universe.
Oct 8, 2022 04:36 by Josh S

Where can I find a guide on how to edit a manuscripts table of contents?

The voice of the Potestatem Temple, Zurchonic of Washington.
Oct 10, 2022 07:56

The table of contents of a Manuscript is automatically generated based on the chapters you have in the Manuscript. So to edit it, just edit the chapters!

[they/them] Creator of Black Light, a science-fantasy universe.
Oct 11, 2022 07:40 by Josh S

I have published the folders that contain each chapter but they are not appearing the table of contents as of right now. Do you know how I could get them too appear?

The voice of the Potestatem Temple, Zurchonic of Washington.
Oct 11, 2022 08:25

If everything is published and public but still not appearing, this could be a bug. You can report bugs in our bug tracker.

[they/them] Creator of Black Light, a science-fantasy universe.
Mar 2, 2023 17:09

Ok, but do I determine what's SHOWN in the table of contents? The world codex on the main page of my world seems to just show about 80% whatever pages I was most recently working on and 20% random pages, categories, etc. Sometimes it showcases pages that don't exist or are completely empty. Is there any way to dictate what is show and what isn't?   As a follow up, I'm not sure if this is the proper place, but this is an issue I've struggled with on several parts of this site. The lists only show so many items, articles, etc, typically the most recent. I have not found a way to just view a complete alphabetical list of all my articles, for example. It's very frustrating, especially because, as stated above, I don't know how to control what's displayed to other people.

Mar 3, 2023 08:53

Hi!   The world table of contents shows all content in your world that is published. This includes all categories and all articles that are not set as Drafts. Note that, since you're a Guild member, you can set articles as Published but keep them as Private so that only you can see them.   You can't see all articles in your world on the Articles manager (this used to cause loading problems for large worlds). I recommend organizing all your articles in Categories for easier organization and navigation. To see which articles aren't in a category, go to List -> Uncategorized articles.   Finally, to control what's displayed to other people, the basics are the Public/Private states that all content on your world has. You can also take a look at the Guide to Subscribers for more information if you want to give access to specific users.

[they/them] Creator of Black Light, a science-fantasy universe.
Nov 4, 2023 16:12

Hi everyone,   So i've set a table of content on every page of my world which works perfecly fine. however, I do not like that it's called "World Codex" is there a way to rename it?

Nov 6, 2023 06:16

The header generated by the [toc] tag can't be edited, but there is a workaround if you're willing to use CSS! The following CSS snippet will remove the "World Codex" header from all ToC except for the one in the homepage:

.user-css .world-toc-header {
  display: none;
} .world-toc-header {
  display: block;
  To use it, just go to the world's style settings (the art palette button at the bottom of the sidebar) and paste it into the CSS tab.   Then, simply add a header manually to all ToCs with any text you want! You could even turn this into a variable so you don't have to manually type the header every time.   Hope this helps, and let me know if you have any other questions!

[they/them] Creator of Black Light, a science-fantasy universe.