Robkk (@robkk)

Forum Replies Created

Viewing 25 replies - 3,726 through 3,750 (of 3,784 total)

  • Robkk
    Moderator

    @robkk

    @robin-w i couldnt get the if ( bbp_is_topic function working

    i wanted to test out if i could do this , took code from this

    <div class="dropdown" id="dropdown">
    				<input type="checkbox" id="drop1" />
            <label for="drop1" class="dropdown_button">Topic Tools</label>
            <ul class="dropdown_content">
                <li class="active"></li>
                  <li> <?php echo bbp_get_reply_to_link(); ?></li>
                  <li><?php if ( bbp_is_topic( $r['id'] ) ) {
    echo bbp_get_topic_reply_link(); ?></li>
                  <li><?php if ( bbp_is_topic( $r['id'] ) ) {
    return bbp_get_topic_reply_link(); ?></li>
            </ul>
            
        </div>

    then make a dropdown menu from that i guess , but im just swinging the dark not really getting a exactly great way of doing what i want to achieve.

    plus i might have to go to a jquery menu template like this

    because the css menus arent working on all replies.


    Robkk
    Moderator

    @robkk

    i cant access your site to take pictures


    Robkk
    Moderator

    @robkk

    you want to change the

    links that come up with a topic or reply so that only some show, and others are in a dropdown list.

    is that correct?

    yes

    This also gives you the ability to add a new link

    yeah i added the topic favorite link to see if it worked and it did with the ajax too
    and also a mark topic as read from the bbpress go to first unread plugin

    You’ll also see that this function checks if it is a topic on line 1825

    i used this as a filter for the topic admin links

    //change admin links displayed
    function change_topic_admin_links ($r) {
    $r['links'] = apply_filters( 'rw_topic_admin_links', array(
    				'edit'  => bbp_get_topic_edit_link ( $r ),
    				'reply'  => bbp_get_topic_reply_link ( $r )
    				
    			), $r['id'] );
    return $r['links'] ;
    }
    add_filter ('bbp_topic_admin_links', 'change_topic_admin_links' ) ;

    i tried using this function to post a single admin link for a topic
    and also just by replacing return with echo
    but i cant seem to get that to work

    if ( bbp_is_topic( $r['id'] ) ) {
    			return bbp_get_name_of_link();
    		}
    
    		if ( !bbp_is_reply( $r['id'] ) ) {
    			return bbp_get_name_of_link() ;
    		}

    Robkk
    Moderator

    @robkk

    checked it out

    are you basically making all the css from scratch?? like even the menu positioning (idk why that looks off on my side)??

    ya need to fix alot in the css positioning of things and add a tiny bit of spacing to some items

    make sure everything is aligned up right and not look awkward in some areas


    Robkk
    Moderator

    @robkk

    bbPress – Ajax Replies

    this plugin only seemed to work for me when threaded replies is activated

    In reply to: Forum index

    Robkk
    Moderator

    @robkk

    there is a little bug on this
    that i could fix in the future

    whenever i subscribe to a forum
    it shows the menu on subscribed forums in the subscriptions area in your profile
    (it showed up on the forums area in my buddypress extended profiles)

    easy fix is to turn off subscriptions to forums and topics in bbpress forum settings

    ill try to find a css way to fix this , if not ILL look up another way


    @netweb
    i might put this into the codex if i fix all the nooks and crannies

    In reply to: How to add a @username

    Robkk
    Moderator

    @robkk

    how do I change the font colour of @username?

    im going to use my version though , cause i dont know how with the add action version

    <p class=bbp-user-nicename><?php $user = get_userdata( bbp_get_reply_author_id() );
    if ( !empty( $user->user_nicename ) ) {
    $user_nicename = $user->user_nicename;
    echo "@".$user_nicename;
    } ?></p>

    throw this into custom css

    #bbpress-forums p.bbp-user-nicename {
    font-weight: bold;
    color: #888;
    display: inline-block;
    margin: 0;
    }
    In reply to: How to add a @username

    Robkk
    Moderator

    @robkk

    How to add a @username like BBPress forum

    <?php $user = get_userdata( bbp_get_reply_author_id() );
    if ( !empty( $user->user_nicename ) ) {
    $user_nicename = $user->user_nicename;
    echo "@".$user_nicename;
    } ?>

    you add this to your loop-single-reply.php template


    Robkk
    Moderator

    @robkk

    nevermind i got it , i assumed i could easily do it with css

    after a couple of tries i eventually got it

    li.bbp-header {
        display: none;
    }

    hides the header on blog posts and forums

    but when i add

    .post li.bbp-header {
      background: none repeat scroll 0% 0% transparent;
      display:block;
    }

    the header is now just on forums and not on blog posts anymore

    this also works on the li.bbp-footer too

    and probably anything else if you just use

    display:none; to hide the original css for blog posts

    .post to display it only on forum pages

    In reply to: Forum index

    Robkk
    Moderator

    @robkk

    ok i checked out all the steps ,and i literally just copied and pasted my code and it worked
    fine for me bbmenu

    i checked out the code on how to register a new menu in woothemes canvas and it looks a little different from what the code i gave you.

    you can take a look at https://support.woothemes.com/hc/en-us/articles/203106807-Add-Custom-Navigation-Menus-in-Canvas and see the how its done.

    i pretty much gave you all you need , i just cant work on the exact structure on the code it might be just adding in ‘woothemes’ but i dont know for sure

    (i work trial and error, im a 19 y/o newb haha) .

    you could wait til @robin-w or @netweb takes over , work it out yourself, or contact woothemes and link them to this topic and maybe they will help you out too.

    In reply to: Forum index

    Robkk
    Moderator

    @robkk

    Could it be a problem with canvas?

    it shouldnt be

    In reply to: Forum index

    Robkk
    Moderator

    @robkk

    well maybe there is a problem with recognizing the menu location , like exactly where the function is in loop-forums.php

    first let me see a link to your website

    then im going to recreate this bbpress menu from the steps i gave you and see if i made an error copying and pasting

    by the time i finish this is what you could do

    put <nav id="subnav" role="navigation">

    <?php
    if ( has_nav_menu( 'bbmenu' ) ) { /* if menu location 'bbmenu' exists then use custom menu */
          wp_nav_menu( array( 'theme_location' => 'bbmenu') ); 
    }
    ?>
    
    </nav>

    below <?php do_action( 'bbp_template_before_forums_loop' ); ?>

    and see if that fixes anything


    Robkk
    Moderator

    @robkk

    I use Yoast breadcrumbs from Yoast SEO plugin could that effect the bbpress breadcrumbs

    yes

    if it checked in the internal links settings

    if so to display the bbpress breadcrumbs uncheck it or use this in functions.php in a child theme

    remove_filter( 'bbp_get_breadcrumb', '__return_false' );

    In reply to: Forum index

    Robkk
    Moderator

    @robkk

    everything on here requires you to have a child theme. especially bbpress templates in your child theme

    In reply to: Forum index

    Robkk
    Moderator

    @robkk

    oh yeh create a new menu, name it , and any links to your forums with the link module in the wordpress menu system . make sure when you see theme locations click bbpress Forum Menu

    now save and your menu should show up in your forum archive

    In reply to: Forum index

    Robkk
    Moderator

    @robkk

    okay what they did was register a menu which is a whole lot easier

    so first put this in your functions.php if you have a child theme

    function register_menu() {
    	register_nav_menu('bbmenu', __('bbpress Forum Menu'));
    }
    add_action('init', 'register_menu');
         		

    and now put this above <?php do_action( 'bbp_template_before_forums_loop' ); ?>
    which is inside loop-forums.php inside the bbpress default templates

    <nav id="subnav" role="navigation">
    
    <?php
    if ( has_nav_menu( 'bbmenu' ) ) { /* if menu location 'bbmenu' exists then use custom menu */
          wp_nav_menu( array( 'theme_location' => 'bbmenu') ); 
    }
    ?>
    
    </nav>

    now put this in your custom css or plugin

    #subnav {
    	background: none;
    	clear: both;
    	display: block;
    	float: left;
    	margin: 0 auto 6px;
    	width: 100%;
    }
    
    #subnav ul {
    	font-size: 13px;
    	list-style: none;
    	margin: 0;
    }
    
    #subnav li {
    list-style-type: none;
    display: inline-block;
    margin: 6px 4px;
    }
    
    #subnav a {
    text-decoration: none;
    color: #555;
    background: #ddd;
    padding: 2px 8px;
    border: 1px solid #e4e4e4;
    }
    
    #subnav li a:hover {
    background: #333;
    color: #fff;
    border-color: transparent;
    text-shadow: none;
    }

    tell me if you come into any problems , so i can see if i hadd a problem copy and pasting

    In reply to: Forum index

    Robkk
    Moderator

    @robkk

    its basically html links manually written to go to each forum

    like what you did to link to singletrackworld, it just has a little bit of style with css

    ILL hook you up in a minute(it will be awhile) though


    Robkk
    Moderator

    @robkk

    thanks 🙂

    In reply to: Forum index

    Robkk
    Moderator

    @robkk

    @dottedpixel

    could you highlight what you want exactly

    cause im not sure what you want , the way the forums itself display?

    or the links above the forum that display each forum name? <–thats really easy

    you could probably do the other thing with shortcodes


    Robkk
    Moderator

    @robkk

    haha well remove topic description to


    Robkk
    Moderator

    @robkk

    add_filter( 'bbp_get_single_forum_description', 'ja_return_blank' );
    
    add_filter( 'bbp_get_single_topic_description', 'ja_return_blank' );
    
    function ja_return_blank() {
    
        return '';
    
    }

    i have this in my functions php in my child theme


    Robkk
    Moderator

    @robkk

    keep buddypress uninstall bbpress?


    Robkk
    Moderator

    @robkk

    ok, ignore the code (it is confusing me)

    i understand

    So you have a topic started and this displays in the ‘post author’ part an avatar, the topic author name, but no role

    it should just display the topic author name with a certain color

    Next someone replies and this displays in the ‘post author’ part an avatar, and the reply author name, but nothing else

    yes exactly

    Next is a reply by the original author, and in the ‘post author’ part this display an avatar, and their name in say a green block (and nothing else)

    yes

    Is that what you want?

    just in case heres a picture, zoom with the scroll wheel

    https://drive.google.com/file/d/0B_Ue9ryY5cmYTHhlRkg0a3k4T1U/edit?usp=sharing

    i used a blue because it was the color i had when photoshop was last used


    Robkk
    Moderator

    @robkk


    Robkk
    Moderator

    @robkk

    @robin-w yeah i still need help

Viewing 25 replies - 3,726 through 3,750 (of 3,784 total)