[wp-trac] [WordPress Trac] #4666: In WP backend, the 'View site' span needs its own ID

WordPress Trac wp-trac at lists.automattic.com
Tue Jul 24 08:29:33 GMT 2007


#4666: In WP backend, the 'View site' span needs its own ID
----------------------------+-----------------------------------------------
 Reporter:  JeremyVisser    |       Owner:  anonymous  
     Type:  defect          |      Status:  new        
 Priority:  normal          |   Milestone:  2.3 (trunk)
Component:  Administration  |     Version:  2.3        
 Severity:  minor           |    Keywords:             
----------------------------+-----------------------------------------------
 In the code for each page within the WP backend, like so:

 {{{
 <h1>Jeremy Visser <span>(<a href="http://jeremy.sunriseroad.net/">View
 site &raquo;</a>)</span></h1>
 }}}

 It uses a {{{span}}} to differentiate between the blog title and 'view
 site' link, in order to make it smaller.

 However, the [http://trac.mu.wordpress.org/ticket/310 WordPress MU
 dashboard switcher] (ported from WP.com) needs to use additional
 {{{span}}}s in order to do its JavaScript magic, like so:

 {{{
 <h1><span id="blog-title">Jeremy Visser</span><span id="viewsite">(<a
 href="http://jeremy.sunriseroad.net/">View site &raquo;</a>)</span></h1>
 }}}

 As you can see, it added the {{{id}}} attribute to both the {{{span}}}s it
 added. However, the CSS is like this:

 {{{
 #wphead h1 span {
         font-size: .4em;
         letter-spacing: 0;
 }
 }}}

 Thus making the blog title and view site link small, which is ugly. So,
 you need the CSS to look like this (making it only select
 {{{#viewsite}}}):

 {{{
 #wphead h1 span#viewsite {
         font-size: .4em;
         letter-spacing: 0;
 }
 }}}

 ...and add an {{{id}}} to the {{{span}}}:

 {{{
 <h1>Jeremy Visser <span id="viewsite">(<a
 href="http://jeremy.sunriseroad.net/">View site &raquo;</a>)</span></h1>
 }}}

 Voilà.

-- 
Ticket URL: <http://trac.wordpress.org/ticket/4666>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list