Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 7,826 through 7,850 (of 32,505 total)
  • Author
    Search Results
  • #166865
    Robkk
    Moderator

    You find this in your theme, most likely in the functions.php file, but it could be different depending on the theme. You would spot by the register nav menu function like what is listed in this page.

    https://codex.wordpress.org/Function_Reference/register_nav_menus

    If you have a free theme I could check it out and get the arguments you need.

    If not there may be some arguments like menu slug that could help, but I need the name of the menu you are wanting to put the profile link in.

    #166864
    dayan89
    Participant

    I’ve learned the code of theme locations tab and found the name of my top menu. It was “top-menu”

    Now I have profile link in top menu. But how can I make it first item in menu, not last?

    #166863
    Robkk
    Moderator

    Interesting survey results!! I keep forgetting to comment my thoughts on this!!

    I am surprised that theming bbPress is split between all three of the choices listed, I expected most people to rely on their custom built themes and theme compatibility of bbPress like last year. So it seems not just developers/knowledgeable coders know how to use bbPress with any theme.

    I can see there is a small increase of developers creating sites with bbPress forums for others, but a decrease in users creating themes and plugins. So at least more developers are interested in bbPress, but I bet once the plugin and theme development guides are finally up, that there will be an increase in plugin and theme development.

    There is an increase in multisite usage of bbPress, which is good to see.

    I believe Gaming, Academic, and Music site types could possibly use an increase in site types using bbPress.

    Users contributing to bbPress has seem to have lowered quite a bit, which is not good. Hopefully there are a few things that can change that. People are joining slack though, so there is that.

    Desktop and Laptop is being mostly used by users, while they seem to want a better mobile experience. I will keep that definitely in mind as times are changing, and people browse while on mobile more than in the past.

    I am surprised unread replies and quotes have dropped a tad for being a requested feature, but there are some great plugins that can add that functionality.

    People want bbPress topics to replace WordPress comments more than ever.

    There is a lot more positive feedback on the comments left in the survey listed at the very bottom on this. Which is very good. I also think these comments are one of the most important parts to pay attention to of the survey.

    http://mercime.github.io/bbPress-2015-survey-results/


    @mercime
    thanks for doing a wonderful job with the survey. ๐Ÿ™‚

    #166860
    project_subdomain
    Participant

    tested commenting out above part several times which gave me correct titles and wrong titles when active. Did a systematic check then by deactivating plugins one after one and custom codes one after one and reversed, also refreshed the page title via backend (no caching in use). Nothing found to make the titles correct except commenting out above part.
    I cannot reproduce it as well.

    #166859
    Robkk
    Moderator

    Hmm, the repair tools should have fixed it. There is even a repair tool named

    Recalculate the sticky relationship of each topic

    There is not really a setting for sticky topics, it is basically a post status similar to sticky posts in WordPress. The query for topics just displays sticky posts first then the rest of the topics after that.

    Did you sort the topics differently by using a code snippet from this website, like sort topics by date or something different??

    #166853
    Robkk
    Moderator

    I think this plugin will allow you to customize how the notifications look in Settings > Forums. There might be shortcodes to change the content to use excerpt instead.

    https://wordpress.org/plugins/bbpress-custom-reply-notifications/

    #166848
    @mercime
    Moderator

    @yolandal backup database and files, then check out the Mingle Forum importer https://codex.bbpress.org/getting-started/importing-data/import-forums/

    #166846
    Karthikeyan KC
    Participant

    Uh! Found it!

    bbp_show_lead_topic


    Hope it helps others…

    #166839
    guillaumemolter
    Participant

    Thank you! I did the same…copy pasted the shortcode from this page! And was desperatly trying to find how to remove this non-html5 tag from bb-press!

    You saved my day!

    #166838
    Robkk
    Moderator

    There is a way to put it into a specific menu if you know exactly what the theme location or any additional menu arguments of a specific menu are.

    Here is an example if the theme location is primary.

    add_filter('wp_nav_menu_items','rk_bbp_menu_profile_link', 10, 2);
    function rk_bbp_menu_profile_link( $items, $args ) {
        if( is_user_logged_in() && $args->theme_location == 'primary')  {
    		
    	$current_user = wp_get_current_user();
            $user = $current_user->user_nicename;
    	$profilelink = '<a href="/forums/users/' . $user . '/">Your Profile</a>';
            $items .=  '<li>' . $profilelink .  '</li>';
    
    	}
        return $items;
    }
    #166837
    Kasi Salyer
    Participant

    Hi,

    Here is what I see using codestyling localisation :

    Loading Issue: Author is using load_textdomain instead of load_plugin_textdomain function. This may break behavior of WordPress, because some filters and actions wonโ€™t be executed anymore. Please contact the Author about that.

    Thanks.

    #166835
    Robkk
    Moderator

    Haha! I did not even edit/create this page before. ๐Ÿ™‚

    Alright, thanks for pointing that out. I just now changed the errors you pointed out for now, but this guide might be completely rewritten later because it does contain information that is similar to/that should be in the theme compatibility guide.

    Theme Compatibility

    And it kind of has information that might be in this guide later when it is finished.

    Template hierarchy in detail

    The amending templates guide might be a comprehensive guide all about customizing the templates/creating custom templates/customizing how theme compatibility works, and not necessarily about just copying the templates in your theme and knowing that you can customize it.

    #166833
    deanljbirch
    Participant

    Hey Robkk,

    Thanks for getting back to me.

    Link : https://codex.bbpress.org/themes/amending-bbpress-templates/ (Last paragraph 2nd word)

    Deano ๐Ÿ™‚

    #166830
    Robkk
    Moderator

    It is weird that you got this new issue. I just tested the snippet again on my WAMP server to check with the latest version of WordPress, switched to German again, and also see if it conflicts with the last code snippet I gave you, but I do not see an issue on my side.

    #166829
    dayan89
    Participant

    Hi,

    I have two menu areas on my website: main and top. I would like to add user profile link to top menu only.

    I found this example, which was were useful: https://codex.bbpress.org/layout-and-functionality-examples-you-can-use/#8-add-edit-profile-to-a-wordpress-menu But it adds link to both menus, top and main. I would like to add user profile link only to top menu, without adding it to main menu.

    Can you help me please?

    #166828
    project_subdomain
    Participant

    just had the problem that on all not bbpress-related pages the title was ” ‘s “.
    When commenting out the part for “User is viewing someone else’s profile” it’s working correctly on all pages, also when viewing another profile:

    else {
    			$new_title['text'] = sprintf( esc_attr_x( "%s's", 'User viewing another users profile', 'bbpress' ), get_userdata( bbp_get_user_id() )->display_name );
           }

    fyi new occurred, just had a wordpress update recently

    #166827
    project_subdomain
    Participant

    UPDATE: sorry, thought code is causing the browser’s title as ” ‘s” on all non-bbpress-related pages. need to find the reason which does not seem to be in relation to this topic.

    #166825
    wpman
    Participant

    I have a taxonomy:location
    I try to register views for all terms.but it doesn’t work.


    function taxonomy_custom_views() {
    $args = array('orderby'=>'asc','hide_empty'=>true);
    $terms = get_terms(array('location'), $args);
    foreach($terms as $term){
    $location_term=$term->slug ;
    $location_name=$term->name ;
    bbp_register_view( $location_term , __( $location_name ),array('tax_query' => array(array('taxonomy' => 'location','field' => 'slug','terms' => $location_term,),),), false );
    }
    }
    add_action( 'bbp_register_views', 'taxonomy_custom_views' );

    #166820

    In reply to: Groups and Forums

    Robkk
    Moderator

    [bbp-topic-form forum_id=$forum_id] โ€“ Display the โ€˜New Topic Formโ€™ for a specific forum ID.

    Shortcodes

    #166819
    project_subdomain
    Participant

    to prevent showing all users’ replies in ‘my replies’ this code works instead, which robkk wrote:

    function custom_bbp_has_replies( $args ) { 
        if ( bbp_is_single_topic() && !bbp_is_single_user() ) { 
            $args['orderby'] .= 'post_modified';
            $args['order'] .= 'DESC';
        } 
        return $args; 
    } 
    add_filter('bbp_before_has_replies_parse_args', 'custom_bbp_has_replies' );
    #166818
    lfeddern
    Participant

    Hi,

    I have a catagory with several different forums in it. I would like to display the most recent topics from the category. Am I right in thinking there is no shortcode that allows this?

    Could I achieve this by just getting them to display some how by forum id? If I have to query the latest topics from certain forums which function would I have to use? I have looked at the docs but the functions don’t seem to be documented.

    Thanks for any help;

    #166817
    project_subdomain
    Participant

    great, it’s working! thank you so much – really saved my day (night already)! just had to change some brackets. so this is working:

    function custom_bbp_has_replies( $args ) { 
        if ( bbp_is_single_topic() && !bbp_is_single_user() ) { 
            $args['orderby'] .= 'post_modified';
            $args['order'] .= 'DESC';
        } 
        return $args; 
    } 
    add_filter('bbp_before_has_replies_parse_args', 'custom_bbp_has_replies' );
    #166816

    In reply to: Groups and Forums

    chigoziekyrian
    Participant

    Thanks for your reply, please where can i get the forum specific topic form short code, do you have or know it? because i haven’t seen it before.. thanks

    #166811

    In reply to: Comments

    Robkk
    Moderator

    Moved your reply to here since it is related to the topic you created earlier.

    You cannot move additional replies to a subforum by default or with a plugin I know. You may need to consider hiring a developer for to create this for you.

    Since I think you basically said the topic gets hidden in all the replies. You can use this function to always display the topic no matter what page you are on like how these forums have by default.

    function custom_bbp_show_lead_topic( $show_lead ) {
      $show_lead[] = 'true';
      return $show_lead;
    }
     
    add_filter('bbp_show_lead_topic', 'custom_bbp_show_lead_topic' );
    #166807
    Robkk
    Moderator

    Well there are these if you do not have show topic lead enabled.

    add_action( 'bbp_theme_before_reply_content', 'function_name' );		
    add_action( 'bbp_theme_after_reply_content', 'function_name' );	

    You may need to use a conditional to only display your value on the first reply/topic if they have the same ID.

    if ( bbp_get_reply_id() == bbp_get_topic_id() ) {

Viewing 25 results - 7,826 through 7,850 (of 32,505 total)
Skip to toolbar