Switch language

wpseek.com
A WordPress-centric search engine for devs and theme authors




allowed_tags [ WordPress Function ]

allowed_tags ( No parameters )
Uses:
  • $allowedtags
Returns:
  • (string) HTML allowed tags entity encoded.
Defined at:



Display all of the allowed tags in HTML format with attributes.

This is useful for displaying in the comment area, which elements and attributes are supported. As well as any plugins which want to display it.

Source


<?php
function allowed_tags() {
    global 
$allowedtags;
    
$allowed '';
    foreach ( (array) 
$allowedtags as $tag => $attributes ) {
        
$allowed .= '<'.$tag;
        if ( 
count($attributes) ) {
            foreach ( 
$attributes as $attribute => $limits ) {
                
$allowed .= ' '.$attribute.'=""';
            }
        }
        
$allowed .= '> ';
    }
    return 
htmlentities($allowed);
}
?>

Examples [ wp-snippets.com ]

Top Google zoekresultaten

Meer ...

0 User Note(s)

Nog geen één. Wees de eerste!

Nieuw toevoegen ...



HTML5 Powered with CSS3 / Styling, Performance & Integration, and Semantics