Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 5,501 through 5,525 (of 32,522 total)
  • Author
    Search Results
  • #181486
    Stiofan
    Participant

    i had to do this today for a few hours, only hidden with CSS and message displayed but might help someone:

    // put forum in read only mode
    add_action('bbp_theme_after_reply_form','gd_bbp_read_only_mode');
    add_action('bbp_theme_after_topic_form','gd_bbp_read_only_mode');
    function gd_bbp_read_only_mode(){
    
    	?>
    <style>
    	fieldset.bbp-form{ display: none;}
    </style>
    	<div style="background: red;color: white;"><h2>The forum is currently in read only mode while we perform some maintenance, this should only take a few hours.</h2></div>
    <?php
    }
    phil49
    Participant

    Hi

    I’ve been reading many posts on this forum and tried out many proposed solutions but to no avail up to now 🙁

    I first started with the copy of an unmodified and renamed in “bbpress.php” “page.php” file at the root of my theme folder, then with another one with a slight modification of the code substituting the class “content-area”with “content-area-wide”, I then tried another method creating a subfolder in my theme and copying the above mentioned file as well as a modified “style.css” file.
    The code was simply :
    .content-area-wide {
    float: left; margin-right: -100%; width: 100%}


    @import
    url (“../twentyseventeen/style.css”);

    Unless the code is not correct or the path or it’s syntax either, of course it didn’t work either.

    Surprisingly, the page listing all the forums is using almost the full width, and looks exactly what I’m looking for anyway but as son as I get in one of the forums they are displayed as if on one column way and aligned on the left.
    Same thing for the abovementioned page if I go back to it unless I refresh it…
    I should point out that I don’t use or have any sidebar for these pages and I’m not concerned by this kind of problem like many other people!
    As I’m not a master of the code, could anybody help me and describe each step to solve this frustrating issue so that I can follow each step and not guess intermediate steps considered as obvious are easy by the most learned guys !?

    Thanks so much for our site subscribers

    Regards,

    Philippe

    #181464
    Robin W
    Moderator
    #181446
    en10
    Participant

    OK, I found the code who make this issue.

    function SearchFilter($query) {
        if ( $query->is_search && !is_woocommerce() && !is_admin()) {
            $query->set( 'post_type', 'post,page' );
        }
        if ( function_exists( 'is_woocommerce' ) ) : 
            if ( $query->is_search && is_woocommerce() && !is_admin()) {
                $query->set( 'post_type', 'product' );
            }
        endif;
        return $query;
     }
    add_filter('pre_get_posts','SearchFilter');

    I put this function in functions.php because without that I can’t search on my blog AND Woocommerce with the plugin Releanssi).

    But what the problem with this function?

    EDIT: I found a topic and the fix of @robin-w

    Topics not appearing in forum

    I will try this fix very soon.

    #181412
    yoyoma1999
    Participant

    I am using WordPress 4.7.2 and bbpress Version 2.5.12. I have tried the code as mentioned in previous post. However, it doesn’t work. Could any generous guys can help me?

    My main objective is to set spectator to have ability to post/edit a post. That’s it.

    1. Is there any other easiest way to do it?
    2. If no, any change besides the false/true value I suppose to amend?
    3. Where should I put the code, only capabilites.php?

    I wish someone can show me step by step solution. Thank you so much.

    #181408
    dropshot
    Participant

    Thanks for your reply.

    This might seem obvious for the creator of bbpress. But it really isn’t. I think you need to drop the word “partner” cause that is really confusing.

    Method 1:
    This doesn’t do anything other than adds a page that you can add to your navigation. You could instead basically add a custom link to your navigation because the page itself isn’t displayed since you have the same slug as you set for forum root index. The default bbpress index will be displayed. Having a wordpress-page is just confusing since nothing added to that page is displayed.

    Method 2:
    This method doesn’t mention the slug at all so I presume the slug here is different then the one set as forum root index. Fine. Name your page anything and add anything along with the shortcode [bbp-forum-index]. There you have it. You think…

    You think you have customized your forum index page. But in fact that page is just a non-bbpress page that happens to have bbpress content in it. How so?

    1) Your breadcrumb forum index link will still display the default index page.

    2) And if you use the bbp style pack to add login-logout-buttons to your navigation it won’t recognize your custom index page as a bbpress-page. (The buttons won’t display when option is set to only display on forum pages)

    Maybe it’s just me, but If I create my own index page, of course I want that page to be the index page linked to in the breadcrumbs as well.

    So. I’m struggling with the word “partner” here. In my mind it says a wordpress page can partner with bbpress and act as the forum index page. As a replacement not as an addition. It can’t be that you should have TWO different index pages, can it?

    So, how do I create a custom forum index page that is recognized as a forum page and acts as the forum index page in the breadcrumbs?

    Cheers!

    #181405
    talonfl1
    Participant

    Hello, using WP 4.7.2, with BBPress sort topic relpies 1.0.3, I’ve set the form sort options to descending, along with forums and topics sidebar to descending. when I view Forums or Topics from their main pages the plug in works as advertised, however when I use the short code [bbp-single-topic id=1286] what is displayed is the topic but not sorted correctly.

    REEF Webcam


    should have newst post on top.

    #181391
    Robin W
    Moderator

    see

    Step by step guide to setting up a bbPress forum – Part 1

    item 3

    method 2 lets you add text before (or after) such as

    “welcome to our forums….”

    #181387
    ddevries
    Participant

    I was using method 1 with postname. My forum root is called “forums” in settings. When that didn’t work, I tried #2 by putting a shortcode in. Still didn’t work.

    I noticed last night that the individual forums show fine when I go directly to them:
    http://livelovecards.com/forums/forum/cardstock/
    It’s not pretty, but at least it’s formatting.

    So I guess it’s just the list of forums that isn’t showing correctly. Is there something different about this page?

    Thanks for your help, Robin. I appreciate it more than you know. 🙂

    Darlene

    #181383
    dropshot
    Participant

    Customize your Forums root. Partner with a WordPress Page and use Shortcodes for more flexibility.

    What does this mean??

    I’ve set the forums root to “forums”. Then I’ve created a WP-page with slug “forums” and included some shortcodes.

    The WP-page is ignored, so content displayed on /forums is the bbpress default index page.

    What does this mean: “Partner with a WordPress Page and use Shortcodes for more flexibility.”??

    How do I replace the default index with a WP-page?

    #181379
    Robin W
    Moderator

    I suspect it is a theme issue, it seems to be rendering as a paragraph.

    what method in item 3 below are you using

    Step by step guide to setting up a bbPress forum – Part 1

    #181369
    lijitimit
    Participant

    Old topic to be chiming in on but this helped a lot, thanks @tharsheblows!

    I changed it up to simply add buttons to the pages instead of the login form, and made sure that upon login, it redirected back to the topic or forum.

    //this adds the login and register links underneath on a single topic so someone can leave a reply. It uses the same logic as form-reply
    function mjj_new_reply_login(){
    	if( !bbp_current_user_can_access_create_reply_form() && !bbp_is_topic_closed() && !bbp_is_forum_closed( bbp_get_topic_forum_id() ) ){ ?>
    		<a href="<?php echo wp_login_url( get_permalink() ); ?>" title="Login">Login</a>
                    <a href="<?php echo wp_registration_url(); ?>">Register</a>
    <?php
    	}
    }
    
    add_action('bbp_template_after_single_topic', 'mjj_new_reply_login');
    
    //this adds the llogin and register links underneath on a single forum so someone can start a topic. It uses the same logic as form-topic
    function mjj_new_topic_login(){
    	if( !bbp_current_user_can_access_create_topic_form() && !bbp_is_forum_closed() ){ ?>
    		<a href="<?php echo wp_login_url( get_permalink() ); ?>" title="Login">Login</a>
                    <a href="<?php echo wp_registration_url(); ?>">Register</a>
    <?php
    	}
    }
    
    add_action('bbp_template_after_single_forum', 'mjj_new_topic_login');

    I personally did them as buttons, if you have a .button class just add class="button" between <a and href=.

    Hope that helps someone in the future.

    #181340
    yoyoma1999
    Participant

    I am using WordPress 4.7.2 and bbpress Version 2.5.12. I have tried the code as mentioned in previous post. However, it doesn’t work. Could any generous guys can help me?

    My main objective is to set spectator to have ability to post/edit a post. That’s it.

    1. Is there any other easiest way to do it?
    2. If no, any change besides the false/true value I suppose to amend?
    3. Where should I put the code, only capabilites.php?

    I wish someone can show me step by step solution. Thank you so much.

    #181333
    sjc
    Participant

    I had a similar need – to show the user’s bio on their replies – so sharing my solution here, a simple function created after having a look at this nifty little plugin by Robin W.

    function show_bio_bbp_replies () {
    $user_id = bbp_get_reply_author_id( $reply_id );
    $usermeta = get_userdata( $user_id, 'description' );
    echo '<p class="bbp-reply-user-bio">'.$usermeta->description.'</p>';
    }
    add_action ('bbp_theme_after_reply_author_details', 'show_bio_bbp_replies');
    #181331
    Robin W
    Moderator

    you may need to add this to your functions file to get it for particpants

    add_filter (‘pw_bbp_parse_shortcodes_cap’ , ‘publish_topics’ ) ;

    #181330
    Robin W
    Moderator

    This used to work, see no reason why it should not still be fully functional!

    https://wordpress.org/plugins/bbpress-do-short-codes/

    #181322

    Topic: Custom topic form

    in forum Plugins
    cskasler
    Participant

    Hello bbPress Profis,

    i hope, that i can find a solution or you can help me…

    i’m searching for a plugin to make different forms for different topics.

    for example: topic name web designers:

    form to post:
    – Name:
    – City:
    – Experience:
    – etc…

    other topic name: Job
    topic form:
    Company name:
    Job title:
    Job description:
    Salary:
    Start date:
    etc…

    And i would like to get a pre-formatted post…

    is there a plugin what can help me?

    I’m not a coder, so i can make only smaller changes, i use plugins to build my own sites, but in this case i would need a lot of different user made content and this would be a cool solution, to don’t need 20 different plugins to make my site slow.

    #181311
    yo35
    Participant

    Hi,
    Is it possible to use WordPress shortcodes in bbPress posts? (I mean either native WordPress shortcodes such as [caption][/caption], [gallery ...], or shortcodes defined by third-party plugins).
    To be more precise, I’m the author of a WordPress plugin that allows to insert chess diagrams and/or chess games in WordPress posts/pages (see https://wordpress.org/plugins/rpb-chessboard/). I would like to extend to have chess games/diagrams in bbPress posts.
    Thank you beforehand.

    #181297
    lijitimit
    Participant

    I am looking to change the buttons in the default text editor to those that appear in the fancy visual editor. My audience is overseas and are familiar with the “microsoft word” style of buttons. I have tried Enabling the visual editor however am experiencing issues with inline replies. I actually prefer the default text editor as it strips out copied html, so really I just need so fancy buttons. Can I do so with css or create a filter to call the other toolbar instead of qt_bbp_topic_content_toolbar ?

    #181278

    In reply to: SDK/API

    Barry
    Participant

    Hi @fhasst1,

    (Let me start by noting it could very well be that you already know this—but something in your post made me want to call it out just in case you weren’t aware.)

    bbPress runs on top of WordPress. That’s important because it means if a user has logged into your (WordPress-driven) site/app then, by extension, they will have logged into the forum (insofar as bbPress will realize they are an authenticated user and will be able to identify them) … no need for a separate login.

    Also, I think it’s worth calling out the fact that when it comes to adjusting the way bbPress behaves, or building some new forum feature, there is a really quite extensive set of functions, hooks and methods available to you that make it a really awesome platform to build on.

    codex.bbpress.org

    tenabrae
    Participant

    All the answers I can find to this question seem old and the solutions don’t work.

    I’ve tried copying my theme’s full width template to my child theme and naming it bbpress.php
    I’ve tried copying bbpress.css to my child theme and adding the CSS for article width to it and adjusting it to 100% (which works fine in the theme if I want to change ALL my content to 100%)

    How can i get JUST my bbPress generated pages to be full width ? Currently i’m linking straight to the forums, should I be putting them in full width pages and generating them with short code instead as a workaround ?

    Note: the bbpress.php override works fine but I can’t figure out how to override the .css that’s keeping the forum box small.

    /* Arrange posts into grid structure on archive pages */
    .archive article,
    .blog article,
    .search article {
    -moz-box-sizing: border-box;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
    float: left;
    margin-bottom: 3.33333%;
    padding-left: 1.11111%;
    padding-right: 1.11111%;
    width: 33.33333%;
    }

    #181272
    Robin W
    Moderator

    your theme is setting the css blockquote to 171.4%

    if your theme has a custom css area put this into it

    blockquote {
    font-size: 100% !important;
    }
    #181263
    rainbowint
    Participant

    I am on WordPress 4.7.2 and bbPress 2.5.12 and suddenly this combination stopped working layoutwise. bbPress is just outputting content (text), but without any tables or any other formatting.

    The glitch happens with all WordPress themes not just a particular theme.
    I am using “bbPress Tweaks” to render the output in my theme. Deactivating bbPress Tweaks did not solve it.

    Unfortunately we use this website for internal communications, so can’t just put a link here, you have to have an active user to login.

    Therefore I uploaded some pictures of what is happening:
    https://www.rainbow-international.de/screen.jpg
    https://www.rainbow-international.de/screen2.jpg

    I tried everything disabling plugins, downgrading WordPress, downgrading bbPress itself. But I can’t get the older versions of bbPress to run. Something in the code is crashing -> white page. So I am stuck with 2.5.12.

    Thank you in advance!

    #181237
    Stephen Edgar
    Keymaster

    Oh, that is strange, can you check the contents of the following file for me on your beta 2:

    bbpress/includes/admin/converter.php#L653

    That line should read $max_index_length = 191;

    One other thing, you might need to run the “reset forums” tool first from:

    /wp-admin/tools.php?page=bbp-reset

    That will delete that old table (and *all* your forum data) and make it available to be created in the updated format.

Viewing 25 results - 5,501 through 5,525 (of 32,522 total)
Skip to toolbar