Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 10,051 through 10,075 (of 32,519 total)
  • Author
    Search Results
  • #155089

    Topic: CKEditor

    in forum Troubleshooting
    wenetwork
    Participant

    Hello there,

    I would like to integrate CKEditor with bbPress. I have already installed a plugin to integrate CKEditor with commenting wordpress related posts, but I have not found anything to make CKEditor visible with bbPress. Is there any way to add some code to core files? I am fairly new to to bbPress.

    #155080
    Icaroferreira
    Participant

    Hi,

    By posting messages on the forum, appears a code “# 1234” next to the date and time. How do I remove the forum posts this Code # …?

    Look this link: http://ajudaroproximo.com.br/wp-content/uploads/2014/12/forum-code.jpg

    Regards,
    Icaro

    izzyian
    Participant

    Wow thank you so much ! 🙂 … This is my loop replies php with the code in it, but I dont know if I put it in right because even though it shows, it does not appear in the same row as subscribe and favorites but rather a little above the row, and any css i added did not help.

    <?php do_action( 'bbp_template_before_replies_loop' ); ?>
    
    <div id="topic-post-list" class="item-list" role="main">
    
    <div class="forum-head-reply-tools">
    
     <a class="bbp-backto-forum" href="<?php bbp_forum_permalink(); ?>">Back to <?php bbp_forum_title(); ?></a> <?php bbp_user_subscribe_link('before=&nbsp;'); ?> <?php bbp_user_favorites_link(); ?></div>
    <div class="clear"></div>
    
    <ul>
    		<?php while ( bbp_replies() ) : bbp_the_reply(); ?>
    
    			<?php bbp_get_template_part( 'loop', 'single-reply' ); ?>
    
    		<?php endwhile; ?>
    </ul>
    </div><!-- #topic-<?php bbp_topic_id(); ?>-replies -->
    
    <?php do_action( 'bbp_template_after_replies_loop' ); ?>

    Here is a picture of the row so you can see the new button is a little above the row
    http://bitfiu.com/wp-content/uploads/2014/12/button-example.png

    Robkk
    Moderator

    well i think i got all of those add action things wrong 🙁

    i got confused with them and thought they were before the favorte/subscription links

    but they were for the user favorites/subscription lists on their profile.

    this function should show it but it will be before the replies loop this function should be in your functions.php in your child theme

    function rkk_forum_link_before_replies() {
    
     if ( bbp_is_single_topic() ) {
    
        	?>
    		
        <a class="bbp-backto-forum" href="<?php bbp_forum_permalink(); ?>">Back to <?php bbp_forum_title(); ?></a>
     
        	<?php
    
        }
    
    }
    
    add_action( 'bbp_template_before_replies_loop', 'rkk_forum_link_before_replies' );

    this is for manually putting the link before the favorite link in loop-replies.php template file in your child theme.

    <a class="bbp-backto-forum" href="<?php bbp_forum_permalink(); ?>">Back to <?php bbp_forum_title(); ?></a>

    izzyian
    Participant

    @robkk,

    Thank you for that here is a little more info because i don’t understand where to place that code:

    What I want to do is add a button ( which I will later style in my css) that will just take the user back to the forum (basically a button that is a breadcrumb).

    I would place all the information here but bbpress reply box is not letting me for some reason. But you can read the information here where I placed it in the wrong section before I asked it here https://buddypress.org/support/topic/how-do-i-add-a-button-in-loops-replies-php-file/

    #155068
    Serch1
    Participant

    Hello Robkk! Thanks a lot for your detailed suggestion. I know this way to delete users from wordpress backend, but I’m looking for the function who does this in order to add a little code to my bbpress frontend 🙂

    Robkk
    Moderator

    you can use any of these hooks to add a button there using a function

    add_action( 'bbp_theme_after_topic_subscription_action' ); 
    
    add_action( 'bbp_theme_before_topic_subscription_action' ); 
    
    add_action( 'bbp_theme_after_topic_favorites_action' ); 
    
    add_action( 'bbp_theme_before_topic_favorites_action' ); 

    more info on using action hooks

    Step by step guide to setting up a bbPress forum – part 4

    #155065
    Robkk
    Moderator

    to enable visual editor install this plugin

    https://wordpress.org/plugins/bbpress-enable-tinymce-visual-tab/

    to remove the code button use this
    add it to your child themes functions.php or a functionality plugin.

    add_filter( 'bbp_after_get_the_content_parse_args', 'rkk_bbp_edit_quick_editor' );
    function rkk_bbp_edit_quick_editor( $args = array() ) {
    	$args['quicktags']         = array( 'buttons' => 'strong,em,link,block,del,img,ul,ol,li,close' );
    
       return $args;
    }
    #155063
    Robkk
    Moderator

    @korobochkin

    in the trac they are trying to add this feature and at least an option to disable it.

    -started 2010 -last reply 3 months ago
    [bbpress.trac.wordpress.org/ticket/1430]

    if you do not want pingbacks and trackbacks remove any code that is for the comments section when you create a bbpress.php and see if that fixes it.

    #155061
    Robkk
    Moderator

    try this

    add it anywhere you add custom css

    #bbpress-forums .bbp-body div.bbp-reply-author {
    	margin: -15px 10px 10px;
    	min-height: 100px;
    	padding-left: 80px;
    	position: relative;
    	text-align: left;
    	width: 100%;
    }
    
    #bbpress-forums div.bbp-reply-author a.bbp-author-name {
    	clear: none;
    	display: inline-block;
    	margin-left: 0;
    	word-wrap: break-word;
    }
    
    #bbpress-forums div.bbp-reply-author img.avatar {
    	position: absolute;
    	top: 15px;
    	left: 0;
    	width: 60px;
    	height: auto;
    }
    
    #bbpress-forums div.bbp-reply-author .bbp-author-role {
    	font-size: 12px;
    	font-style: normal;
    }
    
    #bbpress-forums .bbp-body div.bbp-reply-content {
    	clear: both;
    	margin: 10px;
    	padding: 0;
    }
    #155056
    Robkk
    Moderator

    @satanicdogooder

    did you add these too?? it seems like its the only thing your missing when i checked your website.

    /* try to make these two different types of dark shades if you care about having an AB color pattern of replies/topics/forums. */
    
    #bbpress-forums div.odd, 
    #bbpress-forums ul.odd {
    background-color: inherit;
    }
    
    #bbpress-forums div.even, 
    #bbpress-forums ul.even {
    background-color: inherit;
    }
    #155055
    petriknz
    Participant

    In the editor I need to, at the very least remove the code button.

    Is there any way to use the default WordPress Editor where users can see the visual results of their editing instead of the html markup text.

    Users of the forum I’m creating are not HTML coders and the way this works will totally confuse them. Also switching it off in settings makes matters worse as then they are presented with an instruction box showing the HTML tags.

    #155053
    Robkk
    Moderator

    Is it a secret or something?

    no i pretty much told you that its might be just switching the loop-single-topic.php file in your child theme with the original bbpress plugin version if you wanted the smaller avatars.

    if it still looked weird the rest would’ve been just fixing a couple of lines of CSS

    to completely remove them you would need to hand me a link to your site and I’ll give you a little CSS which will allow you to remove them.

    you can also just remove the avatars with PHP

    but just adding this code should work on an original bbPress loop-single-topic template.

    .avatar-14 { display: none !important; }

    #155049
    colinsp
    Participant

    I have used the code in the documentation to turn on the visual editor and it is working fine.

    However, when you start or reply to a topic neither editor is selected by default. Is it possible to enable the Visual Editor by default? If not is there any way to remove the text editor so that visual is the only option and hopefully that will select by default?

    #155031
    SatanicDogooder
    Participant

    Hi those codes worked great on the bbpress forum paage! However they did not translate to the topics section. I added them to my child Css.styles.
    http://satanicdogooder.com/forums/topic/a-good-deed-aric-u/#new-post
    Any idea why the background of these pages did not take to the CSS change?
    Thx,
    The DoGooder

    #155016
    joop.stringer
    Participant

    I just ran a very simple query over the user table
    Update wpusers set user_nicename = REPLACE( user_nicename , ‘ ‘, ‘-‘ ) ;

    This did the trick for me … It must be possible for bbPress to have the space replaced by a hypen in the function to create the userprofile link …

    #154989

    In reply to: mysite.com/forums

    Robin W
    Moderator
    #154988
    Robin W
    Moderator

    easiest way would be to run some code through to correct – since you are asking, I expect this is beyond your skillset so suggest you post a request on

    http://jobs.wordpress.net/

    It should be a fairly cheap solution – code would be less than 20 lines !

    #154987
    Robin W
    Moderator

    ok,

    1. what two plugins did you try that didn’t work?
    2. have you been through https://codex.bbpress.org/step-by-step-guide-to-setting-up-a-bbpress-forum/
    3. Does it work if you disable s2member – just a test to see if it is a conflict
    4. what permalink are you running – dashboard>settings>permalinks
    5. What bbpress slugs are you running – dashboard>settings>forums

    #154982
    johnmontfx
    Participant

    I’m migrating from a vbulletin forum (3.x) and I’ve figured out how to do a bit of customization, bringing over custom fields in the user table. But one thing I’m having a tough time figuring out is how to bring in the first_name and last_name to the usermeta table.

    For some reason, the following does not work:

    		// fx: last name Stored in usermeta)
    		$this->field_map[] = array(
    			'from_tablename' => 'user',
    			'from_fieldname' => 'lastname',
    			'to_type'        => 'user',
    			'to_fieldname'   => 'last_name'
    		);

    But the following does:

    		// fx: last name Stored in usermeta)
    		$this->field_map[] = array(
    			'from_tablename' => 'user',
    			'from_fieldname' => 'lastname',
    			'to_type'        => 'user',
    			'to_fieldname'   => 'fx_last_name'
    		);

    Simply by changing “last_name” to “fx_last_name” it works. I’d prefer to have it bring it in as the WordPress defaults. I understand I can force a move into the correct field once I import, but as I’ll have about 24 hours on the migration day, i’d love to get it accomplished in the import script.

    Thanks for any insights.

    #154980
    nsbp001
    Participant

    Perhaps this is the solution, found at https://gist.github.com/sc0ttkclark/e5de9d9f2f13964bcecc
    Code to enable having the main bbPress forums on a separate sub-site. Requires: WP Multisite, BuddyPress on main site and network-activated, bbPress on main site and sub-site

    <?php
    /**
    * Remove and add a custom function for bbPress’ BuddyPress activity filter
    */
    function custom_bbp_notifications_fix() {
    if ( !defined( ‘BBPRESS_FORUMS_BLOG_ID’ ) || !BBPRESS_FORUMS_BLOG_ID ) {
    return;
    }
    remove_filter( ‘bp_notifications_get_notifications_for_user’, ‘bbp_format_buddypress_notifications’, 10, 5 );
    add_filter( ‘bp_notifications_get_notifications_for_user’, ‘custom_bbp_format_buddypress_notifications’, 10, 5 );
    add_action( ‘bbp_template_before_user_topics_created’, ‘custom_bbp_switch_to_forums’ );
    add_action( ‘bbp_template_before_user_replies’, ‘custom_bbp_switch_to_forums’ );
    add_action( ‘bbp_template_before_user_favorites’, ‘custom_bbp_switch_to_forums’ );
    add_action( ‘bbp_template_before_user_subscriptions’, ‘custom_bbp_switch_to_forums’ );
    add_action( ‘bbp_template_after_user_topics_created’, ‘custom_bbp_switch_from_forums’ );
    add_action( ‘bbp_template_after_user_replies’, ‘custom_bbp_switch_from_forums’ );
    add_action( ‘bbp_template_after_user_favorites’, ‘custom_bbp_switch_from_forums’ );
    add_action( ‘bbp_template_after_user_subscriptions’, ‘custom_bbp_switch_from_forums’ );
    }
    add_action( ‘init’, ‘custom_bbp_notifications_fix’ );
    /**
    * Format the BuddyBar/Toolbar notifications
    *
    * @since bbPress (r5155)
    *
    * @package bbPress
    *
    * @param string $action The kind of notification being rendered
    * @param int $item_id The primary item id
    * @param int $secondary_item_id The secondary item id
    * @param int $total_items The total number of messaging-related notifications waiting for the user
    * @param string $format ‘string’ for BuddyBar-compatible notifications; ‘array’ for WP Toolbar
    */
    function custom_bbp_format_buddypress_notifications( $action, $item_id, $secondary_item_id, $total_items, $format = ‘string’ ) {
    if ( ‘bbp_new_reply’ == $action ) {
    custom_bbp_switch_to_forums();
    $action = bbp_format_buddypress_notifications( $action, $item_id, $secondary_item_id, $total_items, $format );
    custom_bbp_switch_from_forums();
    }
    return $action;
    }
    /**
    * @var boolean $custom_bbp_switch
    */
    global $custom_bbp_switch;
    /**
    * Switch to forums blog, if it’s not the current blog
    */
    function custom_bbp_switch_to_forums() {
    global $custom_bbp_switch;
    $custom_bbp_switch = ( get_current_blog_id() != BBPRESS_FORUMS_BLOG_ID );
    if ( $custom_bbp_switch ) {
    // Switch to forum site
    switch_to_blog( BBPRESS_FORUMS_BLOG_ID );
    }
    }
    /**
    * Switch back to current blog, if not the forums blog
    */
    function custom_bbp_switch_from_forums() {
    global $custom_bbp_switch;
    if ( $custom_bbp_switch ) {
    restore_current_blog();
    }
    $custom_bbp_switch = false;
    }

    #154978
    Doulacare
    Participant

    Hi,
    I am volunteering on a not for profit site running wordpress 4.0.1, bbpress 2.5.4, s2member pro 141007

    I have yet to be able to see any of the forums, topics etc as all I get is a 404 error. I have ready through the info about this issue and tried everything suggested, including the two plugins that are supposed to fix it to no avail.

    I do have pretty links turned on, I do have a “Forums” page and have tried it with and without a shortcode to pull up the forums and it just shows the shortcode and never the forum. The only way I get get anything to show is to use the “ugly” link to the forums but none of the links work from
    http://ontariodoulas.org/?post_type=forum

    Any ideas on where to go from here? Any help would be appreciated! Thank you!

    #154977

    In reply to: phpBB import problem

    Joukku
    Participant

    no.. frustrating. Any clue?

    Repair any missing information: Continue
    Warning: set_time_limit() has been disabled for security reasons in /home/int2000/d/xxxxx/html/wordpress/wp-content/plugins/bbpress/includes/admin/converter.php on line 306
    
    WordPress database error: [Unknown column 'forums.forum_topics' in 'field list']
    SELECT convert(forums.forum_id USING "utf8") AS forum_id,convert(forums.parent_id USING "utf8") AS parent_id,convert(forums.forum_topics USING "utf8") AS forum_topics,convert(forums.forum_posts USING "utf8") AS forum_posts,convert(forums.forum_topics_real USING "utf8") AS forum_topics_real,convert(forums.forum_name USING "utf8") AS forum_name,convert(forums.forum_desc USING "utf8") AS forum_desc,convert(forums.left_id USING "utf8") AS left_id,convert(forums.forum_type USING "utf8") AS forum_type,convert(forums.forum_status USING "utf8") AS forum_status FROM phpbb_3forums AS forums LIMIT 0, 100
    
    No forums to convert
    Warning: set_time_limit() has been disabled for security reasons in /home/int2000/d/xxxxx/html/wordpress/wp-content/plugins/bbpress/includes/admin/converter.php on line 306 Warning: set_time_limit() has been disabled for security reasons in /home/int2000/d/xxxxx/html/wordpress/wp-content/plugins/bbpress/includes/admin/converter.php on line 306 Warning: set_time_limit() has been disabled for security reasons in /home/int2000/d/xxxxx/html/wordpress/wp-content/plugins/bbpress/includes/admin/converter.php on line 306 
    
    No data to clean
    
    Starting Conversion
    #154970
    Joukku
    Participant

    Hi all,

    I’ve been trying to import my forum from phpbb 3.1.1 (no mod or themes) to bbpress 2.5.4.

    I used row limits 50 and delay time 2. Database settings looks to be ok.

    Problem is following code that appears on every line:
    ‘Warning: set_time_limit() has been disabled for security reasons in /home/int2000/d/xxxxx/html/wordpress/wp-content/plugins/bbpress/includes/admin/converter.php on line 306 Warning: set_time_limit() has been disabled for security reasons in /home/int2000/d/xxxxx/html/wordpress/wp-content/plugins/bbpress/includes/admin/converter.php on line 306’

    Conversion goes till end and following message will appear:
    ‘Repair any missing information: Continue’
    ‘SELECT convert(forums.forum_id USING “utf8”) AS forum_id,convert(forums.parent_id USING “utf8”) AS parent_id,convert(forums.forum_topics USING “utf8”) AS forum_topics,convert(forums.forum_posts USING “utf8”) AS forum_posts,convert(forums.forum_topics_real USING “utf8”) AS forum_topics_real,convert(forums.forum_name USING “utf8”) AS forum_name,convert(forums.forum_desc USING “utf8”) AS forum_desc,convert(forums.left_id USING “utf8”) AS left_id,convert(forums.forum_type USING “utf8”) AS forum_type,convert(forums.forum_status USING “utf8”) AS forum_status FROM phpbb_3forums AS forums LIMIT 0, 100’

    What am I doing wrong?

    #154953
    robertosalemi
    Participant

    Resolved.

    function remove_buddypress_admin_bar_init() {
    	echo '<style type="text/css">
    		div#wp-toolbar > ul#wp-admin-bar-top-secondary > li#wp-admin-bar-my-account > div.ab-sub-wrapper > ul#wp-admin-bar-my-account-buddypress {
    			display: none !important;
    		}
    	</style>';
    }
    
    add_action( 'init', 'remove_buddypress_admin_bar_init' );

    Thanks! 😉

Viewing 25 results - 10,051 through 10,075 (of 32,519 total)
Skip to toolbar