Robin W (@robin-w)

Forum Replies Created

Viewing 25 replies - 12,426 through 12,450 (of 13,959 total)
  • In reply to: Content Not Showing

    @robin-w

    Moderator

    not sure quite how threatening to remove something that is free, cost you nothing, and is supported by volunteers who are paid nothing and have tried to help you to get something working that you had working perfectly well at the start, but has somehow got messed up is really s’posed to progress to a resolution.

    I know you are frustrated, but taking it out on here is not really the answer 🙂

    I hope you are able to get it working, but if not find another solution, and wish you the best for the future.

    @robin-w

    Moderator

    bbpress has a separate set of capabilities, so you can set permissions for the wordpress part of your site totally separately to the capabilities for bbpress.

    see

    https://codex.bbpress.org/bbpress-user-roles-and-capabilities/

    and if needbe

    Custom Capabilities

    In reply to: Content Not Showing

    @robin-w

    Moderator

    do you mean the permalink for your topic is

    /edit.php?post_type=topic

    as in example below where the permalink is under the title

    dd

    @robin-w

    Moderator

    long answer I’m afraid and in two parts

    part 1 – setting the user permission to allow delete topic and delete reply

    delete is easy, making it only trash is in part 2 !

    Basically you’ll need to change a couple of capabilities of the participant role

    see

    https://codex.bbpress.org/bbpress-user-roles-and-capabilities/

    you see the abilities delete topics and delete replies (as distinct from delete others topics and delete others replies)

    Whilst you could amend the participant role, I haven’t documented that, so easiest is just for you to create a new role and give it the participant capabilities plus the ‘delete topics’ and ‘delete replies’. This article explains how

    Custom Capabilities

    add this code to your functions file – see

    Functions files and child themes – explained !

    part 2 – changing the function, so that delete is only shown for keymasters

    This code will only allow a keymaster to permanently delete a topic

    add the following to your functions file

    add_filter ('bbp_get_topic_trash_link', 'topic_dont_delete');
    add_filter ('bbp_get_reply_trash_link', 'reply_dont_delete');
    
    function topic_dont_delete( $args = '') {
    
    		// Parse arguments against default values
    		$r = bbp_parse_args( $args, array(
    			'id'           => 0,
    			'link_before'  => '',
    			'link_after'   => '',
    			'sep'          => ' | ',
    			'trash_text'   => esc_html__( 'Trash',   'bbpress' ),
    			'restore_text' => esc_html__( 'Restore', 'bbpress' ),
    			'delete_text'  => esc_html__( 'Delete',  'bbpress' )
    		), 'get_topic_trash_link' );
    
    		$actions = array();
    		$topic   = bbp_get_topic( bbp_get_topic_id( (int) $r['id'] ) );
    
    		if ( empty( $topic ) || !current_user_can( 'delete_topic', $topic->ID ) ) {
    			return;
    		}
    
    		if ( bbp_is_topic_trash( $topic->ID ) ) {
    			$actions['untrash'] = '<a title="' . esc_attr__( 'Restore this item from the Trash', 'bbpress' ) . '" href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'bbp_toggle_topic_trash', 'sub_action' => 'untrash', 'topic_id' => $topic->ID ) ), 'untrash-' . $topic->post_type . '_' . $topic->ID ) ) . '" class="bbp-topic-restore-link">' . $r['restore_text'] . '</a>';
    		} elseif ( EMPTY_TRASH_DAYS ) {
    			$actions['trash']   = '<a title="' . esc_attr__( 'Move this item to the Trash',      'bbpress' ) . '" href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'bbp_toggle_topic_trash', 'sub_action' => 'trash',   'topic_id' => $topic->ID ) ), 'trash-'   . $topic->post_type . '_' . $topic->ID ) ) . '" class="bbp-topic-trash-link">'   . $r['trash_text']   . '</a>';
    		}
    		
    		if ( bbp_is_topic_trash( $topic->ID ) || !EMPTY_TRASH_DAYS ) {
    		if ( bbp_is_user_keymaster()) {
    		$actions['delete']  = '<a title="' . esc_attr__( 'Delete this item permanently',     'bbpress' ) . '" href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'bbp_toggle_topic_trash', 'sub_action' => 'delete',  'topic_id' => $topic->ID ) ), 'delete-'  . $topic->post_type . '_' . $topic->ID ) ) . '" onclick="return confirm(\'' . esc_js( __( 'Are you sure you want to delete that permanently?', 'bbpress' ) ) . '\' );" class="bbp-topic-delete-link">' . $r['delete_text'] . '</a>';
    		}
    		}
    
    				// Process the admin links
    		$retval = $r['link_before'] . implode( $r['sep'], $actions ) . $r['link_after'];
    
    		return $retval ;
    	}
    	
    	function reply_dont_delete( $args = '' ) {
    
    		// Parse arguments against default values
    		$r = bbp_parse_args( $args, array(
    			'id'           => 0,
    			'link_before'  => '',
    			'link_after'   => '',
    			'sep'          => ' | ',
    			'trash_text'   => esc_html__( 'Trash',   'bbpress' ),
    			'restore_text' => esc_html__( 'Restore', 'bbpress' ),
    			'delete_text'  => esc_html__( 'Delete',  'bbpress' )
    		), 'get_reply_trash_link' );
    
    		$actions = array();
    		$reply   = bbp_get_reply( bbp_get_reply_id( (int) $r['id'] ) );
    
    		if ( empty( $reply ) || !current_user_can( 'delete_reply', $reply->ID ) ) {
    			return;
    		}
    
    		if ( bbp_is_reply_trash( $reply->ID ) ) {
    			$actions['untrash'] = '<a title="' . esc_attr__( 'Restore this item from the Trash', 'bbpress' ) . '" href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'bbp_toggle_reply_trash', 'sub_action' => 'untrash', 'reply_id' => $reply->ID ) ), 'untrash-' . $reply->post_type . '_' . $reply->ID ) ) . '" class="bbp-reply-restore-link">' . $r['restore_text'] . '</a>';
    		} elseif ( EMPTY_TRASH_DAYS ) {
    			$actions['trash']   = '<a title="' . esc_attr__( 'Move this item to the Trash',      'bbpress' ) . '" href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'bbp_toggle_reply_trash', 'sub_action' => 'trash',   'reply_id' => $reply->ID ) ), 'trash-'   . $reply->post_type . '_' . $reply->ID ) ) . '" class="bbp-reply-trash-link">'   . $r['trash_text']   . '</a>';
    		}
    
    		if ( bbp_is_reply_trash( $reply->ID ) || !EMPTY_TRASH_DAYS ) {
    		if ( bbp_is_user_keymaster()) {
    		$actions['delete']  = '<a title="' . esc_attr__( 'Delete this item permanently',     'bbpress' ) . '" href="' . esc_url( wp_nonce_url( add_query_arg( array( 'action' => 'bbp_toggle_reply_trash', 'sub_action' => 'delete',  'reply_id' => $reply->ID ) ), 'delete-'  . $reply->post_type . '_' . $reply->ID ) ) . '" onclick="return confirm(\'' . esc_js( __( 'Are you sure you want to delete that permanently?', 'bbpress' ) ) . '\' );" class="bbp-reply-delete-link">' . $r['delete_text'] . '</a>';
    		}
    		}
    
    		// Process the admin links
    		$retval = $r['link_before'] . implode( $r['sep'], $actions ) . $r['link_after'];
    
    		return $retval ;
    	}
    

    I haven’t fully tested this code as my test site is in some disarray whilst I test something else, so you’ll need to check that it works

    In reply to: Forum Structure error

    @robin-w

    Moderator

    1. go into dashboard>forums and under the title you will see the forum’s permalink. It should read forum-2. change it to forum

    2. go into dashboard>settings>forums and look for forum prefix, and untick

    In reply to: Content Not Showing

    @robin-w

    Moderator

    ok, thanks for that info

    if you go into

    Dashboard>topics>all topics –

    1. can you see and edit the topic?

    2. what is the topics permalink? (just under the heading)

    (this is just for my info)

    then reset the permalinks

    dashboard>settings>permalinks

    see what they are set to, change them to anything else and save, and then change them back and save.

    The come back and tell me what happened !

    In reply to: Content Not Showing

    @robin-w

    Moderator

    just seen you later post – you should have

    dashboard>settings>forums

    have you got that?

    In reply to: Content Not Showing

    @robin-w

    Moderator

    ok, I presume the one topic posted is after you re-installed

    did you have topics before that you are expecting to see?

    In reply to: Content Not Showing

    @robin-w

    Moderator

    Hi, sorry but can you post a screenshot of what it looks like via say photobucket?

    Thanks

    In reply to: Content Not Showing

    @robin-w

    Moderator

    did you install any other plugins in between?

    try

    Plugins

    Deactivate all but bbpress and see if this fixes. if it does, re-enable one at a time to see which is causing the error.

    Themes

    If plugins don’t pinpoint the problem, switch to a default theme such as twentytwelve, and see if this fixes.

    I know you’ve done themes already, but you need to test if it works on a default theme with just twentyfourteen and the bbpress plugin. If it doesn’t then something in your site is screwed up 🙂

    @robin-w

    Moderator

    presume you removing the titles from

    wp-content/bbpress/templates/default/bbpress/loop-forums

    and renaming as per

    https://codex.bbpress.org/step-by-step-guide-to-setting-up-a-bbpress-forum-part-3/ section 3

    then

    wp-content/bbpress/templates/default/bbpress/loop-single-forum

    has the content that you’ll want to take out

    @robin-w

    Moderator

    @robin-w

    Moderator

    but you don’t have to do it al at once, so take a pause and go back to it in a short while… 🙂

    @robin-w

    Moderator

    yes it was supposed to change the color to black.

    You can change it to whatever color you want

    see

    http://www.w3schools.com/html/html_colors.asp

    and maybe use

    http://colorcop.net/

    to find the right color

    Please don’t stop – keep improving that is what you are supposed to do, you’ve come a long way – learned how to create a test site, add functions and styles, but it requires effort ! Learning firebug will help you tailor your site’s styling. Adding color cop will let you choose colors – please keep working at getting a site that is what you want. 🙂

    ‘ I am afraid to mess with these things like firebug. 🙂 ‘ – 1. that is what the test site is for, 2. conquering fear is part of life’s journey, and surely this is only a very petty fear – work through it !

    I’ll come back on registration when I get a moment.

    @robin-w

    Moderator

    hmmm.. ok but we’re starting to need lots of extra code

    ok so add

    #bbpress-forums a {
    color: #111111 !important ;
    }

    This will change the font throughout, and you can play with the colour.

    If you want the topic and date to be different, we’re getting into some real css styling, which is beyond the purpose of the bbpress support forum, and perhaps you need to start to look at how to use firebug so you can see what you need to change eg

    then you can style any forums part by preceding it with

    #bbpress-forums as I’ve done above.

    @robin-w

    Moderator

    to change the font (sorry I missed that) , change it to

    #bbpress-forums div.bbp-forum-title h3, #bbpress-forums div.bbp-topic-title h3, #bbpress-forums div.bbp-reply-title h3, #bbpress-forums a.bbp-forum-title, #bbpress-forums a.bbp-topic-permalink {
    color: #666 !important;
    font-family: ‘Open Sans’,Arial,sans-serif !important;
    font-size: 16px !important;
    }

    @robin-w

    Moderator

    No 2 did not seem to work on the test so i did not add it live. I added it to the bottom of the style.css so I am unsure if that is the issue.

    No 2 changed the font colour and size of the forum list – look at ‘prayer requests’ in you test and live sites to see the difference.

    What else do you want to change?

    @robin-w

    Moderator

    @marianne78 not quite sure what you are saying.

    Can you detail
    how many forums you have,
    whether they are all private,
    when the message appears (eg when not logged in),
    whether you are using a forum page with bbp-index in it,
    what settings you have for dashboard>settings>bbp private groups in forum visibility settings and general settings

    Thanks

    @robin-w

    Moderator

    Now, can you explain what registration process you would like eg

    user does this
    what user info you want
    emails goes from..to…saying
    Site manager does that…

    etc. ie design your ideal process 🙂

    @robin-w

    Moderator

    you’re welcome

    @robin-w

    Moderator

    for no. 1, add this code to your functions file

    //display last topic title in freshness for forums
    function display_title ($anchor, $forum_id, $time_since, $link_url, $title, $active_id ) {
    $anchor = '<ul><li><a href="' . esc_url( $link_url ) . '" title="' . esc_attr( $title ) . '">' . esc_html( $title) . '</a></li></ul><a href="' . esc_url( $link_url ) . '" title="' . esc_attr( $title ) . '">' . esc_html( $time_since ) . '</a>';
    return $anchor ;
    }
    add_filter ('bbp_get_forum_freshness_link', 'display_title', 10, 6 );

    Having coded it, I like the way it displays, and will be adding to the forums on one of the sites I support – one of the reasons I support this forum is that I learn and get ideas from others 🙂

    @robin-w

    Moderator

    @robin-w

    Moderator

    for no. 2

    add

    #bbpress-forums div.bbp-forum-title h3, #bbpress-forums div.bbp-topic-title h3, #bbpress-forums div.bbp-reply-title h3, #bbpress-forums a.bbp-forum-title, #bbpress-forums a.bbp-topic-permalink {
      color: #666 !important;
      font-size: 16px !important;
    }
    
    

    to your style.css

    In reply to: How to add a @username

    @robin-w

    Moderator

    great – glad you’re fixed !

    @robin-w

    Moderator

    great – glad you’re fixed !

Viewing 25 replies - 12,426 through 12,450 (of 13,959 total)