Title: endElement
Published: April 25, 2014
Last modified: May 20, 2026

---

# endElement( resource $parser, string $tag_name )

## In this article

 * [Description](https://developer.wordpress.org/reference/functions/endElement/?output_format=md#description)
 * [Parameters](https://developer.wordpress.org/reference/functions/endElement/?output_format=md#parameters)
 * [Source](https://developer.wordpress.org/reference/functions/endElement/?output_format=md#source)
 * [Changelog](https://developer.wordpress.org/reference/functions/endElement/?output_format=md#changelog)

[ Back to top](https://developer.wordpress.org/reference/functions/endElement/?output_format=md#wp--skip-link--target)

This function’s access is marked private. This means it is not intended for use 
by plugin or theme developers, only by core. It is listed here for completeness.

Ends a new XML tag.

## 󠀁[Description](https://developer.wordpress.org/reference/functions/endElement/?output_format=md#description)󠁿

Callback function for xml_set_element_handler().

## 󠀁[Parameters](https://developer.wordpress.org/reference/functions/endElement/?output_format=md#parameters)󠁿

 `$parser`resourcerequired

XML Parser resource.

`$tag_name`stringrequired

XML tag name.

## 󠀁[Source](https://developer.wordpress.org/reference/functions/endElement/?output_format=md#source)󠁿

    ```php
    function endElement( $parser, $tag_name ) { // phpcs:ignore WordPress.NamingConventions.ValidFunctionName.FunctionNameInvalid
    	// Nothing to do.
    }
    ```

[View all references](https://developer.wordpress.org/reference/files/wp-admin/link-parse-opml.php/)
[View on Trac](https://core.trac.wordpress.org/browser/tags/7.0/src/wp-admin/link-parse-opml.php#L75)
[View on GitHub](https://github.com/WordPress/wordpress-develop/blob/7.0/src/wp-admin/link-parse-opml.php#L75-L77)

## 󠀁[Changelog](https://developer.wordpress.org/reference/functions/endElement/?output_format=md#changelog)󠁿

| Version | Description | 
| [0.71](https://developer.wordpress.org/reference/since/0.71/) | Introduced. |

## User Contributed Notes

You must [log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fdeveloper.wordpress.org%2Freference%2Ffunctions%2Fendelement%2F)
before being able to contribute a note or feedback.