Switch language

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




selected [ WordPress Function ]

selected ( $selected, $current = true, $echo = true )
Parameters:
  • (mixed) $selected One of the values to compare
  • (mixed) $current (true) The other value to compare if not just true
  • (bool) $echo Whether to echo or just return the string
Returns:
  • (string) html attribute or empty string
Defined at:



Outputs the html selected attribute.

Compares the first two arguments and if identical marks as selected

Source


<?php
function selected$selected$current true$echo true ) {
    return 
__checked_selected_helper$selected$current$echo'selected' );
}
?>

Examples [ wp-snippets.com ]

Google Arama Sonuçlarý

Dahasý ...

0 User Note(s)

Henüz yok. Ýlk sen ol!

Yeni Ekle ...



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