# Accordions - things to look out for

## Question

We’re looking to implement accordion functionality on our website. What do we need to look out for?

## Answer

The things to watch out for are that:

* it can be operated with a keyboard — so people can tab onto it and then press enter to open and close it, and
* the titles behave like links — so that if people don’t know what an accordion is they can still click it as if it’s a link
* our accordion titles are actually headings for the content underneath them, even though they look like links.

We also used details/summary elements as this was more semantically correct.

<http://www.w3schools.com/tags/tag_summary.asp>


---

# Agent Instructions: 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:

```
GET https://govtnz.gitbook.io/nz-government-web-standards/technical-accessibility/accordions-things-to-look-out-for.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
