Skip to content

Commit

Permalink
Speaker post type: Link WordPress.org username to profiles. (#1448)
Browse files Browse the repository at this point in the history
* Speaker post type: WordPress.org username should link to profile.
  • Loading branch information
dd32 authored Dec 19, 2024
1 parent 5394773 commit 6a4da3f
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -633,7 +633,7 @@ public function get_speaker_wporg_permalink( $speaker_id ) {
return null;
}

$permalink = sprintf( 'http://profiles.wordpress.org/%s', strtolower( $user->user_nicename ) );
$permalink = sprintf( 'http://profiles.wordpress.org/%s/', strtolower( $user->user_nicename ) );
return esc_url_raw( $permalink );
}

Expand Down Expand Up @@ -1916,7 +1916,11 @@ public function manage_post_types_columns_output( $column, $post_id ) {
$wporg_user = get_user_by( 'id', $user_id );

if ( $wporg_user ) {
echo esc_html( $wporg_user->user_login );
printf(
'<a href="%s">%s</a>',
esc_url( 'https://profiles.wordpress.org/' . $wporg_user->user_nicename . '/' ),
esc_html( $wporg_user->user_login )
);
}

break;
Expand Down

0 comments on commit 6a4da3f

Please sign in to comment.