Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 1,676 through 1,700 (of 32,438 total)
  • Author
    Search Results
  • #220137

    In reply to: Username box different

    Robin W
    Moderator

    try adding this to the custom css part of your theme

    #bbpress-forums fieldset.bbp-form input[type="text"] {
    	height: inherit;
    }
    #220127
    Robin W
    Moderator

    you either want

    dashboard>settings>forums>anonymous if you want anyone to be able to post

    or add registration – bbpress uses wordpress registration, so anyone of then methods here will work.

    https://www.wpbeginner.com/beginners-guide/how-to-allow-user-registration-on-your-wordpress-site/

    there is also a bbpress registration login which includes registration and bbpress shortcodes

    [bbp-login] – Display the login screen.
    [bbp-register] – Display the register screen.
    [bbp-lost-pass] – Display the lost password screen.

    #220116

    In reply to: Shortcodes Forum

    dnfoz45
    Participant

    In the forum session, I can’t add shortcodes to the forum I created, and I can not edit it with Elementor

    blob:https://imgur.com/174e53bb-262d-4fde-8fed-528c34072e20

    #220087
    jeppot
    Participant

    Hello, I have installed BB press but my WP theme makes the font size very small.
    Is there any way to cutomize the BB press Fourm? With another plug in? I know nothing about CSS but I know where to paste custom CSS codes…

    This is how it looks:

    screen shot

    #220084

    In reply to: Update Topic On Reply

    Robin W
    Moderator

    ok, I now understand what you want.

    Put this in your child theme’s function file –

    ie wp-content/themes/%your-theme-name%/functions.php

    where %your-theme-name% is the name of your theme

    or use

    Code Snippets

    add_action ('bbp_new_reply_post_extras' , 'rew_update_topic') ;
    add_action ('bbp_edit_reply_post_extras' , 'rew_update_topic') ;
    
    function rew_update_topic ($reply_id) {
    	$topic_id = bbp_get_reply_topic_id( $reply_id );
    	$topic_data = apply_filters( 'rew_update_topic', array(
    		'ID'           => $topic_id,
    	) );
    
    $topic_id = wp_update_post( $topic_data );
    }
    #220064

    Topic: Shortcodes Forum

    in forum Installation
    dnfoz45
    Participant

    I know I can add ShortCodes to the pages, but can I add them in the forums section? I add and nothing happens

    #220055
    acb93
    Participant

    About the “hidding stuff” the point is the [bbp-topic-index] not have the same header than the [bsp-display-topic-index] shortcode.

    [bbp-topic-index] have the “estandar bbpres header”

    [bsp-display-topic-index] have the image you are using in the page for the header (which is better)

    Regards.

    Adrià Calendario.

    #220053
    Robin W
    Moderator

    ok, that is part of the issue.

    I’m still looking, but whilst I think [bbp-topic-index] will protect against users seeing posts they shouldn’t, you might just want to check for your site.

    I added an extra filter on [bsp-display-topic-index] that does a double check, and this is causing the issue.

    I don’t actually think that filter is needed, but I am doing some extra checks to make sure, so just make sure [bbp-topic-index] is hiding stuff it should until I confirm.

    haddlyapis
    Participant

    great @robin-w , this is very useful.
    Unfortunately, I just copied and pasted your code into my functions.php file and it didn’t work.
    Took me 3 hours to figure out that the variable is spelled incorrectly within the bbp_get_spectator() function. Once I corrected this, it works!!
    Thx for your prompt help. All the best. This topic is now closed.

    #220041
    Robin W
    Moderator

    hmmm…interesting..

    the shortcode [bsp-display-topic-index] is from my stylepack plugin, whereas [bbp-topic-index] is from bbpress.

    If this was working ok, I’ll need to work out what has changed to make it not work 🙂

    #220040
    acb93
    Participant

    OK, I found the solution…

    Normally I use this shortcode:

    [bsp-display-topic-index]

    It fixes with this shortcode:

    [bbp-topic-index]

    So.. OK i found a solution but I really want to know what was the problem, I am just curious right now… If somebody finds an explanation, please post it!

    Regards.

    Adrià Calendario.

    #220032
    cristofayre
    Participant

    I set up my forums with the help of “bbp style pack”, but unfortunately had to deactivate it as it kept causing fatal errors stopping me from logging in, and sometimes throwing errors in admin panel. But now something weird has happened to the layout. It seems to be “double spacing” lines. I have removed bbpress and bbp style pack from the plugin area, and then reinstalled the plugins … but the same error persists.

    I have looked at the code, and there doesn’t seem to be any clues; all entries are still within their

    <ul id="bbp-forum-447" ...
    </ul>
    <p><!-- #bbp-forum-447 --></p>

    So no clues there. Anyone any ideas?

    double spacing error on page

    Robin W
    Moderator

    Sorry, I’m being brain dead this afternoon.

    Spectate is a capability shared by many roles, so the code above is rubbish !

    Try this

    function forum_user_is_spectator(){
    if ( is_bbpress() && is_user_logged_in() ) {
        $user_ID = get_current_user_id() ;
        $role = bbp_get_user_role( $user_id );
        if ($role == bbp_get_spectator_role()){
           wp_enqueue_script( 'spectator-js', get_template_directory_uri() . '/js/spectator.js', array(), false, true);
           }
        }
    }
    Robin W
    Moderator

    you add action is right, and I’d have this as the function (not tested!)

    function forum_user_is_spectator(){
    if ( is_bbpress() && is_user_logged_in() ) {
       $User_ID = get_current_user_id() ;
    	$Spectator = (!empty(current_user_can( 'spectate' )) ? 1  : 0) ;
        if ($Spectator){
           wp_enqueue_script( 'spectator-js', get_template_directory_uri() . '/js/spectator.js', array(), false, true);
           }
        }
    }
    haddlyapis
    Participant

    Hi there,
    Due to a high number of spambot registrations, any user who registers for the forum initially gets “Spectator” rights. Once I check (usually within 12-24 hours) that they are not spam, I change them to “Participant”.
    Some people get annoyed that they cannot post immediately. And I would like to create a popup banner that appears when users login for the first time but cannot post. I am capable of the JS and the CSS, but not quite the PHP.

    Basically, I want to enqueue a JS file if the user is a “spectator” and is “logged in”.

    Could you please advise how to complete my function (hopefully just the commented parts), which will go in the functions.php file, and what add_action arguments should be applied if I am wrong?

    function forum_user_is_spectator(){
    if ( is_bbpress() && is_user_logged_in() ) {
        //$User_ID = get user ID
        //$Spectator = find out if User Has Spectator rights
        if ($Spectator){
           wp_enqueue_script( 'spectator-js', get_template_directory_uri() . '/js/spectator.js', array(), false, true);
           }
        }
    }

    add_action('wp_enqueue_scripts', 'forum_user_is_spectator');

    thx in advance

    #219998
    cristofayre
    Participant

    Having done a little digging in the CSS that “bbp style pack” creates, I THINK I have isolated the buttons to the class of

    #bbpress-forums.button{
    background-color:#9e9e9e
    color: 000000
    }

    … which is the correct grey / black that the editor buttons SHOULD be. But it seems that something after that is picking up the theme colours, and setting it to those. (Unless there is some code earlier that is !IMPORTANT! that is setting it.

    Also, “bbPress” seems to have a mind of it’s own, disregarding settings made within WordPress. For example, the editor has been set up with two rows of buttons … but “bbPress” will only display the default 12 or 13 buttons in one row, (and not even those match what’s been set up elsewhere in WordPress) The same plugin that sets up two rows of buttons has an option with “Don’t use visual editor in bbPress” Guess what … “bbPress” loaded the visual editor anyway.

    Another plugin states “Switch this on to use the membership profile rather than the bbPress profile” Turn that on, and … rather than link to the profile, the link shows “#” so that it simply reloads the same page. And the big profile button (beside “Create Topic”) STILL jumps to the bbPress profile !!

    OK, appreciate that some of those things are bbPress not accepting the settings of the other plugins … but it gets somewhat annoying when you bat your head against a brick wall all day!

    #219989
    Robin W
    Moderator

    that code has been moved to content-single-topic.

    Can you just recheck your settings in

    dashboard>settings>forums and look at subscriptions and favorites are set – I have no reason to doubt except past experience 🙂

    If so, you may need to upgrade in

    dashboard>tools>forums>upgrade forums

    cristofayre
    Participant

    On my post / pages, the Tiny MCE Visual Editor displays as it should, ie a row (or two) of grey and black icons, allowing user to select align right / align left / justify etc. (I mention that in case anyone thinks I’m referring to the ‘basic’ buttons as shown on this forum posting options) As such, I don’t think it’s the theme / plugins causing the problem.

    However, once “bbPress” fires up, the buttons go crazy, and ‘inherit’ the CSS styles from the theme. (The vendor who created the “WP-Edit” plugin says in an article that some themes are DESIGNED so that the buttons change to the theme colours; I want to keep the default colours)

    In another post, RobinW suggested the “bbpress-pack” which has done a great job getting the forum set up the way I want … but it doesn’t redress the button problem.

    I am using:

    Theme: dashscroll
    Plugins: ARMember (membership plugin)
    bbPress
    WP-Edit (to change the buttons on the editor)

    I THINK there is code I can place somewhere that effectively filters this settting so that it doesn’t take effect … but what I need to filter for, or the code to use I have no idea.

    NB: The “Visual” and “Text” buttons also seem to be inheriting the font size / padding of theme as it is also displacing the text on said buttons.

    https://atomz.pro/tec-tocc/Forums/forum/atomz-apps/product-directory/

    #219964
    BackuPs
    Participant

    Because of different html code (using tabs in html) the space is not the same in one widget! And the items do not vertically align correctly. See image and link

    bbpress-forum-lia

    bbpress-html

    BBpress Forum

    #219954
    Robin W
    Moderator

    I am just a bbpress user who helps out here – I have no power to change code. I can log a defect, but I’ll only do that if I can also see an issue

    #219948
    BackuPs
    Participant

    Its in a test install local host install…

    Will set up a demo for you tomorrow. Please change the code as line 797 in the same file. As the list elements do not align vertically.

    #219930
    BackuPs
    Participant

    Please change forum widget li a code at line 550 from

    					<a class="bbp-forum-title" href="<?php bbp_forum_permalink( $widget_query->post->ID ); ?>">
    						<?php bbp_forum_title( $widget_query->post->ID ); ?>
    					</a>

    to

    <a class="bbp-forum-title" href="<?php bbp_forum_permalink( $widget_query->post->ID ); ?>"><?php bbp_forum_title( $widget_query->post->ID ); ?></a>

    Because it leads to unwanted spaces and tabs in the html and there is no filter to strip them out.

    make it the same and consistent as widget_display_topics where li a at libe 797 is done the correct way.

    When using both widgets in a same sidebar below each other the li a elements do not align in a vertical way.

    Thank you

    #219928
    Robin W
    Moderator

    This simply allows you to create a page with some other content as well, for instance

    Welcome to our forums - debate is free here, but please be kind to each other
    [bbp-forum-index]
    #219927
    Ricsca2
    Participant

    By default the forum can be reached on the forums page which is not actually a page.
    However, you can also create a page with the shortcode [bbp-forum-index] .
    What is the shortcose for if the forum page already exists?
    Thank you

    #219888

    In reply to: Archive old topics

    Robin W
    Moderator

    ok, so if you are happy to move them to a different forum, then contact me via

    Contact me

    and I’ll give you some code

Viewing 25 results - 1,676 through 1,700 (of 32,438 total)
Skip to toolbar