Search Results for 'code'
-
Search Results
-
Topic: bbPress Forums subtitle
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:
ForumsbbPress Forums
Seems duplicated to me.
Sorry if this has been discussed but my searches have come up empty.
Topic: Change css id’s
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 ?
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?
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!
Topic: Empty forum index
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/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.
ThanksI’m redesigning my site, and for some reason, the child (sub) forums are not showing on the Forum Index under their parents. This happened on my first development site and after trying different things, I uninstalled bbPress and reinstalled it. They appeared. Now, when I moved my redesigned theme (which does have some template overrides) to a new dev site setup, once again my child forums are missing. However, uninstalling and reinstalling bbPress didn’t fix it this time.
I looked at the source code of the forum index and there is absolutely nothing there (no child forums).
Any ideas why they are not showing up again?
NOTE: I’m on WordPress 5.4.2, PHP 7.2. I switched to the twenty twenty theme, and the same thing happens…no child forums show under the parents. I also cannot give a link because my redesign is done locally on XAMPP.