Search Results for 'code'
-
AuthorSearch Results
-
August 17, 2015 at 10:36 am #165465
In reply to: Inserting Forum Element on Front Page
kachan64
ParticipantYou will have to use
<?php echo do_shortcode(‘[bbp-topic-index]‘); ?>With this code, you can insert it anywhere you want just like a regular HTML
August 17, 2015 at 3:58 am #165459In reply to: The subscribe has no spaces from breadcrums
Robin W
ModeratorTry adding !important – your theme may be overriding the settings viz
August 16, 2015 at 5:46 am #165440Topic: Add line breaks to frontend’s biographical info
in forum Troubleshootingproject_subdomain
ParticipantAs wordpress strips the break and text tags I’m looking for a solution to add line breaks to my bbp_user_decription div.
Here is what did not work:
1.) What I find everywhere is some sort of this added to functions.php:remove_filter('pre_user_description', 'wp_filter_kses');This does not work, also looking at wordpress’ recent incl/registration.php just saying this file is deprecated makes me think that this code should not get to work at all.
2.) Alternatively I looked through my themes’files and used
<?php echo nl2br(get_the_author_meta( 'user_description' )); ?>
in content.php. Or<?php echo nl2br(get_the_author_meta( 'description' )); ?>in my author.php3.) Tried 1) and 2) with bbp_ at the beginning of each decription’s part.
Nothing worked, break-or p-tags are just ignored.
Also, is there a secure way to add break-tags only?
Thanks for any help!August 15, 2015 at 8:25 am #165410In reply to: bbPress Shortcode
Robkk
ModeratorYou would need to follow this and create a bbpress.php file and then come back and I will help you with some CSS that you might need.
August 15, 2015 at 8:21 am #165409In reply to: New to bbPress – Help on Page Theme
Robkk
ModeratorIt looks like it is inheriting different templates for the forum archive and the single forums. From the looks of it the second image looks correct to me. It is displaying the title, but you have leftover post data from your theme like the extra breadcrumbs.
If you did create a bbpress.php rename it to something like bbpressa.php so that it won’t load anymore.
Now if you have what the file still installed, go to the forum archive or
/?post_type=forumand see if the page template is different from what the General Forum page has.The reason why I am saying do this, is to see if bbPress could be inheriting two different templates. It would make sense if the Forum archive would use page.php or even archive.php, and in some cases the single forum pages could be inheriting single.php.
August 15, 2015 at 6:57 am #165405In reply to: The subscribe has no spaces from breadcrums
Robkk
Moderatorwhoops sorry I messed up the CSS a little. I edited the code above try that now.
August 15, 2015 at 5:41 am #165397In reply to: New to bbPress – Help on Page Theme
Robkk
ModeratorYou can try that, but it usually only affects one specific page. Doing it this way means you have to put a shortcode for every bbPress page. It is easier in the end to just create a
bbpress.phpfile in your theme from yourpage.phpfile. You can also just tell me your theme (hopefully it is not paid) then I could just do it for you.August 15, 2015 at 4:05 am #165395In reply to: Get next and previous page in wp_header
Robkk
ModeratorNot entirely sure really but I have tested themes that add next and prev post nav links to bbPress on accident and it seems to work. You may need to add the php tag to the bbPress forum templates, maybe just output it in a bbpress.php file with a condtional to only show on single forums.
https://codex.wordpress.org/Function_Reference/posts_nav_link
August 15, 2015 at 3:27 am #165390In reply to: Importing a large vBulletin forum – in stages?
Robkk
ModeratorThere should be a vBull importer in bbPress.
The W3 Total Cache would help optimize bbPress. Of course it is more important to have high performance hardware on your site, use an opcode cache, possibly an object cache (the plugin helps add a backend file), and keeping your database tidy. Page cache can become a little tricky in some situations but it should be fine using w3 total cache with bbPres.
bbPress is translatable and there are translations for specific langauges.
bbPress could work in multilingual sites. It might be better to just allow your users to contribute their content in their language though. There is an issue using WPML though.
August 15, 2015 at 3:07 am #165388In reply to: How to share bbPress forum multisite
Robkk
ModeratorIs there anyway you could embed a forum into another page?
Not the whole bbPress forums like some Iframe embed like some other forums, you can use this shortcode to embed a single forum though.
[bbp-single-forum id=$forum_id]
Display a single forums topics. eg. [bbp-single-forum id=32]
To find the ID, add a plugin like Reveal IDs to help you out find the IDs of all your forums. After installing it go to Forums > All Forums and you should see each forums ID next to it.
There are of course other ways of finding a posts ID and you may not need to install the plugin, it is just better and easier for users.
August 15, 2015 at 2:48 am #165387In reply to: The subscribe has no spaces from breadcrums
Robkk
ModeratorThis should help.
/*styling to move 'Subscribe' to right hand side */ .single-forum .subscription-toggle { padding-left: 10px; }August 15, 2015 at 2:39 am #165386Robkk
Moderator1. Not entirely sure what the topic frame is, but I like how the title looks good on your site already.
2.
div.bbp-reply-header { clear: none; }If you need help styling your forums you may need to use the bbp style pack plugin. There are a lot of CSS styles on your site that I can see causing some minor issues with other areas on bbPress, like the Forum Header labels that say Topic and Freshness. You may also need to use a darker image/background for your single forum pages.
August 15, 2015 at 1:58 am #165385Stephen Edgar
KeymasterIf you select a different forum from the dropdown, e.g.
SMFwhat error do you get?Can you also try using an incorrect password, you should be seeing some kind of errors here rather than nothing each time.
August 14, 2015 at 11:38 pm #165381In reply to: several forum
Robkk
ModeratorYou might need to look into using LearnPress and this plugin. I think it should do what you want, but you may need to leave a support topic on the plugin’s below support forum just to make sure.
https://wordpress.org/plugins/learnpress-bbpress/
Or this might be custom development for a plugin.
But what you can do is at the bottom of each post just insert one of the single forum shortcodes.
Like this.
[bbp-single-forum id=$forum_id]You can find the forum id by using a plugin like Reveal IDs to make life easier, and all you have to do is go to Forums > All Forums in the WordPress backend to see all of your forums ids.
Same thing with topics if you to assign topics for each post.
August 14, 2015 at 11:35 pm #165380In reply to: SMF Import Help Needed
Robkk
ModeratorSince you still need help on this. First do not import SMF to phpbb, just try leaving it in SMF and import from there. users have had problems importing from phpBB lately but not SMF.
You have to make sure you are not using a remote database.
Make sure to always check the import troubleshooting.
Run through this topic to see if you have any similar issues others may of have, and Stephen may have answered already.
August 14, 2015 at 11:20 pm #165378In reply to: New to bbPress – Help on Page Theme
Robkk
ModeratorYou need help with bbPress using a certain theme template?? Is that what you are saying??
This guide will help you (I hope), I am not entirely sure you want specifically though. I bet the information is useful to learn though.
August 14, 2015 at 6:59 pm #165369In reply to: Topics and replys exists and dont at the same time!
Robkk
ModeratorTry some troubleshooting, and also link to your site to a forum where the error occurs. Also tell me your WordPress and bbPress versions are.
August 14, 2015 at 12:55 pm #165359In reply to: View all posts across multiple forums
Robin W
Moderatoryou can use the shortcode [bbp-topic-index] in a new page – this will show the latest 15 topics across all forums with pagination.
August 14, 2015 at 5:31 am #165355In reply to: Limit tags to a pre-defined list?
strategeek
ParticipantHere is a working code. Hooray!
function displayTagElements($selectedTags, /* $userRole, */ $task){ $html= array(); $tags = get_categories(array('hide_empty' => 0, 'taxonomy' => 'topic-tag')); $selectedTagsArray = explode(',', $selectedTags); if($userRole != 'bbp_participant' || $task != 'edit') { $html[] = ""; foreach($tags as $tag) { $selected = ''; if (in_array($tag->name, $selectedTagsArray)) { $selected = 'checked'; } $html[] = "<input type='checkbox' name='bbp_topic_tags[]'".$selected." value=". $tag->name .">". $tag->name; } } else { $html[] = $selectedTags; } return implode('', $html);August 13, 2015 at 1:57 pm #165344In reply to: bbPress Shortcode
Robin W
ModeratorAugust 13, 2015 at 1:57 pm #165343In reply to: No Admin Sections Available
Robin W
ModeratorAugust 13, 2015 at 4:33 am #165334Topic: bbPress Shortcode
in forum InstallationAcs-Yt
ParticipantHi,
I was not able to find a shortcode like [bbPress_forum] to add a forum on a page. Is there a code available?
August 12, 2015 at 11:08 pm #165331In reply to: Getting only one comment
Robkk
Moderatorthe
bbpress.phptemplate looks fine to me.There might be other custom functions for bbPress somewhere though? or cache?
Try some troubleshooting. See if it is a plugin issue, issue is only present in your custom theme, and maybe run the repair tools to recalculate.
August 12, 2015 at 10:10 pm #165329In reply to: Limit tags to a pre-defined list?
23creative
Participantits been a while and im not 100% sure this will work (in terms of sanitation checks) but if you change
$html[] = '<select class="chzn-select" multiple="multiple" name="bbp_topic_tags[]" id="bbp_topic_tags">'; foreach($tags as $tag){ $selected = ''; if (in_array($tag->name, $selectedTagsArray)) { $selected = 'selected="selected"'; } $html[] = '<option '.$selected.' value="'.$tag->name.'">'.$tag->name.'</option>'; } $html[] = '</select>';to
foreach($tags as $tag){ $selected = ''; if (in_array($tag->name, $selectedTagsArray)) { $selected = 'checked="selected"'; } $html[] = '<input '.$selected.' type="checkbox" name="bbp_topic_tags" value="'.$tag->name.'">'.$tag->name; }i haven’t tested it but it should get you close
August 12, 2015 at 9:41 pm #165326In reply to: List subscribers of a forum
Robkk
Moderator@casiepa Thanks for creating a plugin to solve this problem for users. It is greatly appreciated. I have a few questions though.
How do I use it??
The setting are confusing me a little bit, and it doesn’t seem to show the subscriptions, but I do not really know where to manage them in the plugin. I just see a list of users with a button that says `[has role]’. I also do not think your plugin works for sub-forums/child forums of categories.
How does it work exactly??
I try to set it up, but I am still confused. Also there are a few errors while activating it with debug set to true in my wp-config.php file.
define('WP_DEBUG', true); -
AuthorSearch Results