[wp-trac] [WordPress Trac] #22010: RSS Widget with hardcoded icon and style
WordPress Trac
wp-trac at lists.automattic.com
Wed Sep 26 22:13:59 UTC 2012
#22010: RSS Widget with hardcoded icon and style
-----------------------------+--------------------------
Reporter: thomask | Type: defect (bug)
Status: new | Priority: normal
Milestone: Awaiting Review | Component: Widgets
Version: | Severity: normal
Keywords: |
-----------------------------+--------------------------
Standard RSS Widget outputs hardcoded icon and oldschool inline
style="border:0" e.g.
{{{
<img style="border:0" width="14" height="14"
src="http://zdrojak.lamp.wikidi.net/wp-includes/images/rss.png" alt="RSS">
}}}
this makes it hard to style (even more that the parent anchor has the same
css class as following title, so you can't even hide it without some css3
only magic (:first)
IMO this part of WP_INC/default-widgets.php row 766-777
{{{
$icon = includes_url('images/rss.png');
if ( $title )
$title = "<a class='rsswidget' href='$url'
title='" . esc_attr__( 'Syndicate this content' ) ."'><img
style='border:0' width='14' height='14' src='$icon' alt='RSS' /></a> <a
class='rsswidget' href='$link' title='$desc'>$title</a>";
}}}
+ line 764
should be replaced by standard way e.g.
{{{
$title = apply_filters( 'widget_title', empty(
$instance['title'] ) ? __( 'RSS' ) : $instance['title'], $instance,
$this->id_base );
}}}
so when someone wants to output there an icon, he could simply with the
widget_title filter
--
Ticket URL: <http://core.trac.wordpress.org/ticket/22010>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list