Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 476 through 500 (of 32,468 total)
  • Author
    Search Results
  • #238290
    kelixirr
    Participant

    Hi, I want to highlight the first topic that the user creates to ask his doubts so that it can stand out from other replies. I tried this code but I don’t know what’s missing here. I could not find the CSS classes for the first topics in their documentation.

    .bbpress-forums .bbp-topics:first-child {
    	
    	background-color: #000;
      font-weight: bold;
    }

    Additionally, I want to highlight the best reply either by changing it’s color or by pinging it to the main topic so that new visitors won’t have to check every other reply. It will be helpful for the new users.

    is there any way I can solve these two issues using css:

    1. Highlight the first issue so that it stands out from the crowd of replies
    2. Highlight or ping the correct/solution contained reply thread so that new visitors won’t have to read everything.

    #238277

    In reply to: Forum

    Robin W
    Moderator

    The ‘Forums’ heading is created by your theme.

    which method in the below are you using to create the forum page?

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

    #238268

    Topic: Forum

    testdevs
    Participant

    we need to add a shortcode on this page https://www.clevercafecompany.com.au/chats/ above ‘Forums’ heading.
    Is it possible to add through in function.php?

    #238253
    markwilliams21
    Participant

    Certainly! In the WordPress REST API, creating a new topic and assigning it to a parent forum involves utilizing the wp/v2 endpoints for both forums and topics. To achieve this, you can follow these steps:

    ### 1. Get the Forum ID
    Firstly, you’ll need to know the ID of the parent forum to which you want to assign the new topic. You can retrieve this ID by making a GET request to the forums endpoint, typically /wp/v2/forums.

    For example:
    `http
    GET /wp/v2/forums
    `

    ### 2. Create a New Topic
    Make a POST request to the topics endpoint, usually /wp/v2/topics, providing the necessary parameters including title, content, and forum to link it to the specific forum.

    For example:
    `http
    POST /wp/v2/topics
    Content-Type: application/json

    {
    “title”: “New Topic Title”,
    “content”: “Content of the new topic”,
    “forum”: <forum_id>
    }
    `
    Replace <forum_id> with the ID of the parent forum retrieved from step 1.

    ### Example Using cURL
    Using cURL, the process might look something like this:
    `bash
    curl -X POST -H “Content-Type: application/json” -d ‘{“title”:”New Topic Title”,”content”:”Content of the new topic”,”forum”:1}’ https://yoursite.com/wp-json/wp/v2/topics
    `
    Replace https://yoursite.com with your actual WordPress site URL and 1 with the ID of the desired forum.

    Remember to authenticate the API request if your WordPress site requires authentication for creating new content.

    This approach allows you to create a new topic and assign it to a parent forum via the WordPress REST API. Adjust the endpoint URLs and parameters as needed based on your specific WordPress configuration.

    #238241
    gozazomo
    Participant
    #238219
    Robin W
    Moderator

    put this in the custom css of the style pack plugin.

    #bbpress-forums span.bbp-admin-links a, #bbpress-forums span.bbp-admin-links {
    	font-size: 13px;
    }
    #238180
    getfree
    Participant

    I have 3 categories (main forums) and a bunch of sub forums. I would like to display 1 main forum/category, the blogs, separate from the rest on the front page, but I don’t find the option to do it.

    This only works for specific forums, not categories [bsp-display-topic-index show=”5″ forum=”10,11,12]
    and this style adds a different style (the original) that I don’t want [bsp-display-topic-index].

    So, how to display one or more categories using short templates?

    #238178

    In reply to: Export/Import

    Robin W
    Moderator

    sort of…

    It is doable, but requires a series of steps and some code.

    I am trying in spare time to get this into a workable solution, but needs more work.

    #238165
    Robin W
    Moderator

    without a pluguin

    Custom Capabilities

    with a plugin

    bbp style pack

    once activated go to

    dashboard>settings>bbp style pack>roles

    #238087
    Robin W
    Moderator

    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

    #238086
    rpuskarcik
    Participant

    So where does the “add_shortcode )’… go?

    #238052
    Robin W
    Moderator

    try adding this to custom css

    # Mobile
    only screen and (min-width: 480px) {
    fieldset.bbp-form p {
    width : 20px ;
    }
    }
    #238049
    hemantmalav
    Participant

    Is there a way to link post and topic tags and show post and topics associated with the tag on a single page in front end?

    I tried doing it using [bbp-single-tag id=$tag_id] short code on post tag page but I couldnt fetch the topic tag id in runtime. Is there a shortcode like [bbp-single-tag slud=$slug], I can fetch the slug from the post tag URL in runtime.

    #238042
    Robin W
    Moderator

    ok, so that is a page with a shortcode that tends to suggest you do not have the bbpress plugin active

    #238008
    Robin W
    Moderator

    ‘how to quote a post or comment without using any plugin.’

    you could try using a Ouija board, but otherwise you will need code in either theme or plugin.

    You could pay someone to cut some theme code, but of course that won’t be maintained unless you take out some sort of maintenance agreement with the author.

    Adding a plugin will not make any difference in load time that anyone would notice (or indeed most software could time), and if you use caching software nothing measurable at all over theme code.

    bbp style pack

    has a quotes section

    #238002
    dianaringer2018
    Participant

    Hello,

    I am trying to follow the step-by-step instructions, and I am still having trouble displaying the main forum page. I am trying to use method 1. I checked and verified the settings.

    I added some test forums and topics, and I can see them in the backend.
    Forum Root = Forums
    Permalink structure is set to POSTNAME
    Category | Tag base left blank (default)

    I created a page called Forums and nothing displayed.
    I tried adding the shortcode and still nothing appears.

    I am referring to: https://codex.bbpress.org/step-by-step-guide-to-setting-up-a-bbpress-forum/#3-%c2%a0creating-a-forum-page

    Page Links: https://bkswathq.com/forums
    Wordpress : 6.3.2
    bbp Version 2.6.9

    Thanks in advance.
    Fills silly to be stuck so early on in the process.

    #237995
    chrisej93
    Participant

    Looks like I’ve fixed it. I had some code to change bbpress usernames in my functions.php file, which I have deleted.

    norcom41
    Participant

    In a bbPress forum I want to prevent participants from creating topics but allow replies. In searching the Internet I found code examples from which I selected some to build a plugin. I know a little PHP but WordPress is like a “black box.”

    add_action(‘wp_loaded’,’modify_participant’);

    function ‘modify_participant'()
    {
    add_filter(‘mod_participant’, ‘upd_participant’);
    }

    function upd_participant($role,$caps)
    {
    $role = bbp_get_participant_role();
    $caps = modify_capabilities($role);
    }

    function modify_capabilities($role)
    {
    return array(

    // Topic caps
    ‘publish_topics’ => false,
    ‘edit_topics’ => false,
    ‘edit_others_topics’ => false,
    ‘delete_topics’ => false,
    ‘delete_others_topics’ => false,
    ‘read_private_topics’ => false,

    // Topic tag caps
    ‘manage_topic_tags’ => false,
    ‘edit_topic_tags’ => false,
    ‘delete_topic_tags’ => false,
    ‘assign_topic_tags’ => false
    )
    }

    For instance the WP loaded hook causes it to run once at the start which should call those functions to initialize things. Is an add_filter also executed at that time to complete initialization? Then the black box proceeds with the bbp_get_parcipant_role routine so that the capabilities array elements can be updated. I read that WP filters always expect an object to be returned. It seems that these wouldn’t be permanent but just temporary in memory for executing that page. However my suspicion is that more coding would be necessary because that would be too much to depend on the black box for.

    #237913

    In reply to: wpForo to bbPress?

    Driven 2 Services
    Participant

    I’ve handled a few with code I wrote myself. It’s very possible to do. 🙂

    #237902
    Jessparvin
    Participant

    I used shortcode to only display one forum in a Learndash course I created. I have older forums that are only assigned to other courses. But now the forum displayed in my new course is showing topics/ threads from older forums. I cannot for the life of me figure out why they would be appearing here! I don’t want customers in this course to see older threads from other courses.

    #237796
    Robin W
    Moderator

    I appreciate that you are feeling a sense of frustration.
    But both WordPress and bbpress are free software, and come with free support offered by volunteers.
    In effect you are asking someone to take their free time to help you, and then complaining that it is not at the level you want.
    When I asked for a link to your forum page, you were unable to provide this, giving a link to a page that does not exist. As such it is hard to help – a bit like asking for help with your car, but then not allowing me to examine your car.
    If you provide a link to the forum, the I may be able to help further, otherwise ethe best I can offer is to read the documentation

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

    and/or the advice in

    Before Posting

    #237793
    yagirlrenae
    Participant

    I added blog to site but it keeps taking me to homepage with clicking on topics and categories. Also why is it so difficult to use the forum it suppose to be made for wordpress. Also, why is it that noone can walk me through each step instead of sending information that is not useful for someone who is not good at code?

    #237760
    Robin W
    Moderator

    sorry, weekend and other things got in the way, but I have been playing with this.

    Try :

    add_shortcode ('bbp-forum-subscription-link' , 'rew_forum_subscription_link' ) ;
    
    function rew_forum_subscription_link ($atts) {
    	$args = array() ;
    	if (empty ($atts['forum'])) return ;
    	$args['object_id'] = $atts['forum'] ;
    	if (!empty ($atts['subscribe'])) $args['subscribe'] = $atts['subscribe'];
    	if (!empty ($atts['unsubscribe'])) $args['unsubscribe'] = $atts['unsubscribe'];
    	return bbp_get_forum_subscription_link ($args) ;
    }

    and then put this wherever it want it to appear

    [bbp-forum-subscription-link forum="2927" subscribe="Subscribe to Fishing Report" unsubscribe="Unsubscribe to Fishing Report" ]

    with the forum number and whatever wording you want

    #237750
    enkoes
    Participant

    Try to enable tinymce full editor and you will see the button. Check out this documentation.

    #237746
    1wb5rdd
    Participant

    Folks, this is reference bbPress 2.6.9, WP 6.2.2 and the link to our site forums page is https://www.wb5rdd.org/forums/. My issue is this – Forum users cannot change the font color on their posts. Even with the highest level of access I cannot change the font on the sentence “Please call, text or email me if you can help.” on this page https://www.wb5rdd.org/forums/topic/autumn-in-bonham-bike-rally-radio-operator-assistance-requested/ red. Where are the color choice buttons? Why won’t using HTML code (<FONT COLOR=”#ff0000″> </FONT>) doesn’t even do it. THANKS! – Phillip Beall

Viewing 25 results - 476 through 500 (of 32,468 total)
Skip to toolbar