pll_esc_attr__

Translates a string ( previously registered with pll_register_string ) and escapes it for safe use in HTML attributes.

Description

(string) pll_esc_attr__( $string ); 

Returns (string)

Parameters (1)

0. $string
The string.

Usage

  1. if ( !function_exists( 'pll_esc_attr__' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'polylang/include/api.php'; 
  3.  
  4. // The string. 
  5. $string = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = pll_esc_attr__($string); 
  9.  

Defined (1)

The function is defined in the following location(s).

/include/api.php  
  1. function pll_esc_attr__( $string ) { 
  2. return esc_attr( pll__( $string ) );