Search Results for 'code'
-
AuthorSearch Results
-
July 27, 2015 at 4:59 pm #164643
Robkk
ModeratorYeah this issue is not because of the bbPress plugin but your site does not have enough memory.
https://codex.wordpress.org/Common_WordPress_Errors#Allowed_memory_size_exhausted
July 27, 2015 at 3:04 pm #164638Robkk
ModeratorYou have to copy the main template bbPress is inheriting from your theme for its layout and create a bbpress.php file from it. This would usually require you to remove the sidebar code, then use CSS to make the layout fullwidth.
July 27, 2015 at 11:42 am #164627In reply to: Logout Link Redirects to Topic
drinkingsouls
ParticipantBasically when I activate bbPress on my blog the log out links no longer work. It seems to append a redirect to the end of log out links which prevents it from working. I’m not sure why but it’s definitely to do with bbPress.
Here is the logout anchor tag when bbPress is deactivated (works)
<a href="http://test.webshrimp.uk/wp-login.php?action=logout&_wpnonce=1ef350795a">Log out</a>Here is the anchor tag when bbPress is activated – doesn’t do anything
<a href="http://test.webshrimp.uk/wp-login.php?action=logout&_wpnonce=1ef350795a&redirect_to=http%3A%2F%2Ftest.webshrimp.uk%2F%3Floggedout%3Dtrue">Log out</a>Any help would be greatly appreciated.
Thank you.July 27, 2015 at 5:30 am #164621In reply to: How can I hide category when create a new topic?
PinkishHue
ParticipantI’m assuming by category you mean the forum that the topic is in?
You can remove the forum dropdown menu and use a hidden field here instead.
In your theme you need to have this file:
wp-content/your-theme/bbpress/form-topic.php
If you don’t have it, copy it over from the bbpress default templates at:
wp-content/plugins/bbpress/templates/default/bbpress
Then open your new form-topic.php in a text editor and find this part of the code:
<p> <label for="bbp_forum_id"><?php _e( 'Forum:', 'bbpress' ); ?></label><br /> <?php bbp_dropdown( array( 'show_none' => __( '(No Forum)', 'bbpress' ), 'selected' => bbp_get_form_topic_forum() ) ); ?> </p>and replace it with this:
<input id="bbp_forum_id" type="hidden" name="bbp_forum_id" value="20">Where 20 is the ID no. of the forum you want all topics to be created in.
Hope that helps 🙂
July 27, 2015 at 2:49 am #164616In reply to: bbcode Visual Editor for bbpress
killer_x10
ParticipantYou could’ve added a function to allow extra tags though.
I think most people prefer bbcode in the Forums and besides I’m not a Developer, I know very little js and just started with php (You could call me Web Designer though).
But the close Tags isn’t still working for me, I think I’m just gonna publish the Site without that functionality.
July 26, 2015 at 10:18 pm #164615In reply to: Replies Created Tab Showing Full Posts
Robkk
ModeratorFound this snippet earlier this week, this should help not allow guest users to see BuddyPress Profiles.
/** * Redirect buddypress and bbpress pages to registration page */ function kleo_page_template_redirect() { //if not logged in and on a bp page except registration or activation if( ! is_user_logged_in() && ! bp_is_blog_page() && ! bp_is_activation_page() && ! bp_is_register_page() ) { wp_redirect( home_url( '/register/' ) ); exit(); } } add_action( 'template_redirect', 'kleo_page_template_redirect' );July 26, 2015 at 9:30 pm #164611In reply to: Modify forum index page and some
Robkk
ModeratorI’ve looked inside the loop-forums.php template, then found this <?php do_action( ‘bbp_template_before_forums_loop’ ); ?> being executed. Which template file is bbp_template_before_forums_loop pulling from ?
Sorry for the late reply, but that is a hook. If you want the login form only above the forum index just echo the shortcode like so above or below that hook.
<?php echo do_shortcode("[shortcode]"); ?>or if you are pretty good with PHP just use the hook.
If you want the login form above all bbPress pages, you might have to consider echoing the shortcode in a bbpress.php file.
July 26, 2015 at 9:00 pm #164608In reply to: template_part hierarchy
Robkk
ModeratorIf what you are looking for is to remove the
This topic contains blah blah blah
Look for this in
content-single-topic.php<?php bbp_single_topic_description(); ?>You can also use a function snippet like this to remove it for Forums and topics.
add_filter( 'bbp_get_single_forum_description', 'ja_return_blank' ); add_filter( 'bbp_get_single_topic_description', 'ja_return_blank' ); function ja_return_blank() { return ''; }July 26, 2015 at 8:51 pm #164607In reply to: How to enable tinyMCE text editor??
Robkk
ModeratorTry some troubleshooting especially the Theme and Plugin steps.
July 26, 2015 at 8:47 pm #164605In reply to: Make The Forum Full Width
Robkk
ModeratorYou have to copy the main template bbPress is inheriting from your theme for its layout and create a bbpress.php file from it. This would usually require you to remove the sidebar code, then use CSS to make the layout fullwidth.
Robkk
ModeratorAdd all this CSS, it fixes the issue you have created this topic for and whatever else I could find on your site.
#bbpress-forums .reply a { padding: 0; display: inline-block !important; text-align: inherit!important; } #bbpress-forums .reply a:hover { background-color: transparent !important; } #bbpress-forums li.bbp-topic-voice-count, #bbpress-forums li.bbp-topic-reply-count { color: inherit; } #bbpress-forums #content p{ text-align: inherit; }July 26, 2015 at 8:13 pm #164602In reply to: Logout Link Redirects to Topic
Robkk
Moderatormax links allowed in posts are 2 this includes links in embedded images.
You can remove the http:// from the code, I would know what you are talking about.
July 26, 2015 at 8:09 pm #164600In reply to: Check if post is visible to user
Robkk
ModeratorMaybe this? Not 100% sure though, if you haven’t contact BuddyPress support.
if ( is_user_logged_in() || bp_group_is_member() )July 26, 2015 at 12:29 pm #164595In reply to: Logout Link Redirects to Topic
drinkingsouls
ParticipantMy replies with code won’t post for some reason..
July 25, 2015 at 7:17 pm #164583In reply to: Display this plugin before the username on replies
Stagger Lee
ParticipantForgot about this and that I did it without buddyPress. Took code from this plugin and adapted it to my needs. But I see you already found it and adapted it self. Added some additional thing, Non logged User doesnt see online/offline icons, logged in User see them. Good to force curious people to log in.
https://wordpress.org/support/topic/show-a-red-green-circle?replies=16
https://wordpress.org/plugins/bbp-user-online-status/screenshots/July 25, 2015 at 5:31 pm #164580In reply to: bbCode toolbar with markItUp! editor
killer_x10
ParticipantThank you for the Information but I am just replacing all the HTML Tags with bbcode tags, nothing special because I am very bad at php and javascript, I know very little js and just started with php. Btw I have finished it, just couldn’t get 1 thing right, Close HTML Tags.
Here’s the Link to the Topic: https://bbpress.org/?post_type=topic&p=164557
July 25, 2015 at 4:38 pm #164578In reply to: Redirect from page to profile url (menu link)
Robkk
Moderatorif you need to use the user nicename replace
$user = $current_user->user_login ;with
$user = $current_user->user_nicename ;How could I possibly find out the correct menu slug id? Right now the menu appears in every menu (sidebar as well) and regardless of an user’s login status.
I guess you can try doing what the top answer said here.
http://wordpress.stackexchange.com/questions/104301/get-menu-id-using-its-name
July 25, 2015 at 2:13 pm #164565Stagger Lee
ParticipantI help others as much I can and know. I cannot code from scratch. I knew this argument would come soon or later.
Cannot be more specific. Move plugins from Github to WP repository and if possible maintain them by themselves. Good start.
Can tell you story of most advanced and most powerfull forum on the world.
Drupal forum, long time ago in the core, then as “featured plugin” (module) and now lost, not existing.
I worked few months very intense on it and can witness that it is most advanced and powerful on the world (was).But for what use, what is the point. Nobody use it and now everyone forgot about it. Ugly as hell when installed, takes lot of time.
Learn from mistakes of other people. Not everything is in the code.
July 25, 2015 at 2:00 pm #164563Robin W
ModeratorAn interesting discussion, and can I perhaps add my thoughts as a plugin developer
You start from a perspective that bbpress would naturally seek to be all things to all people and should want to compete with other products.
I cannot speak for bbpress authors, but as a plugin author I write for the enjoyment and challenge of coding and to help others – I am not in an arms race or commercially minded – I can do plenty of that outside bbpress – and if some code I write has one user or thousands as long as it does what I want it to, I am happy. Yes it is nice to have good feedback, and improve it using others suggestions, but when these are posted as pseudo demands, or as a big list of complaints, then I have to say I would turn off. I do this for free, in my spare time, and for my enjoyment, and I suspect that the bbpress authors do the same as well.
I have to say therefore I find your general thrust of your demands, and your ‘I know better’ how bbpress should be run attitude upsetting.
This is a free product – if you want to improve it don’t whinge for the sidelines – write a detailed spec or better still write the code and submit it yourself.
Just telling others how they should do something that costs you nothing seems a very negative way to go about things.Just my view 🙂
July 25, 2015 at 1:51 pm #164562Robkk
ModeratorTo edit the templates make sure to copy the files from the bbPress plugin into your child theme in a folder called bbpress.
In
content-single-forum.phpremove this to remove the forum subscription link.<?php bbp_forum_subscription_link(); ?>In
user-subscriptions.php, remove all of this.<h2 class="entry-title"><?php esc_html_e( 'Subscribed Forums', 'bbpress' ); ?></h2> <div class="bbp-user-section"> <?php if ( bbp_get_user_forum_subscriptions() ) : ?> <?php bbp_get_template_part( 'loop', 'forums' ); ?> <?php else : ?> <p><?php bbp_is_user_home() ? esc_html_e( 'You are not currently subscribed to any forums.', 'bbpress' ) : esc_html_e( 'This user is not currently subscribed to any forums.', 'bbpress' ); ?></p> <?php endif; ?> </div>July 25, 2015 at 12:36 pm #164558In reply to: Redirect from page to profile url (menu link)
Robkk
ModeratorShould be also possible to make new menu items via functions to one of the menus created in backend design -> menu, right?
Maybe? maybe do something similar to what Baw login/logout menu uses, but I haven’t dived deep into this yet.
The way your code looks is a little odd, you might have to construct it similar to what I posted above.
This is what I made while messing with it, there could be a different class that your theme uses for sub-menu’s though.
add_filter( 'wp_nav_menu_items', 'my_nav_menu_profile_link' ); function my_nav_menu_profile_link($menu) { if (!is_user_logged_in() && $args->menu->slug == 'mobile_menu') return $menu; else $current_user = wp_get_current_user(); $user = $current_user->user_login ; $class = 'sub-menu'; $profilelink = ' <li><a href="/forums/users/' . $user . '/">Your Profile</a> <ul class=' . $class . '> <li><a href="/forums/users/' . $user . '/replies">Replies</a></li> <li><a href="/forums/users/' . $user . '/topics">Topics</a></li> <li><a href="/forums/users/' . $user . '/subscriptions">Subscriptions</a></li> <li><a href="/forums/users/' . $user . '/edit">Edit Profile</a></li> </ul> </li> '; $menu = $menu . $profilelink; return $menu; }July 25, 2015 at 12:23 pm #164556In reply to: bbCode toolbar with markItUp! editor
Robkk
ModeratorThere is a toolbar plugin which is quite old. Just so you know if you plan to fix it up, you might as well structure it out better, because with all of its inline javascript it will add about 3 seconds load time to your site.
There is also a way to hook up other toolbars that could be just for bbcode into bbpress also.
July 25, 2015 at 11:20 am #164552In reply to: bbCode toolbar with markItUp! editor
killer_x10
ParticipantI understand, thank you anyway Robkk.. btw I am actually testing another Toolbar Plugin and I am editing some stuff around and my first Test went okay, now I’m just editing that Toolbar Plugin to add up with bbcode.
July 25, 2015 at 11:17 am #164551In reply to: bbCode toolbar with markItUp! editor
Robkk
ModeratorThis topic was way back in bbPress v1, so nothing is good for this current version.
There is a way to use shortcodes (bbcode) as long as they are whitelisted for users in the quicktags toolbar but this would require some editing of some javascript.
You can also use the TinyMCE toolbar, adding bbcode to this would be more difficult then editing the quicktags toolbar.
July 25, 2015 at 11:13 am #164550In reply to: Importing from WBB4
Robkk
ModeratorCould be the importer code.
Is there anything else you can spot that is different between WBB3 and WBB4?
-
AuthorSearch Results