# How to Add Inline Highlighting to Text

Inline highlighting works in the block editor or by wrapping a span around the text with a CSS class `has-inline-text`.

### Add Inline Highlighting in the Block Editor

Inline highlighting is very simple. Simply highlight some text in the block editor, and select **Inline Social Highlight** from the **More** context menu.

<figure><img src="/files/H188BZCzq6iO644TXkTQ" alt=""><figcaption><p>Select Inline Social Highlight to Highlight Text</p></figcaption></figure>

### Adding Inline Highlighting Via Code (HTML Attribute)

If you need to highlight text outside of the block editor, just wrap a `span` element around the text and give it a class of `has-inline-text`.

{% code title="Sample HTML code" overflow="wrap" %}

```html
<span class="has-inline-text">Text to Highlight</span>
```

{% endcode %}


---

# 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://docs.dlxplugins.com/highlight-and-share/inline-highlighting/how-to-add-inline-highlighting-to-text.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.
