Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 6,001 through 6,025 (of 32,505 total)
  • Author
    Search Results
  • #177498
    Stephen Edgar
    Keymaster

    Maybe try deleting any bbpress-es_ES.po files, and then get new translations by going to http://example.com/wp-admin/update-core.php and click “Update Translations”

    #177486
    ptrck_r
    Participant

    [Solved]

    If anybody hasthe same problem, I solved it by creating a small plugin out of the code so it’ll load on time.

    <?php
    /*
    Plugin Name: FilterBbRoleMap
    */
    
    if(!class_exists('FilterBbRoleMap')) {
    	class FilterBbRoleMap
    	{
    		public function __construct()
    		{
    			add_filter('bbp_get_user_role_map', 'add_spectator_role');
    			function add_spectator_role($role_map) {
    				$role_map['prefix_spectator'] = bbp_get_spectator_role();
    				return $role_map;
    			}
    		}
    	}
    
    	$FilterBbRoleMap = new FilterBbRoleMap();
    }
    #177475
    Robkk
    Moderator

    The “by” is printed in php, as displayed in this code here.

    https://github.com/ntwb/bbPress/blob/master/src/includes/common/widgets.php#L822

    There is a way to use CSS to hide the “by” though. It will look like the topic title has a little margin away from the topic authors name.

    Here is a custom CSS example.

    .widget_display_topics li {
      visibility: hidden;
    }
    
    .widget_display_topics li > * {
      visibility: visible;
    }

    There might be a way to use a plugin like Loco translate to just translate “by” to nothing also, but I have never tried that plugin before, and I am not 100% if that would even work. But it could be another possibly easy solution.

    #177474
    Robkk
    Moderator

    Robin might be on to something with the url thing. Robins suggestion works fine, but I usually suggest looking into using the Reveal IDs plugin, as it really makes it easier by just adding a column in posts like Forums > All Forums list and users list in the WordPress backend.

    https://codex.bbpress.org/getting-started/faq/#findpostid

    #177473

    In reply to: meta-single-topic

    Robkk
    Moderator

    @rateyourway

    Its a custom bbPress template file in your theme. I suggest you contact your theme developer. Maybe they can make the custom bbPress layout translatable by a few code tweaks.

    #177472
    Robkk
    Moderator

    @aviazz

    You already should have a way to view topics with no replies. By default bbPress has a feature called Views. It allows you to display topics with various different arguments. Topics with no replies should be one of the 2 default views which are Most popular topics and Topics with no replies

    You can link to the existing page using the Topic Views widget in your sidebar, or you can use a shortcode already provided by bbPress to display a view shortcode in a page and add it to a menu. You can also also instead add a custom link to a menu in the menus section in Appearance > Menus if you do not need to use a shortcode in a page.

    The widget is called the Topic Views widget that you will be able to see in Appearance > Widgets or you can manage your sidebars using the Customizer API in Appearance > Customize in the WordPress backend.

    https://codex.bbpress.org/features/widgets/

    The shortcode you would want to use is [bbp-single-view id='no-replies']

    https://codex.bbpress.org/features/shortcodes/#views

    If for some reason you may not already have the default view. See if its related to a theme/plugin function removing the default view by troubleshooting.

    Plugin Troubleshooting

    https://codex.bbpress.org/getting-started/troubleshooting/#plugins

    Theme Troubleshooting

    https://codex.bbpress.org/getting-started/troubleshooting/#themes

    If its not a theme/plugin issue we can check to see if its a possible bug causing an issue.

    #177471
    Stephen Edgar
    Keymaster

    @rateyourway The “freshness” term has been removed from bbPress 2.6 (/dev) so you will not see it in the translation files, it is still there for the current bbPress 2.5.x see:
    https://translate.wordpress.org/projects/wp-plugins/bbpress/stable/es/default?filters%5Bterm%5D=freshness&filters%5Buser_login%5D=&filters%5Bstatus%5D=current_or_waiting_or_fuzzy_or_untranslated&filter=Filter&sort%5Bby%5D=priority&sort%5Bhow%5D=desc#

    Edit: The string may also be coming from your theme, switch themes to one of the included “Twenty” themes to double check.

    #177469
    Robin W
    Moderator

    I’ve just added that capability to one of my existing shortcodes in my style pack plugin, so if you install

    https://wordpress.org/plugins/bbp-style-pack/

    and then see

    Dashhboard>settings>bbp style pack>shortcodes for a description of how to use it in detail, but

    [bsp-display-topic-index noreply='true']

    used in a page will get you what you want

    #177457
    Robin W
    Moderator

    The correct code would be

    [bbp-single-forum id='3569159-2']

    but I suspect ‘3569159-2’ is the url not the post ID as post ID are a whole number and what you want

    so go to

    Dashboard>forums and select all forums

    If you hover of ‘edit’ of then forum you want, you’ll see at the bottom left of the screen

    url…post.php?post=12345&action=edit

    it is the 12345 that you want to put in the shortcode

    #177455
    smartIt
    Participant

    Hi,
    I created a forum, his id is 3569159-2 and it contains one topic.

    in this page of my website http://radiotounsi.com/?page_id=4862
    I tried to display this forum by using the shortcode [bbp-single-forum id=$3569159-2] but nothing is displayed, but other bbpress shortcodes work just fine like [bbp-forum-index] and [bbp-login]
    I switched the theme to twenty sixteen for testing purpose, same problem

    #177453
    epretorious
    Participant

    This may be easier than I’d thought:

    [root@cp bbpress]# grep -r 'You must be logged in' *
    languages/bbpress.pot:msgid "You must be logged in to create new forums."
    languages/bbpress.pot:msgid "You must be logged in to reply to this topic."
    languages/bbpress.pot:msgid "You must be logged in to create new topics."
    templates/default/bbpress/form-forum.php:			<p><?php is_user_logged_in() ? _e( 'You cannot create new forums.', 'bbpress' ) : _e( 'You must be logged in to create new forums.', 'bbpress' ); ?></p>
    templates/default/bbpress/form-topic.php:			<p><?php is_user_logged_in() ? _e( 'You cannot create new topics.', 'bbpress' ) : _e( 'You must be logged in to create new topics.', 'bbpress' ); ?></p>
    templates/default/bbpress/form-reply.php:			<p><?php is_user_logged_in() ? _e( 'You cannot reply to this topic.', 'bbpress' ) : _e( 'You must be logged in to reply to this topic.', 'bbpress' ); ?></p>

    What’s the “best practice” for modifying the languages file? Is that something that I can achieve with a child theme?

    TIA,
    Eric Pretorious
    Portland, OR

    #177452
    epretorious
    Participant

    > Thanks, Pascal: That worked perfectly!

    One, very important correction: If visitors to the site aren’t logged in, they see nothingnot even the warning that “You must be logged in to…” 🙁

    There must be an easy way to do away with that “Oh bother!…” bit of text without leaving visitors in the dark. 🙁

    Maybe I should just manually change the source:

    [root@cp bbpress]# grep -r bother *
    languages/bbpress.pot:msgid "Oh bother! No forums were found here!"
    languages/bbpress.pot:msgid "Oh bother! No replies were found here!"
    languages/bbpress.pot:msgid "Oh bother! No search results were found here!"
    languages/bbpress.pot:msgid "Oh bother! No topics were found here!"
    templates/default/bbpress/feedback-no-topics.php:	<p><?php _e( 'Oh bother! No topics were found here!', 'bbpress' ); ?></p>
    templates/default/bbpress/feedback-no-replies.php:	<p><?php _e( 'Oh bother! No replies were found here!', 'bbpress' ); ?></p>
    templates/default/bbpress/feedback-no-search.php:	<p><?php _e( 'Oh bother! No search results were found here!', 'bbpress' ); ?></p>
    templates/default/bbpress/feedback-no-forums.php:	<p><?php _e( 'Oh bother! No forums were found here!', 'bbpress' ); ?></p>

    Eric Pretorious
    Portland, OR

    #177451
    epretorious
    Participant

    I’m really surprised to see that bbPress warns visitors to the forums that “You must be logged in to create new topics.” but does not provide a link to the login page. e.g.,

    <a href='/login.php'>Login</a> to create new topics and/or to reply to topics.

    Is there some way to correct that?

    TIA,
    Eric Pretorious
    Portland, OR

    epretorious
    Participant

    Robin:

    Originally: I hid the top primary menu by adding a bit of CSS to the child theme:

    .primary-navigation {
            display: none;
    }

    …but I have since enabled the top primary menu.

    HTH,
    Eric Pretorious
    Portland, OR

    #177429
    Robkk
    Moderator

    Creating a new view template will help with the layout of how you want it. And yes you can still show that view with a shortcode.

    #177428
    MalMac
    Participant

    Apologies for being unclear,

    The shortcode I posted worked, just wondering if I create a new view template if I will be able to call it in a shortcode?

    Thanks!

    #177427
    Robkk
    Moderator

    The shortcode that you posted seemed alright with the code you posted, so you had the right ID and everything, only thing I would possibly say is if those quotes don’t work use single quotes.

    '

    #177425
    MalMac
    Participant

    Thats a great help, Thanks! Would it be possible to call this new view in a shortcode?

    #177423

    In reply to: Dynamic Profile Link

    Robkk
    Moderator

    The toolbar on this site is sort of absolutely positioned, it has this CSS used. Its not really that great if you want a good mobile site.

    #wpadminbar {
      top: 81px;
    }
    #177419
    Robkk
    Moderator

    If you want a specific view to have images, you would need to create a custom view template called either single-view-recent-with-topic-image.php or view-recent-with-topic-image.php and most of the code would be based on the single-view.php template in the extras folder in the bbPress plugin, you would have to make it custom enough to include the featured image code, and I guess however your users will be able to select a featured image during topic creation.

    #177418

    In reply to: Site Role

    Robkk
    Moderator

    Well I don’t entirely understand where you are getting at, but I mean its possible for a user to have 3 different roles.

    For example.

    Site Role – Subscriber – Default WordPress role
    Forum Role – Participant – Default bbPress role
    Membership Role – Premium Member – Some paid membership framework plugins role

    If you want 1 custom site role with different capabilities that other roles might have, consider creating a custom user role. But be aware of what each capability does, so that you will not give your users permissions that you do not exactly want them to have.

    Creating a custom bbPress role guide.

    https://codex.bbpress.org/custom-capabilities/

    bbPress user roles and capabilities

    https://codex.bbpress.org/getting-started/before-installing/bbpress-user-roles-and-capabilities/

    WordPress roles and capabilities

    https://codex.wordpress.org/Roles_and_Capabilities

    And a plugin I would recommend to create a custom user role with custom capabilities would be a plugin called Members by Justin Tadlock.

    MalMac
    Participant

    Hello All,

    This is what I have so far:

    in my functions.php file:
    bbp_register_view( 'recent-with-topic-image', __( 'Recent With Topic Image' ), array(false ,'author' => 0, 'show_stickies' => false, 'order' => 'DESC', 'post_parent' => 'any', 'posts_per_page' => 8 ), false );

    corresponding short code
    [bbp-single-view id="recent-with-topic-image"]

    What can I add to array to show the featured image from the topic that the post is in?

    Thanks, Malcolm

    #177416
    Robkk
    Moderator

    I think other moderators thought this was spam.

    I can see that it is hard to tell unless you go digging in your sites source code to tell if you are using bbPress.

    I knew one day with all these users basically using bbPress as a blog, that a designer one day would customize and create custom templates for bbPress enough to just make it look like a blog.

    Interesting and very unique stuff!!

    You don’t even have to worry about waiting for bbPress replies for blog posts, because your whole site is mainly using bbPress.

    Interesting as hell to see bbPress turn into a news site.

    #177415

    In reply to: Dynamic Profile Link

    Robkk
    Moderator

    Its the WordPress toolbar, a bit customized, but its definitely the default WordPress toolbar.

    https://codex.wordpress.org/Toolbar

    Joe Greenwood
    Participant

    I have already posted this question, but has not been approved by moderators. Please approve, has been entire day already, thank you.

    I have issue where bbPress HTML code is being written above the <doctype> declaration in my page, but this only happens when not logged in / signed in to WordPress. This is for Forums and Topics pages, and none others. When logged in, then HTML code is written in its proper place. I will attach a screenshot showing both instances, the top being when not signed in (HTML is out of place, before <doctype>), the bottom when signed in (HTML is correctly placed in body, and <doctype> comes first as it should).

    screenshot

    Any ideas on where this HTML might be called differently, depending on whether or not user is logged in? I have tried disabling plugins. Perhaps it is something with my theme. My site can be viewed at http://www.lexiconleep.com/forums/forum/leep-questions-answers/ … I wonder if it has something to do with assigning a forum role to anonymous users..? Perhaps anonymous (not logged in) users need to have a forum role … I will look into this. Thanks!

Viewing 25 results - 6,001 through 6,025 (of 32,505 total)
Skip to toolbar