Making WordPress.org

Changeset 14519


Ignore:
Timestamp:
09/01/2025 02:43:43 AM (3 months ago)
Author:
dd32
Message:

Trac: Include trailing slashes in user links.

Fixes #8073.

Location:
sites/trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/trac.wordpress.org/templates/site-ticket.html

    r11797 r14519  
    55
    66<?python
    7     profile_link = 'https://profiles.wordpress.org/'
    8 
    97  field_types = [ 'milestone', 'priority', 'type', 'severity', 'version', 'component', 'keywords', 'focuses', ]
    108
     
    4846<!--! Gravatars for the ticket reporter -->
    4947<td py:match="td[@headers='h_reporter']" py:attrs="select('@*')" py:with="wporg_user = wporg_sanitize_user_nicename(ticket.reporter)">
    50   <a href="${profile_link + wporg_user}" data-nicename="${wporg_user}">
     48  <a href="https://profiles.wordpress.org/${wporg_user}/" data-nicename="${wporg_user}">
    5149    <img class="avatar" src="https://wordpress.org/grav-redirect.php?user=${wporg_user}&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=${wporg_user}&amp;s=96 2x" height="48" width="48" alt="${wporg_user}'s profile" />
    5250  </a>
     
    5654<!--! Gravatars for the ticket owner -->
    5755<td py:match="td[@headers='h_owner']" py:attrs="select('@*')">
    58   <a py:if="ticket.owner" py:with="wporg_user = wporg_sanitize_user_nicename(ticket.owner)" href="${profile_link + wporg_user}">
     56  <a py:if="ticket.owner" py:with="wporg_user = wporg_sanitize_user_nicename(ticket.owner)" href="https://profiles.wordpress.org/${wporg_user}/">
    5957    <img class="avatar" src="https://wordpress.org/grav-redirect.php?user=${wporg_user}&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=${wporg_user}&amp;s=96 2x" height="48" width="48" alt="${wporg_user}'s profile" />
    6058  </a>
  • sites/trunk/trac.wordpress.org/templates/site.html

    r14505 r14519  
    55
    66<?python
    7     scripts_version = '227'
     7    scripts_version = '228'
    88    project_slug = req.environ['HTTP_HOST'].split(':')[0].split('.')[0]
    99    wporg_endpoint = 'https://make.wordpress.org/' + project_slug + '/'
     
    293293    <py:match path="div[@id='content' and @class='prefs']/div[@id='tabcontent']" once="true">
    294294        <div id="tabcontent">
    295             Notifications are sent to the email listed in <a href="${profile_to_edit}${req.session['sid']}">your WordPress.org profile</a><py:if test="req.session['email']"> (${req.session['email']})</py:if>.
     295            Notifications are sent to the email listed in <a href="${profile_to_edit}${req.session['sid']}/">your WordPress.org profile</a><py:if test="req.session['email']"> (${req.session['email']})</py:if>.
    296296            <py:if test="notifications_enabled">
    297297                Notification preferences can be configured <a href="${wporg_endpoint}notifications/">here</a>.
  • sites/trunk/trac.wordpress.org/templates/ticket_change.html

    r14482 r14519  
    156156      <py:when test="'author' in change" py:with="wporg_user = wporg_sanitize_user_nicename(change.author)">
    157157        <span class="avatar" py:if="change">
    158           <span class="username-line"><a href="https://profiles.wordpress.org/${wporg_user}" class="profile-link">
     158          <span class="username-line"><a href="https://profiles.wordpress.org/${wporg_user}/" class="profile-link">
    159159            <img src="https://wordpress.org/grav-redirect.php?user=${wporg_user}&amp;s=48" srcset="https://wordpress.org/grav-redirect.php?user=${wporg_user}&amp;s=96 2x" height="48" width="48" alt="" /> @<span class="username" data-username="${change.author}" data-nicename="${wporg_user}">${authorinfo(change.author)}</span></a></span>
    160160          <py:if test="'date' in change">
  • sites/trunk/wordpress.org/public_html/style/trac/wp-trac.js

    r14505 r14519  
    220220
    221221                        var meClass = ( username === wpTrac.currentUser ) ? ' me' : '';
    222                         return pre + '<a class="mention' + meClass + '" href="https://profiles.wordpress.org/' + username + '">@' + username + '</a>';
     222                        return pre + '<a class="mention' + meClass + '" href="https://profiles.wordpress.org/' + username + '/">@' + username + '</a>';
    223223                    } );
    224224
     
    361361                if ( 0 === username.indexOf( 'logged in as' ) ) {
    362362                    username = username.replace( 'logged in as ', '' );
    363                     el.html( $('<a />', { href: 'https://profiles.wordpress.org/' + username }).text( username ) ).prepend( 'logged in as ');
     363                    el.html( $('<a />', { href: 'https://profiles.wordpress.org/' + username + '/' }).text( username ) ).prepend( 'logged in as ');
    364364                }
    365365            })(jQuery);
     
    643643
    644644                    author = $el.find( '.username' ).data( 'username' );
    645                     $commit.append( ' by&nbsp;<a href="https://profiles.wordpress.org/' + author + '">@' + author + '</a>' );
     645                    $commit.append( ' by&nbsp;<a href="https://profiles.wordpress.org/' + author + '/">@' + author + '</a>' );
    646646
    647647                    date = $el.find( '.time-ago' ).html();
Note: See TracChangeset for help on using the changeset viewer.