Changeset 11109 for trunk/wp-includes/default-widgets.php
- Timestamp:
- 04/28/2009 05:58:45 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/default-widgets.php
r11094 r11109 61 61 //Defaults 62 62 $instance = wp_parse_args( (array) $instance, array( 'sortby' => 'post_title', 'title' => '', 'exclude' => '') ); 63 $title = attr ibute_escape( $instance['title'] );64 $exclude = attr ibute_escape( $instance['exclude'] );63 $title = attr( $instance['title'] ); 64 $exclude = attr( $instance['exclude'] ); 65 65 ?> 66 66 <p><label for="<?php echo $this->get_field_id('title'); ?>"><?php _e('Title:'); ?> <input class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" value="<?php echo $title; ?>" /></label></p> … … 211 211 if ( $d ) { 212 212 ?> 213 <select name="archive-dropdown" onchange='document.location.href=this.options[this.selectedIndex].value;'> <option value=""><?php echo attr ibute_escape(__('Select Month')); ?></option> <?php wp_get_archives("type=monthly&format=option&show_post_count=$c"); ?> </select>213 <select name="archive-dropdown" onchange='document.location.href=this.options[this.selectedIndex].value;'> <option value=""><?php echo attr(__('Select Month')); ?></option> <?php wp_get_archives("type=monthly&format=option&show_post_count=$c"); ?> </select> 214 214 <?php 215 215 } else { … … 240 240 $dropdown = $instance['dropdown'] ? 'checked="checked"' : ''; 241 241 ?> 242 <p><label for="<?php echo $this->get_field_id('title'); ?>"><?php _e('Title:'); ?> <input class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" value="<?php echo attr ibute_escape($title); ?>" /></label></p>242 <p><label for="<?php echo $this->get_field_id('title'); ?>"><?php _e('Title:'); ?> <input class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" value="<?php echo attr($title); ?>" /></label></p> 243 243 <p> 244 244 <label for="<?php echo $this->get_field_id('count'); ?>"><input class="checkbox" type="checkbox" <?php echo $count; ?> id="<?php echo $this->get_field_id('count'); ?>" name="<?php echo $this->get_field_name('count'); ?>" /> <?php _e('Show post counts'); ?></label> … … 274 274 <?php wp_register(); ?> 275 275 <li><?php wp_loginout(); ?></li> 276 <li><a href="<?php bloginfo('rss2_url'); ?>" title="<?php echo attr ibute_escape(__('Syndicate this site using RSS 2.0')); ?>"><?php _e('Entries <abbr title="Really Simple Syndication">RSS</abbr>'); ?></a></li>277 <li><a href="<?php bloginfo('comments_rss2_url'); ?>" title="<?php echo attr ibute_escape(__('The latest comments to all posts in RSS')); ?>"><?php _e('Comments <abbr title="Really Simple Syndication">RSS</abbr>'); ?></a></li>278 <li><a href="http://wordpress.org/" title="<?php echo attr ibute_escape(__('Powered by WordPress, state-of-the-art semantic personal publishing platform.')); ?>">WordPress.org</a></li>276 <li><a href="<?php bloginfo('rss2_url'); ?>" title="<?php echo attr(__('Syndicate this site using RSS 2.0')); ?>"><?php _e('Entries <abbr title="Really Simple Syndication">RSS</abbr>'); ?></a></li> 277 <li><a href="<?php bloginfo('comments_rss2_url'); ?>" title="<?php echo attr(__('The latest comments to all posts in RSS')); ?>"><?php _e('Comments <abbr title="Really Simple Syndication">RSS</abbr>'); ?></a></li> 278 <li><a href="http://wordpress.org/" title="<?php echo attr(__('Powered by WordPress, state-of-the-art semantic personal publishing platform.')); ?>">WordPress.org</a></li> 279 279 <?php wp_meta(); ?> 280 280 </ul> … … 294 294 $title = strip_tags($instance['title']); 295 295 ?> 296 <p><label for="<?php echo $this->get_field_id('title'); ?>"><?php _e('Title:'); ?> <input class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" value="<?php echo attr ibute_escape($title); ?>" /></label></p>296 <p><label for="<?php echo $this->get_field_id('title'); ?>"><?php _e('Title:'); ?> <input class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" value="<?php echo attr($title); ?>" /></label></p> 297 297 <?php 298 298 } … … 334 334 <p><label for="<?php echo $this->get_field_id('title'); ?>"> 335 335 <?php _e('Title:'); ?> 336 <input class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" value="<?php echo attr ibute_escape($title); ?>" />336 <input class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" value="<?php echo attr($title); ?>" /> 337 337 </label></p> 338 338 <?php … … 382 382 <p><label for="<?php echo $this->get_field_id('title'); ?>"> 383 383 <?php _e('Title:'); ?> 384 <input class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" value="<?php echo attr ibute_escape($title); ?>" />384 <input class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" value="<?php echo attr($title); ?>" /> 385 385 </label></p> 386 386 … … 464 464 //Defaults 465 465 $instance = wp_parse_args( (array) $instance, array( 'title' => '') ); 466 $title = attr ibute_escape( $instance['title'] );466 $title = attr( $instance['title'] ); 467 467 $count = (bool) $instance['count']; 468 468 $hierarchical = (bool) $instance['hierarchical']; … … 567 567 568 568 function form( $instance ) { 569 $title = attr ibute_escape($instance['title']);569 $title = attr($instance['title']); 570 570 if ( !$number = (int) $instance['number'] ) 571 571 $number = 5; … … 654 654 655 655 function form( $instance ) { 656 $title = attr ibute_escape($instance['title']);656 $title = attr($instance['title']); 657 657 if ( !$number = (int) $instance['number'] ) 658 658 $number = 5; … … 703 703 704 704 if ( ! is_wp_error($rss) ) { 705 $desc = attr ibute_escape(strip_tags(@html_entity_decode($rss->get_description(), ENT_QUOTES, get_option('blog_charset'))));705 $desc = attr(strip_tags(@html_entity_decode($rss->get_description(), ENT_QUOTES, get_option('blog_charset')))); 706 706 if ( empty($title) ) 707 707 $title = htmlentities(strip_tags($rss->get_title())); … … 717 717 $url = clean_url(strip_tags($url)); 718 718 $icon = includes_url('images/rss.png'); 719 $title = "<a class='rsswidget' href='$url' title='" . attr ibute_escape(__('Syndicate this content')) ."'><img style='background:orange;color:white;border:none;' width='14' height='14' src='$icon' alt='RSS' /></a> <a class='rsswidget' href='$link' title='$desc'>$title</a>";719 $title = "<a class='rsswidget' href='$url' title='" . attr(__('Syndicate this content')) ."'><img style='background:orange;color:white;border:none;' width='14' height='14' src='$icon' alt='RSS' /></a> <a class='rsswidget' href='$link' title='$desc'>$title</a>"; 720 720 721 721 echo $before_widget; … … 788 788 $link = substr($link, 1); 789 789 $link = clean_url(strip_tags($link)); 790 $title = attr ibute_escape(strip_tags($item->get_title()));790 $title = attr(strip_tags($item->get_title())); 791 791 if ( empty($title) ) 792 792 $title = __('Untitled'); 793 793 794 $desc = str_replace(array("\n", "\r"), ' ', attr ibute_escape(strip_tags(@html_entity_decode($item->get_description(), ENT_QUOTES, get_option('blog_charset')))));794 $desc = str_replace(array("\n", "\r"), ' ', attr(strip_tags(@html_entity_decode($item->get_description(), ENT_QUOTES, get_option('blog_charset'))))); 795 795 $desc = wp_html_excerpt( $desc, 360 ) . ' […]'; 796 796 $desc = wp_specialchars( $desc ); … … 851 851 extract( $inputs, EXTR_SKIP); 852 852 853 $number = attr ibute_escape( $number );854 $title = attr ibute_escape( $title );855 $url = attr ibute_escape( $url );853 $number = attr( $number ); 854 $title = attr( $title ); 855 $url = attr( $url ); 856 856 $items = (int) $items; 857 857 if ( $items < 1 || 20 < $items ) … … 985 985 <p><label for="<?php echo $this->get_field_id('title'); ?>"> 986 986 <?php _e('Title:') ?> 987 <input type="text" class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" value="<?php echo attr ibute_escape( $instance['title'] ); ?>" />987 <input type="text" class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" value="<?php echo attr( $instance['title'] ); ?>" /> 988 988 </label></p> 989 989 <?php
Note: See TracChangeset
for help on using the changeset viewer.