Robin W (@robin-w)

Forum Replies Created

Viewing 25 replies - 8,426 through 8,450 (of 14,219 total)
  • In reply to: Recent replies list

    @robin-w

    Moderator

    ok, remove the whole line

    <?php echo do_shortcode(‘[bbpress_recent_replies_by_topic show =5]’) ?>

    then add this to your functions

    add_action( 'bbp_template_before_forums_loop', 'call_bbpress_recent_replies_by_topic' ); 
    
    function call_bbpress_recent_replies_by_topic () {
    	echo do_shortcode("[bbpress_recent_replies_by_topic show=5]") ;
    }

    This just hooks to the line after the one you’d added

    <?php do_action( ‘bbp_template_before_forums_loop’ ); ?>

    so saving you having to amend that template.

    This works on my site.

    @robin-w

    Moderator

    ok, which div do you want the class added to, give me the existing class/classes in that div so I can identify

    @robin-w

    Moderator

    suggest you report it here

    Support Forums

    or talk to your host provider

    In reply to: Importing data via sql

    @robin-w

    Moderator

    great – glad to have helped 🙂

    In reply to: Link to bbpress

    @robin-w

    Moderator

    Not quite sure what what level of knowledge you are coming – the question could mean many things.

    If your front end is a page, then you just use wordpress to add a link into the content of thte page – the chain icon is the one. The url will be the one in your browser when you are on the forums part of the site.

    Otherwise come back with a more detailed request

    In reply to: Importing data via sql

    @robin-w

    Moderator

    bbpress just uses

    posts
    post_meta
    and for its own settings
    options

    forums, topics and replies are all post types in wordpress.

    go to

    Import Forums

    for more info including an example importer.

    I documented my import from snitz access database when I very first started using bbpress, and you may want to read through that as well in this page

    Custom Import

    @robin-w

    Moderator

    great – glad you are fixed

    @robin-w

    Moderator

    initially I’d ask learndash, and this is a paid plugin that I don’t have access to

    @robin-w

    Moderator

    the error is a permissions one.

    Does this occur on both the front end and the back end (dashboard>topcis>create new topic)
    Is it just one user, all users?

    In reply to: Recent replies list

    @robin-w

    Moderator

    not sure why, but adding show seems to fix

    <?php echo do_shortcode(‘[bbpress_recent_replies_by_topic show =5]’) ?>

    @robin-w

    Moderator

    I’ve been thinking this over, and can’t see a simple way to achieve this.

    To get something working would involve adding extra fields to a topics meta data, and then filtering the display to catch.

    With the forum visible in effect the code for a forum or set of forums would need to (by default) make a topic private using an additional field, and then all the display parameters would need to hide it unless made public. That means closing every back door in search, profiles, displays, freshness all widgets and other areas so that no-one sees it unless set to public, which is one hell of a lot of work, and a large re-write of many bbpress functions.

    I could modify my private groups plugin which makes forums (but not content) visible, so that certain topics are shown, but again it is a heap of code. Beyond free help I’m afraid, but if you want to look at that route contact me via my website http://www.rewweb.co.uk

    In reply to: Recent replies list

    @robin-w

    Moderator

    whereabouts in loop-forums.php did you put it ?

    @robin-w

    Moderator

    can you post the whole of your code – so I can copy/paste into my file and check what it does on mine

    @robin-w

    Moderator

    bbpress with a default theme (eg twentseventeen) will do the following

    • search for say ‘hello’
    • bbpress will produce all single topics and single replies that match this (which could be many)
    • for a reply you will see the reply with the words In reply to :the topic name as a link
    • click the topic name and you are taken to the topic

    If this is not what you are getting, then come back

    @robin-w

    Moderator

    did you change the filter – I was calling the wrong one should be

    add_filter( 'bbp_get_topic_freshness_link', 'rew_freshness_no_date_link' , 100, 5)

    @robin-w

    Moderator
    In reply to: access control

    @robin-w

    Moderator

    no problem, come back if I can help further 🙂

    @robin-w

    Moderator

    ok, so the forum is visible as existing, but non-logged-in can only see designated threads, other threads are not visible until they log in.

    Trying to think how easy that would be to achieve

    I’ll come back…

    @robin-w

    Moderator

    sort of but not quite 🙂

    if you don’t allow anonymous posting, then all threads are ‘locked’ to non-logged in users.

    Can you explain further with an example – just me not understanding I expect

    @robin-w

    Moderator

    thanks fro your post – I’m author of private groups.

    When you say ‘lock certain threads to non-logged in users’ – are you allowing anonymous posting?

    @robin-w

    Moderator

    ok, should have tested before sending, but coded it late last night and I have been out all day !

    Now had a chance to try it, and correct code is

    add_filter( 'bbp_get_topic_freshness_link', 'rew_freshness_no_date_link' , 100, 5) ; 
    	
    function rew_freshness_no_date_link($anchor, $topic_id, $time_since, $link_url, $title) {
    	if (!empty ($topic_id)) {
    	?>
    	<a href="<?php echo $link_url; ?>"><?php echo $title ;?></a> (<?php echo $time_since ; ?>)
    	<?php
    	}
    	else echo 'No topics' ;
    }
    In reply to: access control

    @robin-w

    Moderator

    ok, thanks that helps.

    ONE

    you have set the forum to private in dashboard>forums>all Forums>do-i-quality>edit and visibility options on the right hand side in the forum attributes set to private.

    A private forum is one that is not public, so its existence is also not public. It therefore returns a 404 error to someone not logged in, as bbpress doesn’t know the difference between a user who is not logged in and any member of the public. Once logged in they see the forums. Most users click the remember me button and save passwords in their browser. When not logged in they will not see the existence of the forums. If you want the forums to be visible, then the private groups plugin above will do that.

    TWO

    This is simply a forum with dashboard>forums>all Forums>bylaws>edit and visibility options on the right hand side in the forum attributes set to public.

    THREE

    I’ll look through the wording again to see if I can make it better – I did write it some time ago, and probably due for a review but the settings are in there viz

    Forum visibility:

    Public – Anyone can see these forums
    Private – Only logged in registered users with a forum role can see these forums
    Hidden: Only Moderators/keymasters can see these forums

    Visibility is set for each forum, go into Dashboard>forums> and when you add/edit a forum, you will see visibility options on the right hand side in the forum attributes.

    By default forums are available to be publically viewed. If you set anonymous posting to be on (see 4. Above) then anyone can also post.

    @robin-w

    Moderator

    SORRY – just read you post again, and now I think I understand

    on one site you want the code as above

    on another site you just want a single post, but with title and date, but no link on the date – yes ?

    if so then untested but this should be it

    add_filter( 'bbp_get_forum_freshness_link', 'rew_freshness_no_date_link' , 100, 6) ; 
    	
    function rew_freshness_no_date_link($anchor, $forum_id, $time_since, $link_url, $title, $active_id ) {
    	if (!empty ($active_id)) {
    	?>
    	<a href="<?php bbp_topic_permalink($active_id); ?>"><?php bbp_topic_title(active_id) ?></a> (<?php bbp_topic_last_active_time(active_id); ?>)
    	<?php
    	}
    	else echo 'No topics' ;
    }

    @robin-w

    Moderator

    you’ve lost me now 🙂

    The key line that does the reference is

    <a href="<?php bbp_topic_permalink($topic); ?>"><?php bbp_topic_title($topic) ?> (<?php bbp_topic_last_active_time($topic); ?>)</a>

    This translates as

    <a href="[topic link]">[topic title] ([date])</a>

    which makes both the topic title and the date a single clickable link and the code shows 3 of these.

    I’m not really sure what you are trying to achieve – I had thought you wanted 3 clickable links on both title and date, which is what the above does.

    If you don’t want the date clickable, then do

    <a href="<?php bbp_topic_permalink($topic); ?>"><?php bbp_topic_title($topic) ?></a> (<?php bbp_topic_last_active_time($topic); ?>)

    In reply to: access control

    @robin-w

    Moderator

    I wrote that guide.

    it says

    Private – Only logged in registered users with a forum role can see these forums

    so if you set it to private, then those forums don’t display, so no-one will see that they exist.

    so I’m not quite sure how someone not logged in will see it to click it and get the 404?

Viewing 25 replies - 8,426 through 8,450 (of 14,219 total)