Yes–it was a private parent forum. Ok good news and bad news–I replaced the code in post.php:
if ( ‘publish’ === $parent->post_status ) {
replaced with
if ( ! empty( $parent ) ) {
The permalink has been fixed, but now I am getting errors:
Warning: Cannot modify header information – headers already sent by (output started at /public_html/wp-includes/post.php:1) in /public_html/wp-admin/post.php on line 197
Warning: Cannot modify header information – headers already sent by (output started at /public_html/wp-includes/post.php:1) in /public_html/wp-includes/pluggable.php on line 1228
What does this mean?
Hi All.
I think that I have a similar problem, maybe the same problem.
If anyone advise me I will be very grateful.
Unfortunately I am not a programmer and I can not help myself.
I tried to insert this code from @gperez-tl
add_filter('bbp_get_reply_position', 'lugpa_get_reply_position', 10, 3);
function lugpa_get_reply_position($reply_position, $reply_id, $topic_id){
if(empty($topic_id))
$topic_id = bbp_get_reply_topic_id ($reply_id);
$numReplies = bbp_get_topic_reply_count($topic_id);
return ($numReplies+1) - $reply_position; // plus one because of thread description
}
into my theme functions.php but it does not work for me.
For example, in this topic:
3.1.2016 Supercars @ Brands Hatch
Links to first posts (#9129) refers to the wrong url to page2, but this post is still on page1…
Other post urls on this page1 is OK. When i go to page2 every post has bad URL refers to page1.
Please help if you can… Thanks
seems it is pasting the date of the original topic, not the date of it’s latest reply.
so the site is posting
<a title="2016 Targets" href="http://www.harrisonchapmankarate.com/forums/topic/2016-targets/">1 week, 1 day ago</a>
when it should be posting
<a title="Reply To: 2016 Targets" href="http://www.harrisonchapmankarate.com/forums/topic/2016-targets/#post-3442">17 hours, 55 minutes ago</a>
what theme and plugins are you using?
The code you have under the title is
.add-new-post-header2 .container {
border-bottom: 1px solid #ecf0f1;
}
Are you using a wordpress page with [bbp-forum-index] in it?
I’ve managed to do it with the following css.. I do wonder if there is a more efficient way?
.entry-title {
background: #212121;
border-color: #000000 !important;
}
#bbpress-forums div.odd,
#bbpress-forums ul.odd {
background: #212121;
border-color: #000000 !important;
}
#bbpress-forums div.even,
#bbpress-forums ul.even {
border-color: #000000 !important;
background: #212121;
}
#bbpress-forums {background:#212121 !important;}
#bbpress-forums ul li{background:#212121 !important; border-color: #000000 !important;}
Hello I was hoping for some help please . I’ve just made the background colour of my forum a darker shade (see below) and now I need to change the border colours from white to a slightly duller shade.
How can I do this please?
.entry-title {
background: #212121;
}
#bbpress-forums div.odd,
#bbpress-forums ul.odd {
background: #212121;
}
#bbpress-forums div.even,
#bbpress-forums ul.even {
background: #212121;
}
- When visitors come to a forum and click a topic from the topic index list, bbpress elegantly shows the lead topic and replies and Reply-to form on the topic page.
- I wanted to hide the reply form box, instead, put a link of pointing to a regualr wordpress page so that only visitor who wants might write a reply for that topic by clicking the link.
- So I copied a page from parent theme dir into the child theme dir, and named “forum_new_reply_form.php” and changed like :
/**<br>
* Template Name: Forum New Reply Form<br>
*<br>
* @package WordPress<br>
* @subpackage Twenty_Sixteen<br>
* @since Twenty Sixteen 1.0<br>
*/<br>
get header(); ?><br>
< div id=”primary” class=”content-area”><br>
< main id=”main” class=”site-main” role=”main”><br>
< ?php <br>
// Start the loop.<br>
while ( have_posts() ) : the_post();<br>
// nothing to do here <br>
endwhile;<br>
?><br>
< ?php <br>
global $wp_query;<br>
if (isset($wp_query->query_vars[‘reply_to_this_topic’]))<br>
{ <br>
?><br>
< div class=”my-bbp-reply-form”><!– bbp-reply-form –><br>
< ?php <br>
$reply_shortcd = ‘[bbp-reply-form topic_id=”‘ . $wp_query->query_vars[‘reply_to_this_topic’] . ‘”]’;<br>
echo do_shortcode($reply_shortcd);<br>
? ><br>
< / div><!– bbp-reply-form –><br>
< /main><!– .site-main –><br>
< ?php get sidebar( ‘content-bottom’ ); ?><br>
< / div><!– .content-area –><br>
<br>
get sidebar()<br>
get footer() <br>
- Go back to functions of childtheme, put this action
add_action(‘bbp_template_after_single_topic’,’my_bbp_reply_form’);<br>
function my_bbp_reply_form() {<br>
if (!current_user_can(‘publish_replies’)){<br>
return;
}
$t = ‘< div class=”my-bbp-new-reply-form-link”>’; <br>
$t .= ‘< a href=”http://kabum/write_reply_page/?reply_to_this_topic=’ . bbp_get_topic_id() . ‘” title=”‘ . bbp_get_topic_title() . ‘”>’;<br>
$t .= ‘< /a>< / div>’;<br>
echo $t;<br>
}
- From content-single-topic.php, commented out
bbp_get_template_part( ‘form’,’topic’);<br>
so, i can see the lead topic and a link mentioed at 4), and replies if any.
- For debugging purpose, I copied form-reply.php into childtheme/bbpress, changed one line like this :
// printf( __( ‘Reply To: %s’, ‘bbpress’ ), bbp_get_topic_title() );<br>
echo ‘I am replying to ‘ . bbp_get_topic_title();<br>
under < legend > of < fieldset > of that file.
- When I clicked the link which was added at 4), a reply form pops up without any topic and replies !! hurray !!!
But disaster !!, <br> the page http : / /kabum/write_reply_page/?reply_to_this_topic=1234<br>
shows <br>
I am replying to “forum title” (the title of the regular page housing the template “Forum New Reply Form”)<br>
It should have shown <br>
I am replying to “topic title” (of topic id 1234)
- I learned that bbp_topic_id and bbp_reply_to are 0, that triggered fetching parent id of a topic.
The page source of browser does even show html < input hidden name=bbp_topic_id value in the page.<br>
The page of http://kabum/write_reply_page/?reply_to_this_topic=1234, exactly tells <br>
reply_to_this_topic is 1234
- I changed topic_id of shorcode bbp-reply-form atts with reply_to before retrying.<br>
Same thing happened.
- At the writing of this post, bbpress org documentation regarding to bbp-reply-form shortcode,<br>
is not clearly saying about shortcode atts, but topic is [bbp-topic-form forum_id=$forum_id].
- in case topic creation, i did the similar way as mentioned above, works fine. no need to do with jquery stuff.
- bbpress outof box has action as h t tp://kabum/forums/topic/topic_title/#newpost, but my reply form page is
h t tp://kabum/topic_title/?reply_to_this_topic=1234, i.e./forums/forum is sit in or not. In my reading of showrcode source, I can’t find any clue of hansdling atts reply_to hopfully i was wrong reading.
==
Hopfully, looking forward to anyone’s help.
Hey guys
I am creating a link to creat new Topic form and using the
href=”mysite/forum/<?php bbp_forum_id(); ?>/#new-post”>Create New Post
I get the links parsed as
href=”mysite/forum/6/#new-post”>Create New Post
notice the 6!
I have permalinks on so how to force the shortcode forum name?
Thanks
Sorry I was off line during the holidays..
Glad to hear you have sorted it now..
It is usually better to have a copy of the orginal code with you if you hava customized theme for comparison and help recevied from here and most of the help you would get here would be based on the default plugin code and theme..
The best advice I can give you is to create a test site for each of your live sites.
This not only allows you to test new plugins, be confident in taking and using backups but also be happy that you can re-create your site should your host provider go bankrupt and you lose everything.
https://codex.bbpress.org/getting-started/testing-your-bbpress-installation/creating-a-test-site/
I am keen to create a forum for my 2 websites that have been in existence for over a year in order to entice visitors to hang around and engage each other on key topics that are very dear to me. I originally intended to use MyBB for my 2 websites World Of Leathers and CarBuyerSg but received advice from MyBB forum members that the current different WordPress themes on my websites are not suitable for MyBB and will likely conflict with it.
I downloaded bbPress for both websites but didn’t dare to activate them after it crashed another website of mine that was a one Page website using the free So Simple Theme By Press75. The So Simple theme is one of the cleanest and most basic free WordPress theme available with really clean codes and meant for simple basic websites so I am now really afraid to activate it on my 2 websites that are using premium WordPress themes from Studio Press and Elegant Themes. Does anyone have any experience using bbPress for the Lifestyle Pro Theme by Studio Press or the Divi Theme by Elegant Themes?
If anyone runs into this wondering the same thing, I got this working using this code:
<?php global $current_user; get_currentuserinfo(); $uid = bbp_get_current_user_id(); ?>
<?php if ( bbp_get_user_topic_subscriptions( $uid ) ) : ?>
<?php bbp_get_template_part( 'pagination', 'topics' ); ?>
<?php bbp_get_template_part( 'loop', 'topics' ); ?>
<?php bbp_get_template_part( 'pagination', 'topics' ); ?>
<?php else : ?>
<p><?php _e( 'You are not currently subscribed to any topics.', 'bbpress' ); ?></p>
<?php endif; ?>
Basically you just have to specify the current user’s ID number in the bbp_get_user_topic_subscriptions function. I’m running into another weird problem that I haven’t been able to fix though: If this is in your sidebar and you view a single forum, it will only display the subscribed topics within that forum.
Hope this helps someone.
the problem seems to be in your custom-css
#bbpress-forums .bbp-body div.bbp-reply-content {
clear: both;
margin: 10px;
padding: 0;
}
is moving the text down – take this out and it appears in the right place
contact me via my website and I’ll send you the code for your functions file
http://www.rewweb.co.uk
Thanks. It would be such an easy thing for bbPress to add too. I will need to fork it out. Do you know of any good tutorials to do this, I am not sure how much customization I will need to do compared to the widget code already.
Thanks again,
no simple way to do this in your functions file, the bbpress widgets are pretty unforgiving in allowing you to tinker with them.
two immediate choices – fork the widgets code into your functions file and rename it – requires some php and WordPress knowledge or
Just amend it in the bbpress file – AND make a note to need to change it on bbpress upgrades.
The latter upsets the purists, but it’s only codes and you can’t be arrested for changing code !
I am looking for a way to update my functions.php file to add a dynamic additional class to the bbPress Forums List Widget. Basically I would like the current code of:
<li><a class="bbp-forum-title" href="<?php bbp_forum_permalink( $widget_query->post->ID ); ?>"><?php bbp_forum_title( $widget_query->post->ID ); ?></a></li>
I would like to add an additional dynamic class or ID to the link. I want to do this so I can add different background images to each forum if I choose through CSS.
Thanks!
Strange, can you open bbpress-cs.po in a text editor and confirm that these exist in the .po file:
The original string:
• Your username must be unique, and cannot be changed later.
The “waiting” string for the “dev” (2.6-alpha) translations
• Vaše přezdívka musí být unikátní a nejde později změnit.
The “waiting” string for the “stable” (2.5.x) translations
• Vaše uživatelské jméno musí být jedinečné, a nelze ho měnit.
I have read other posts regarding the alignment of bbPress after removing the R side bar in a theme. I would like to center the forum on this page. Any help would be appreciated.
Thanks!
http://copdcommunity.org/forums/
WP version 4.4
Theme Twenty Sixteen 1.0
bbPress version 2.5.8-5815
bbp style pack 2.8.4
bbP Toolkit 1.0.5
I created bbpress.php and placed it in the theme root dir to remove the R sidebar.
<?php
get_header(); ?>
<div id="main-content">
<div class="container">
<div id="content-area" class="clearfix">
<div>
<?php while ( have_posts() ) : the_post(); ?>
<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
<h1 class="main_title"><?php the_title(); ?></h1>
<div class="entry-content">
<?php the_content(); ?>
</div> <!-- .entry-content -->
</article> <!-- .et_pb_post -->
<?php endwhile; ?>
</div>
</div> <!-- #content-area -->
</div> <!-- .container -->
</div> <!-- #main-content -->
<?php get_footer(); ?>
Do you still have a problem?
I am unsure from your various rants what exactly the issue is – I need a problem definition to be able to help, and don’t know from your name ‘iapologizepleasedeleteme’ whether you have now fixed your issue.
If you still have the problem then – given that you have been pressing lots of buttons – I would suggest you contact you host provider and ask then to revert your site to a previous backup – almost all host providers take backups every 24 hours. This will get you site working again.
I would then invest some time in creating a test site – to do development in your live site is just stupid, as you have found out. See https://codex.bbpress.org/getting-started/testing-your-bbpress-installation/creating-a-test-site/
For others I was able to remove the widget by adding the following line to [wp docroot]/wp-admin/includes/dashboard.php
remove_meta_box('bbp-dashboard-right-now', 'dashboard', 'core');
Specifically line 55, just above the line
// WordPress News
hi,
i am novice, so i need more support and suggestion more than others…..
i have installed Gazette (Automattic) theme and then bbpress plugin and some of things as said in https://codex.bbpress.org/themes/theme-compatibility/ …. but its not working. i cant see any bbpress template-pages or other things….
can you able to help me out on the same….
thanks…
Hi!
I am trying to get a list of specific topics which have some meta data in common.
No matter what I insert in 'meta_key' => 'name' property of query_posts function, the page still returns a list of the total topics.
This is my code so far:
add_action('wp', function() {
if( isset( $_GET['my_variable'] ) ) {
$page = get_query_var('paged') ? get_query_var('paged') : 1;
query_posts(array(
'paged' => $page,
'post_type'=> 'topic',
'order' => 'ASC'
));
}
});
If I visit site.ext/?my_variable=1 I get a list of all forum topics.
How can I get this to work, using query_posts or WP_Query, or any other workaround? How can we target those specific topics and show them as a list?
Regards,
Samuel.
Step by step guide to setting up a bbPress forum – part 3
The usage of child theme is to avoid overwriting any customization that you have done to your site by a theme/plugin upgrades. So you maintain a separate set of files in different folder than the out of box themes or plugins. This way whenever there are new upgrades and get pushed and overwrite your files, it won’t overwrite whatever customization you had.
I think for Czech the files should be bbpress-cs.mo and bbpress-cs.po
When you export the translations from translate.wordpress.org you should also change a couple of the defaults:
• Make sure the filter Current/waiting/fuzzy + untranslated (All) is showing the waiting translation
• Select the only matching the filter and then click export to export the .po .mo (This way you’ll get the those strings that have not yet been approved)