Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 2,601 through 2,625 (of 32,481 total)
  • Author
    Search Results
  • robertherold
    Participant

    I did not do anything! 🙂

    But I was able to solve it with css:

    .bbp-search-results .bbp-topic-author span.topic-author,
    .bbp-search-results .topic-author span.topic-author {
    	display: inline-block;
    }
    
    .bbp-search-results span.topic-author {
    	display: none;
    }

    I hide span.topic-authors from the search results page and left only within .bbp-topic-author and within .topic-author.

    Chuckie
    Participant

    I noticed that when you edit a reply that the “Reply To” combo appears squashed:

    View post on imgur.com

    So I added CSS to widen the select control and then was confused by the values in the drop-down list being truncated. I decided to examine the HTML (without making any CSS changes) and this is what I get:

    `
    <select name=”bbp_reply_to” id=”bbp_reply_to” class=”bbp_dropdown”>
    <option value=”” class=”level-0″>3189 – Introduction to the Text and Visual Editors</option>
    <option class=”level-1″ value=”3226″ disabled=”disabled”>   3226 – Update The</option>
    </select>
    `
    The first entry is complete (although not all visible in the actual control). But the rest are all cropped to just a few letters. If I try other forum replies they are all the same.

    Here is another example:

    View post on imgur.com

    `
    <select name=”bbp_reply_to” id=”bbp_reply_to” class=”bbp_dropdown”>
    <option value=”” class=”level-0″>2692 – Setting up the new forum – Testing and Change-Log</option>
    <option class=”level-1″ value=”2695″ disabled=”disabled”>   2695 – This is a</option>
    <option class=”level-1″ value=”2705″>   2705 – This is a</option>
    <option class=”level-1″ value=”2735″>   2735 – This reply</option>
    <option class=”level-1″ value=”2791″>   2791 – Test ok.</option>
    <option class=”level-2″ value=”2794″>      2794 – Hi Stefano</option>
    <option class=”level-1″ value=”2814″>   2814 – All forums</option>
    <option class=”level-1″ value=”2825″>   2825 – Based on t</option>
    <option class=”level-1″ value=”2828″>   2828 – I have sta</option>
    <option class=”level-1″ value=”2853″>   2853 – Further up</option>
    <option class=”level-1″ value=”2858″>   2858 – Further up</option>
    <option class=”level-1″ value=”2881″>   2881 – Further up</option>
    <option class=”level-1″ value=”2912″>   2912 – Update: I</option>
    <option class=”level-1″ value=”2918″>   2918 – Update: Ch</option>
    <option class=”level-1″ value=”2936″>   2936 – Update: Th</option>
    <option class=”level-1″ value=”2943″>   2943 – I have dec</option>
    <option class=”level-2″ value=”3254″>      3254 – Update: I</option>
    <option class=”level-3″ value=”3324″>         3324 – Update The</option>
    <option class=”level-1″ value=”2950″>   2950 – This is so</option>
    <option class=”level-1″ value=”2961″>   2961 – One final</option>
    <option class=”level-1″ value=”3044″>   3044 – I have upd</option>
    <option class=”level-1″ value=”3051″>   3051 – I added a</option>
    <option class=”level-1″ value=”3052″>   3052 – Implemente</option>
    <option class=”level-1″ value=”3066″>   3066 – Hi Andrew,</option>
    <option class=”level-1″ value=”3067″>   3067 – Hi Simon I</option>
    <option class=”level-1″ value=”3068″>   3068 – Sorry, mis</option>
    <option class=”level-1″ value=”3100″>   3100 – Sorry, mis</option>
    <option class=”level-1″ value=”3112″>   3112 – Three more</option>
    <option class=”level-1″ value=”3136″>   3136 – Updates: I</option>
    <option class=”level-1″ value=”3208″>   3208 – This is a</option>
    <option class=”level-1″ value=”3209″>   3209 – This is a</option>
    <option class=”level-1″ value=”3238″>   3238 – Update: Th</option>
    <option class=”level-1″ value=”3318″>   3318 – Update Whe</option>
    <option class=”level-1″ value=”3343″>   3343 – Update: I</option>
    <option class=”level-1″ value=”3401″>   3401 – Update I h</option>
    <option class=”level-1″ value=”3403″>   3403 – Update Rat</option>
    <option class=”level-1″ value=”3518″>   3518 – Update You</option>
    <option class=”level-1″ value=”3519″>   3519 – Yes, the h</option>
    <option class=”level-1″ value=”3973″>   3973 – [quote quo</option>
    <option class=”level-1″ value=”3974″>   3974 – [quote quo</option>
    </select>
    `
    Why is it restricting the data displayed to just a few letters? I tried to research a reason and couldn’t find one.

    Thanks

    #212507
    levangelista2013
    Participant

    Hi,

    I want to insert a form (with three questions, for example ‘How much free time do you have? How do you spend your free time? What games do you like?’) on one page of my website and have a plugin to create one page linking the let say 20 most recent answers, so that visitors can read the most recent answers given by every other visitor.

    Do you have any suggestion on how to do it or plugins to suggest?

    I tried with BBpress shortcodes, but for there are no shortcodes allowing to collect at once and publish answers to different questions. A solution could be to post all the questions together as the first post of a new topic, and ask visitors to annswer, but there is no a short code such as [bbp-reply-form id=223] allowing visitors to post replies to this, without them needing to see or visit the forum (see discussion at https://bbpress.org/forums/topic/using-shortcode-bbp-reply-form-to-specific-topic/)

    My website https://www.orientamento.it/, I am using Twenty seventeen and BBpress 2.6.5.

    Thanks in advance for your help

    #212506
    mdavidson1965
    Participant

    Hello,

    New to bbPress and have been following the guides and have had a lot of success.

    I do have one question that my searches have not been able to solve.

    I create a page called Forums and added the short code [bbp-forum-index] and that works but it adds a subtitle bbPress Forums to the heading of the page.

    How do I turn that off?

    Example from page:
    Forums

    bbPress Forums

    Seems duplicated to me.

    Sorry if this has been discussed but my searches have come up empty.

    #212502

    In reply to: Change css id’s

    Robin W
    Moderator

    you could use

    wp_dequeue_script ('bbp-default') ;

    to dequeue and then load you own named version

    #212482

    Topic: Change css id’s

    in forum Themes
    infernoprime
    Participant

    Let me first state I am doing this for security in light of all the wordpress sites being hacked. I want to change the #bbpress css ID’s to something like #forum.

    I am not much of a coder so could I ask how I go about this ? or is there an easier way to go about this ?

    #212476
    Chuckie
    Participant

    Fixed:

    input[type="text"]#bbp_topic_title,
    input[type="text"]#bbp_topic_tags {
    	width: 100%;
    }

    This way I don’t affect the checkbox type controls. Now all OK.

    #212475
    Chuckie
    Participant

    I checked the functions.php file, line 353:

    	// Forums
    	$forum_count = ! empty( $r['count_forums'] )
    		? wp_count_posts( bbp_get_forum_post_type() )->publish
    		: 0;

    So this is a bbPress issue, part of the function bbp_get_statistics. Is there anyway for me to correct this logic without modifying the core …?

    #212471
    Chuckie
    Participant

    The reason for the issue is because I have this custom CSS that has a side effect on the check box:

    /* Topic Title */
    input#bbp_topic_title, input#bbp_topic_tags {
    	width: 100%;
    }

    This is causing that check box to take on 100% with instead of 13px like the other check boxes. I need to find a way of being able to make my changes above without causing the side effect to the third check box.

    You see, when creating a topic or reply we have a list of tags in a input box and in that context I want 100% width. But when merging topics we are using the same ID for some reason for tags check box and as a result I have a conflict.

    Is there a way to resolve it? Thanks.

    #212467
    Chuckie
    Participant

    If you are interested, I ended up using EnlighterJS. It has a fantastic WordPress module that is compatible with bbPress and is fantastic. User support has been great via GitHub:

    Enlighter – Customizable Syntax Highlighter

    If you need to show code snippets in your forum then this should be the one to use – hands down.

    robertherold
    Participant

    Hi @robin-w,

    //This function adds the author to the reply
    function bbp_author_display () {
    	if (bbp_get_reply_author_id() == bbp_get_topic_author_id() ) {
    	echo '<span class="topic-author">' ;
    	echo '<ul><li>' ;
    	echo 'Topic Author' ; 
    	echo '</li></ul></span>' ;
    	}
    	else return ;
    	}
    	
    	add_action ('bbp_theme_after_reply_author_details', 'bbp_author_display') ;

    This is a very good code, however, when searching, it puts it on each result. 🙁

    #212432
    Robin W
    Moderator

    the ‘term’ code deletes orphaned and unused stuff in the database. By definition these belong to nothing, so there is no bbpress relationship (or indeed other relationship) that you can select against

    #212425
    Chuckie
    Participant

    Your new code is working fine for “revisions” 🙂

    It turns out that in the backend after I run your code I am left with two revisions. Both of which are forum posts 🙂 Cool .. well done.

    Maybe we can do the same for the terms (tags)?

    Andrew

    #212420
    Chuckie
    Participant

    Hi @robin-w

    Thanks for the revised code which I have yet to try.

    There are two aspects in general to consider with respects to the plugin:

    1. The actual sweeping (which you have been looking at)
    2. The actual stats provided on the plugin page.

    Both ideally need to be addressed. For example, you mention about the tags, but in his backend they are referred to as terms:

    View post on imgur.com

    I think terms are unused_terms in the function you referred to. But as mentioned, for this sweeping change to make sense the stats also need revising so they are not included in the counts or detail lists.

    #212411
    Robin W
    Moderator

    I can’t see an option for tags in the code

    #212410
    Robin W
    Moderator

    Actually, this is the (I hope) correct code for revisions

    foreach ( $query as $id ) {
    $post_parent_id = wp_get_post_parent_id ($id) ;
    $type = get_post_type ($post_parent_id) ;
    if ($type != 'topic' && $type != 'reply' ) 
    wp_delete_post_revision( (int) $id );
    }
    #212407
    Robin W
    Moderator

    if you go into the plugin and find

    wp-sweep.php

    find line 557 which says

    foreach ( $query as $id ) {
    												wp_delete_post_revision( (int) $id );
    }

    and amend to

    foreach ( $query as $id ) {
    $post_parent_id = wp_get_post_parent_id ($id) ;
    $type = get_post_type ($post_parent_id) ;
    if ($type != 'topic' && $type != 'reply' ) 
    wp_delete_post_revision( (int) $id );
    }

    that should do it

    #212385
    Juha Metsäkallas
    Participant

    I have had TinyMCE working, but something seems to have broken it. Unfortunately I don’t know after which update to which plugin this began. Neither the code by AnnieBVT nor the bbp style pack plugin helps.

    Pointers to what to try next appreciated.

    #212384
    Chuckie
    Participant

    I was running a Query Monitor on my site and noted the following:

    Undefined index: latest-user

    wp-content/plugins/bbpress-improved-statistics-users-online/includes/public/class.online.php:229
    bbPress_Advanced_Statistics_Online->allowed_tags()

    So I had a look at the core file at that line and found:

            private function allowed_tags() {
                // Store all of the strings currently replace
                $this->_tags = array(   
                            "%MINS%"                => $this->parent->option['user_inactivity_time'],
                            "%COUNT_ACTIVE_USERS%"  => $this->stats["count"]["active"],
                            "%HOURS%"               => $this->parent->option['user_activity_time'],
                            "%COUNT_ALL_USERS%"     => $this->stats["count"]["inactive"] - $this->stats["count"]["guests"],
                            "%COUNT_ALL_GUSERS%"    => $this->stats["count"]["guests"],
                            "%COUNT_ACTIVE_GUSERS%" => $this->stats["count"]["guestsa"],
                            "%USER_USERS%"          => _n("user", "users", $this->stats["count"]["active"], 'bbpress-improved-statistics-users-online'),
                            "%GUEST_GUESTS%"        => _n("guest", "guests", $this->stats["count"]["guestsa"], 'bbpress-improved-statistics-users-online'),
                            "%ALL_USER_USERS%"      => _n("user", "users", $this->stats["count"]["inactive"] - $this->stats["count"]["guests"], 'bbpress-improved-statistics-users-online'),
                            "%ALL_GUEST_GUESTS%"    => _n("guest", "guests", $this->stats["count"]["guests"], 'bbpress-improved-statistics-users-online'),
                            "%USER_RECORD%"         => $this->most_users( "record" ),
                            "%USER_RECORD_DATE%"    => $this->most_users( "date" ),
                            "%USER_RECORD_TIME%"    => $this->most_users( "time" ),
                            "%LATEST_USER%"         => $this->stats["latest-user"]
                        );

    The offender is:

    "%LATEST_USER%" => $this->stats["latest-user"]

    So I tried to find where latest-user is also used and only found one place in all the files, here:

            private function stats_extra( $activity ) {
                
                if( $this->parent->option["bbpress_statistics"] == "on" ) {
                    // Add the bbPress Statistics
                    $activity["bbpress"] = $this->get_formatted_statistics();
                }
                
                if( $this->parent->option["last_user"] == "on" ) {
                    // Get the HTML latest usser
                    $activity["latest-user"] = $this->get_latestuser( true );
                }
                
                if( $this->parent->option["most_users_online"] == "on" ) {
                    // Get/set the most users ever online, users the active online users
                    $activity["most-users"] = $this->get_mostusers( $activity["count"]["active"] );
                }
                
                return $activity;
            }

    This led me to:

                // Create the statistics variable
                $this->stats = $this->stats_extra( $activity );

    So this warning looks like a false positive to me. Thoughts?

    #212367
    Robert Hewitt
    Participant

    For the part of my website containing bbPress, I don’t want the main navigation menu to show. To achieve this, I enter CSS code on the main web page where [bbp-forum-index] is displayed.

    The CSS code does its job as far as the first page is concerned – that is the page where the forums are listed.

    However, if you select a specific forum to look at, this takes you to a new page. Unfortunately, on the new page, the main navigation menu is showing. So the CSS code has not done its job here.

    Any advice on how to solve this problem would be much appreciated!

    #212363

    In reply to: Empty forum index

    Robin W
    Moderator

    you have in-line css code that says

    .bbp-forums {
     display:none
    }

    which means they don’t display, but the forum is there on the page.

    I cannot see what is setting that, and in-line code cannot be overridden.

    It may be your theme, or another plugin, so a setting you have in your theme or another plugin.

    Have you added any plugins lately, or updated theme or plugins ?

    #212359
    Chuckie
    Participant

    If you know how to do the code in php you might be able to build a URL that effectively jumps to that reply in the topic (just like you can see on the standard forum pages).

    #212356
    thevisas
    Participant

    Hi,
    Nothing is displayed in a page when using bbp-forum-index shortcode.
    Tried saving permanent links, but the issue is still present.
    The same happens when creating new page with bbp-forum-index shortcode.
    Not sure when the issue started, but probably since 2.6 update.
    Current bbpress version is 2.6.5.
    The URL is https://www.thevisasofoz.com/australia-migration-forum/

    #212344

    In reply to: bbPress + Elementor

    Kamrujjaman kanak
    Participant

    Hello, I use Elementor pro and element pack pro But the problem is going on when I can showing the forum single post then only possible to show the post by id but I can show all of the specific posts in my Elementor forum single post template I want to show all of the specific posts in this page.

    Here is the shortcode for showing the single post by id [bbp-single-topic id=$topic_id]
    But I can show all of the single posts without using id Is it possible can I give some solution, please

    Madam @fabwintle Please give me a great solution, please

    Thanks
    only4kanak

    #212343
    Sadegh Hosseini
    Participant

    Hi,
    there is a shortcode to display a single topic:
    [bbp-single-topic id=$topic_id]
    and there is a function to find last reply of the topic:
    <?php bbp_last_topic_reply_permalink ?>
    Now I want to create a shortcode to show the last reply of the topic.
    for example:
    [bbp-single-topic-last id=$topic_id]
    Please tell me how can I do this.
    Thanks

Viewing 25 results - 2,601 through 2,625 (of 32,481 total)
Skip to toolbar