esc_attr_e( string $text, string $domain = 'default' )
Displays translated text that has been escaped for safe use in an attribute.
Description
Encodes < > & " '
(less than, greater than, ampersand, double quote, single quote).
Will never double encode entities.
If you need the value for use in PHP, use esc_attr__() .
Parameters
-
$text
string Required -
Text to translate.
-
$domain
string Optional -
Text domain. Unique identifier for retrieving translated strings.
Default'default'
.Default:
'default'
Source
File: wp-includes/l10n.php
.
View all references
function esc_attr_e( $text, $domain = 'default' ) {
echo esc_attr( translate( $text, $domain ) );
}
Related
Uses
Uses | Description |
---|---|
translate() wp-includes/l10n.php |
Retrieves the translation of $text. |
esc_attr() wp-includes/formatting.php |
Escaping for HTML attributes. |
Used By
Used By | Description |
---|---|
WP_Customize_Themes_Panel::render_template() wp-includes/customize/class-wp-customize-themes-panel.php |
An Underscore (JS) template for rendering this panel’s container. |
WP_Customize_Themes_Section::render_template() wp-includes/customize/class-wp-customize-themes-section.php |
Render a themes section as a JS template. |
WP_Customize_Themes_Section::filter_bar_content_template() wp-includes/customize/class-wp-customize-themes-section.php |
Render the filter bar portion of a themes section as a JS template. |
wp_print_community_events_markup() wp-admin/includes/dashboard.php |
Prints the markup for the Community Events section of the Events and News Dashboard widget. |
WP_Customize_Nav_Menus::print_custom_links_available_menu_item() wp-includes/class-wp-customize-nav-menus.php |
Prints the markup for available menu item custom links. |
WP_Plugins_List_Table::search_box() wp-admin/includes/class-wp-plugins-list-table.php |
Displays the search box. |
WP_Customize_Site_Icon_Control::content_template() wp-includes/customize/class-wp-customize-site-icon-control.php |
Renders a JS template for the content of the site icon control. |
print_embed_sharing_button() wp-includes/embed.php |
Prints the necessary markup for the embed sharing button. |
print_embed_sharing_dialog() wp-includes/embed.php |
Prints the necessary markup for the embed sharing dialog. |
WP_Customize_Nav_Menu_Location_Control::render_content() wp-includes/customize/class-wp-customize-nav-menu-location-control.php |
Render content just like a normal select control. |
WP_Customize_Nav_Menu_Control::content_template() wp-includes/customize/class-wp-customize-nav-menu-control.php |
JS/Underscore template for the control UI. |
WP_Customize_Nav_Menus::available_items_template() wp-includes/class-wp-customize-nav-menus.php |
Prints the HTML template used to render the add-menu-item frame. |
WP_Customize_Manager::render_control_templates() wp-includes/class-wp-customize-manager.php |
Renders JS templates for all registered control types. |
wp_print_revision_templates() wp-admin/includes/revision.php |
Print JavaScript templates required for the revisions experience. |
WP_Media_List_Table::views() wp-admin/includes/class-wp-media-list-table.php |
Overrides parent views to use the filter bar display. |
login_footer() wp-login.php |
Outputs the footer for the login page. |
signup_another_blog() wp-signup.php |
Shows a form for returning users to sign up for another site. |
signup_user() wp-signup.php |
Shows a form for a visitor to sign up for a new user account. |
signup_blog() wp-signup.php |
Shows a form for a user or visitor to sign up for a new site. |
display_setup_form() wp-admin/install.php |
Displays installer setup form. |
WP_Screen::render_screen_meta() wp-admin/includes/class-wp-screen.php |
Renders the screen’s help section. |
wp_image_editor() wp-admin/includes/image-edit.php |
Loads the WP image-editing interface. |
WP_Theme_Install_List_Table::theme_installer() wp-admin/includes/class-wp-theme-install-list-table.php |
Prints the wrapper for the theme installer. |
install_search_form() wp-admin/includes/plugin-install.php |
Displays a search form for searching plugins. |
install_plugins_favorites_form() wp-admin/includes/plugin-install.php |
Shows a username form for the favorites page. |
wp_dashboard_quick_press() wp-admin/includes/dashboard.php |
Displays the Quick Draft widget. |
find_posts_div() wp-admin/includes/template.php |
Outputs the modal window used for attaching media to posts or pages in the media-listing screen. |
media_upload_gallery_form() wp-admin/includes/media.php |
Adds gallery form to upload iframe. |
media_upload_form() wp-admin/includes/media.php |
Outputs the legacy media upload form. |
link_submit_meta_box() wp-admin/includes/meta-boxes.php |
Displays link create form fields. |
link_categories_meta_box() wp-admin/includes/meta-boxes.php |
Displays link categories form fields. |
post_submit_meta_box() wp-admin/includes/meta-boxes.php |
Displays post submit form fields. |
attachment_submit_meta_box() wp-admin/includes/meta-boxes.php |
Displays attachment submit form fields. |
post_tags_meta_box() wp-admin/includes/meta-boxes.php |
Displays post tags form fields. |
wp_nav_menu_item_link_meta_box() wp-admin/includes/nav-menu.php |
Displays a meta box for the custom links menu item. |
wp_nav_menu_item_post_type_meta_box() wp-admin/includes/nav-menu.php |
Displays a meta box for a post type menu item. |
wp_nav_menu_item_taxonomy_meta_box() wp-admin/includes/nav-menu.php |
Displays a meta box for a taxonomy menu item. |
request_filesystem_credentials() wp-admin/includes/file.php |
Displays a form to the user to request for their FTP/SSH details in order to connect to the filesystem. |
Custom_Image_Header::step_1() wp-admin/includes/class-custom-image-header.php |
Displays first step of custom header image page. |
list_plugin_updates() wp-admin/update-core.php |
Display the upgrade plugins form. |
list_theme_updates() wp-admin/update-core.php |
Display the upgrade themes form. |
list_translation_updates() wp-admin/update-core.php |
Display the update translations form. |
Custom_Background::admin_page() wp-admin/includes/class-custom-background.php |
Displays the custom background page. |
WP_Admin_Bar::_render() wp-includes/class-wp-admin-bar.php | |
WP_Customize_Header_Image_Control::render_content() wp-includes/customize/class-wp-customize-header-image-control.php | |
WP_Widget_Area_Customize_Control::render_content() wp-includes/customize/class-wp-widget-area-customize-control.php |
Renders the control’s content. |
WP_Customize_Control::render_content() wp-includes/class-wp-customize-control.php |
Render the control’s content. |
WP_Customize_Widgets::output_widget_control_templates() wp-includes/class-wp-customize-widgets.php |
Renders the widget form control templates into the DOM. |
_WP_Editors::wp_link_dialog() wp-includes/class-wp-editor.php |
Dialog for internal linking. |
wp_print_media_templates() wp-includes/media-template.php |
Prints the templates used in the media manager. |
Changelog
Version | Description |
---|---|
2.8.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.
the esc_attr_e function it echoing the value for example: