WordPress.org

Making WordPress.org

Changeset 1188


Ignore:
Timestamp:
01/24/2015 01:34:53 PM (6 years ago)
Author:
obenland
Message:

WP.org Themes: Account for subfolder installs in tag links.

See #745.

Location:
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-themes
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-themes/content-single.php

    r1156 r1188  
    157157                <?php
    158158                    foreach( $theme->tags as &$tag ) :
    159                         $tag = sprintf( '<a href="/tag/%1$s/">%1$s</a>', $tag );
     159                        $tag = sprintf( '<a href="%1$s">%2$s</a>', esc_url( home_url( "/tag/{$tag}/" ) ), $tag );
    160160                    endforeach;
    161161                    echo implode( ', ', $theme->tags );
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-themes/js/theme.js

    r1155 r1188  
    4343            // Make tags clickable and seprated by a comma.
    4444            data.tags = _.map( data.tags, function( tag ) {
    45                 return '<a href="/tag/'+tag+'/">'+tag+'</a>';
     45                return '<a href="'+wp.themes.data.settings.adminUrl+'tag/'+tag+'/">'+tag+'</a>';
    4646            }).join( ', ' );
    4747
Note: See TracChangeset for help on using the changeset viewer.