---
title: Filtrar esquema personalizado manual
url: "https://www.seopress.org/es/soporte/hooks/filtrar-esquema-personalizado-manual/"
lang: es
updated: 2026-10-16
hook_name: seopress_rich_snippets_custom_{$key}_html
required_version: 4.6
---

# Filtrar esquema personalizado manual

- **Hook name:** `seopress_rich_snippets_custom_{$key}_html`
- **Required version:** 4.6

```php
<?php
// $key is the index of the custom schema among the custom schemas of the post (0 = first custom schema).
add_filter( 'seopress_rich_snippets_custom_0_html', 'sp_rich_snippets_custom_html', 10, 2 );
function sp_rich_snippets_custom_html( $html, $context ) {
	// $html is the custom schema as a string (the <script type="application/ld+json"> block you entered).
	// $context is an array describing the current page, use it to apply conditions.

	// Do your stuff.

	return $html;
}
```

Source: [https://gist.github.com/wp-seopress/06bf64c0824788762e7ab5019f00f631](https://gist.github.com/wp-seopress/06bf64c0824788762e7ab5019f00f631)



