Skip to:
Content
Pages
Categories
Search
Top
Bottom

BBPRESS replace Topics and Posts Menu Title with with Icon

Viewing 7 replies - 1 through 7 (of 7 total)

  • uksentinel
    Participant

    @uksentinel

    Re-bump encase anybody can advise πŸ‘


    Robin W
    Moderator

    @robin-w

    you would need to add this to your additional/custom css

    /*topic titles*/
    .bbpress .forum-titles {
    	overflow: hidden;
    }
    .bbpress .forum-titles .bbp-topic-voice-count::before,
    .bbpress .forum-titles .bbp-topic-reply-count::before {
    	font: 400 16px/1 dashicons;
    	margin-right: 100px;
    	-moz-osx-font-smoothing: grayscale;
    	-webkit-font-smoothing: antialiased;
    }
    
    	.bbpress .forum-titles .bbp-topic-voice-count::before,
    	.bbpress .forum-titles .bbp-topic-reply-count::before {
    		font: 400 21px/1 dashicons;
    		margin-left: 20px;
    	}
    
    .bbp-topic-voice-count {
    	display: none;
    }
    
    .bbpress .forum-titles .bbp-topic-voice-count::before {
    	content: "\f307";
    }
    .bbpress .forum-titles .bbp-topic-reply-count::before {
    	content: "\f125";
    }
    
    .bbpress li.bbp-header li.bbp-forum-info,
    .bbpress li.bbp-header li.bbp-topic-title {
    	text-align: left !important;
    }

    and then amend loop-topics.php as foillows

    find
    wp-content/plugins/bbpress/templates/default/bbpress/loop-topics.php

    transfer this to your pc and edit

    <li class="bbp-topic-voice-count"><?php esc_html_e( 'Voices', 'bbpress' ); ?></li>
    			<li class="bbp-topic-reply-count"><?php bbp_show_lead_topic()
    				? esc_html_e( 'Replies', 'bbpress' )
    				: esc_html_e( 'Posts',   'bbpress' );
    			?></li>

    to

    <li class="bbp-topic-voice-count"></li>
    <li class="bbp-topic-reply-count"></li>

    and save

    create a directory on your theme called ‘bbpress’
    ie wp-content/themes/%your-theme-name%/bbpress

    where %your-theme-name% is the name of your theme

    Then transfer the file you saved above and put in in the directory called bbpress that you created above, so you end up with
    wp-content/themes/%your-theme-name%/bbpress/loop-topics.php.php

    bbPress will now use this template instead of the original


    uksentinel
    Participant

    @uksentinel

    Thanks Robin

    I have already created a directory on my theme called β€˜bbpress’ so will add and then mod the loop-topics.php and add the custom css as advised.

    Your guidance most appreciated as always and hopefully this will be useful for others also πŸ‘

    P.S. Shame you cannot add this to your BBP Style Pack at some point in the future as I am sure lots of BBPRESS Forum owners/dev’s would like this option 😏


    uksentinel
    Participant

    @uksentinel

    Hi Robin

    An update to say the CSS worked perfectly and now I have Icons on my forum heading menu where there was the Voices and Replies wording.

    I am going to use the above CSS as a start and see if I can also achieve the same for Topics and Posts on the forum heading main front forum page.

    Cheeky link to my site so others can see progress also πŸ˜‰

    https://uktechhub.com/forums/forum/wireless-routers-modems/asus/


    uksentinel
    Participant

    @uksentinel

    So I have worked out how to modify the BBPRESS main forum menu ‘Topics and Posts’ titles to now show Icons as per Topics Voice and Topics Replies (as above).

    I then modified the Loop-Forum.php file and edited as described above for the Loop-Topics.php but changed the …

    <li class=”bbp-topic-voice-count”>
    <li class=”bbp-topic-reply-count”>

    for

    <li class=”bbp-forum-topic-count”>
    <li class=”bbp-forum-reply-count”>

    This does remove the menu bar ‘Topics and Posts’ titles but alas this seems to cause a clash (maybe) with BBP-Style-Pack as the main forum page becomes distorted.


    Robin W
    Moderator

    @robin-w

    now added to version 5.9.2

    bbp style pack

    see forums index and topics index tabs.


    uksentinel
    Participant

    @uksentinel

    Thank you πŸ‘

Viewing 7 replies - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.
Skip to toolbar