Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'test'

Viewing 25 results - 4,951 through 4,975 (of 11,598 total)
  • Author
    Search Results
  • #143291
    Robin W
    Moderator

    Sorry, I failed to add the other bit of code you need !!

    The last paragraph should have read :

    …and then on your page template add this function where you want it.

    <?php if(is_front_page() ) { display_latest_topic () ; } ?>
    

    I’ve wrapped it in an if is_front_page statement so it only shows on the frontpage. You night need to use is_home instead depending on how your blog is set up.

    If you want it in the body, you should put it within the content div, either before or after the loop depending if you want it at the of or bottom of the page. You may need to play a bit !

    If any of that isn’t clear, do come back, but let me know what theme you’re using as well

    #143290

    In reply to: Creating a new forum

    tonyhir
    Participant

    1. Turning of all plugins would disable those which support custom post types, such as books and films, which are currently used on the site.

    2. It would also endanger the site’s security and expose it to hackers.

    3. This is all for the benefit of a plugin which I have not been able to test.

    4. All would be well if the site could be put into maintenance mode while plugins are disabled, or if I could work on a local copy. But I know nothing about these things. I see a number of maintenance mode plugins: can you recommend one?

    #143281
    Robin W
    Moderator

    ok, so drop the following into your functions file

    //  Display just latest topic
    function display_latest_topic() {  
    
    	$topics_query = array(
    					'post_type'           => bbp_get_topic_post_type(),
    					'post_parent'         => $settings['parent_forum'],
    					'posts_per_page'      => '1',
    					'post_status'         => array( bbp_get_public_status_id(), bbp_get_closed_status_id() ),
    					'ignore_sticky_posts' => true,
    					'no_found_rows'       => true,
    					'order'               => 'DESC'
    				);
    				
    	$lt_query = new WP_Query( $topics_query );
    		
    	while ( $lt_query->have_posts() ) {
    			
    		$lt_query->the_post();
    			$topic_id    = bbp_get_topic_id( $lt_query->post->ID );
    ?>
    <h2> Latest topic </h2>
    <h3> <a href="<?php bbp_reply_url(); ?>" class="bbp-reply-permalink"><?php bbp_topic_title($topic_id); ?></a></h3>
    		
    <div id="bbpress-forums">
    		
    		<div id="post-<?php bbp_reply_id(); ?>" class="bbp-reply-header">
    
    	<div class="bbp-meta">
    
    		<span class="bbp-reply-post-date"><?php bbp_reply_post_date(); ?></span>
    
    		<a href="<?php bbp_reply_url(); ?>" class="bbp-reply-permalink">#<?php bbp_reply_id($topic_id); ?></a>
    		
    	</div><!-- .bbp-meta -->
    
    </div><!-- #post-<?php bbp_reply_id(); ?> -->
    
    <div <?php bbp_reply_class(); ?>>
    
    	<div class="bbp-reply-author">
    
    		<?php bbp_reply_author_link( array( 'post_id' => $topic_id, 'sep' => '<br />', 'show_role' => true ) ); ?>
    
    		</div><!-- .bbp-reply-author -->
    
    	<div class="bbp-reply-content">
    
    		<?php bbp_reply_content(); ?>
    
    	</div><!-- .bbp-reply-content -->
    
    </div><!-- .reply -->
    </div><!--div bbpress-forums--->
    
    	<?php
    		
    	} }

    and then on your page template add this function where you want it. I’ve wrapped it in an if is_front_page statement so it only shows on the frontpage. You night need to use is_home instead depending on how your blog is set up.

    If you want it in the body, you should put it within the content div, either before or after the loop depending if you want it at the of or bottom of the page. You may need to play a bit !

    #143256

    In reply to: No toolbar available

    Liberty
    Participant

    Hello Robin,

    I’m missing this toolbar:
    dsrgdrg

    it’s not available on my site:
    dgdfrgdr

    I have the newest versions of WordPress and bbPress and have done this steps to fix this problem but nothing happened:

    I have deleted every JavaScript and tested it. Nothing!
    I deleted the code of the function.php. Nothing!
    I deactivated every plug-in. Nothing!
    …and the CSS can’t be the fault because the toolbar is not disabled. It’s not there.

    I opened my forum for guests and created a test forum. Now you can take a look on it: http://plusthemes.de/forum/test

    Thank you so much for your answer. I try to give as much information as possible. 🙂

    #143247
    jyd44
    Participant

    You are right. Having the same requirement, I was facing the same issue (and you will discover very soon that it is not the only one !).
    As far as I understand, the integration between bbPress and BuddyPress is not fully completed. In bbPress, the user capabilities based on their role in the forums are only mapped to WP capabilities. (see for example the function bbp_current_user_can_publish_replies() or bbp_current_user_can_access_create_reply_form() (invoqued in the form-reply.php part of the bbPress theme) in bbpress/includes/users/template.php .
    My way to overcome this issue is to add my own filter on the ‘bbp_current_user_can_publish_replies’ filter and to check in this function if the current_user is a member of the group associated with the root_forum (the one associated with the group) of the topic currently displayed.

    below my function:

    function my_bbp_current_user_can_publish_replies($input)
    	{
    		$topic_id = bbp_topic_id();
    		$root_forum = alsb_get_post_root_forum($topic_id);
    		$groups_id = bbp_get_forum_group_ids($root_forum);
    		$user_id = get_current_user_id();
    		if (groups_is_user_admin( $user_id, $groups_id[0])
    			|| groups_is_user_mod ($user_id, $groups_id[0]) 
    				|| groups_is_user_member ($user_id, $groups_id[0]) )
    			return true;
    		else return false;
    	}
    
    whith the help function
     	function alsb_get_post_root_forum($post_id)
    	{
    		$post = get_post($post_id);
    		do
    		{
    			$post = get_post($post->post_parent);
    		}while ($post->post_parent != 0);
    		return $post->ID;
    	}
    

    another way is perhaps to setup a filter on the ‘user_has_cap’ WP filter, but I did not test it.
    good luck for your integration !

    #143241
    surangaudimedia
    Participant

    @robin-w
    the latest topic and content. I dont need toshow replies. Just the last thread’s title and content. Thanks

    #143236
    Robin W
    Moderator

    Do you want :

    just the latest reply (or topic is no replies)
    The title or all the content?

    #143232

    In reply to: Creating a new forum

    Robin W
    Moderator

    then check for a plugin or theme conflict

    Check other plugins

    Check that no other plugins are affecting this.

    Turn off all other plugins, and see if that fixes the problem. If the problem is resolved, add back one at a time to see which is causing the conflict.

    Check themes

    If plugins are not the cause, the it may be a theme issue. Switch to a default theme, such as twentytwelve, and test.

    #143196

    In reply to: Titles – Roles

    Robin W
    Moderator

    ok, just tested and this code seems to work

    function add_custom_role( $bbp_roles ) {
     $bbp_roles['my_custom_role1'] = array(
    'name' => 'name 1',
    'capabilities' => bbp_get_caps_for_role( bbp_get_participant_role() ) // the same capabilities as participants
    
    );
     $bbp_roles['my_custom_role2'] = array(
    'name' => 'name 2',
    'capabilities' => bbp_get_caps_for_role( bbp_get_participant_role() ) // the same capabilities as participants
    
    );
    
     $bbp_roles['my_custom_role3'] = array(
    'name' => 'name 3',
    'capabilities' => bbp_get_caps_for_role( bbp_get_keymaster_role() ) // the same capabilities as keymaster
    
    );
    
    return $bbp_roles;
     }
     add_filter( 'bbp_get_dynamic_roles', 'add_custom_role', 1 );

    So this adds 3 roles, you/your experts can duplicate the code and add more or remove unnecessary.

    Basically you’ll just need to

    1. tell the what to put as the names – currently the new roles are name 1, Name2 and name 3 (where it says ‘name’ => ‘name 1’ , so they’ll just overwrite that with what you want.

    2. for each what capability. You’ll see the first two have the code bbp_get_participant_role() so that sets them to participant and the last sets to keymaster using bbp_get_keymaster_role() . You can guess that you just change the words for other roles such as spectator, or moderator.

    They need to add this to your theme’s functions file.

    please come back if any of this is not clear

    #143192

    In reply to: Titles – Roles

    Robin W
    Moderator

    I don’t like giving no answers so in between I have a little look, and found an answer from someone else on your second question ie adding roles with existing capabilities.

    I just need to test it, and I’ll be back.

    in the meantime if I said “add this code to your functions file” would you know what I mean?

    #143174
    Robin W
    Moderator

    I think you have got some display issues

    under IE, Firefox and Chrome (haven’t tested others) at 100% the submit buttons disappears. At 75% you see it. Do a zoom in and out to see the effect.

    Fix that and the checkbox will probably appear !

    #143173
    Robin W
    Moderator

    Do you want :

    just the latest reply (or topic is no replies)
    The title or all the body?
    Do you want it in the body or in a sidebar?

    #143171
    surangaudimedia
    Participant

    how can i show letest thred (only last one) on my home page template. http://codex.bbpress.org/shortcodes/ i tried all this short cods in this page but nothing worked.

    #143170

    In reply to: bbPress 2.5.3

    Robin W
    Moderator

    @surangaudimedia

    have you :

    Check other plugins

    Check that no other plugins are affecting this.

    Turn off all other plugins, and see if that fixes the problem. If the problem is resolved, add back one at a time to see which is causing the conflict.

    Check themes

    If plugins are not the cause, the it may be a theme issue. Switch to a default theme, such as twentytwelve, and test.

    come back once you done those of you still have a problem

    #143168

    In reply to: bbPress 2.5.3

    surangaudimedia
    Participant

    Hi..
    please help me to get bbpress latest post.’[bbp-single-view]‘ this shortcode are not working. how I get bbpress latest post to my home page.

    #143164
    Ricardo Bueno
    Participant

    The submit button is on the lower right. I need to change the color so that it stands out more. But yep, I’m able to fill out a new topic with content and hit submit.

    Example:
    http://www.contentsmartslab.com/membersite/forums/topic/testing/

    I just can’t subscribe to the thread. The checkbox still isn’t working.

    Robin W
    Moderator

    the url reads

    http://domain.com/whatever-your-shortcode-page-is-called/page/2/

    So presume your page is called “topics”

    The code works – I’ve just retested it on twentyten site and pagination and subsequent pages were fine, so suggest you try

    Check other plugins

    Check that no other plugins are affecting this.

    Turn off all other plugins, and see if that fixes the problem. If the problem is resolved, add back one at a time to see which is causing the conflict.

    Check themes

    If plugins are not the cause, the it may be a theme issue. Switch to a default theme, such as twentytwelve, and test.

    and then come back if you need further help.

    #143158
    Robin W
    Moderator

    Just check that it is not plugin related first

    Check other plugins

    Check that no other plugins are affecting this.

    Turn off all other plugins, and see if that fixes the problem. If the problem is resolved, add back one at a time to see which is causing the conflict.

    Then to confirm it is a theme problem..

    Check themes

    If plugins are not the cause, the it may be a theme issue. Switch to a default theme, such as twentytwelve, and test.

    Come back and let us know if you fixed, or for more help

    #143155
    Stagger Lee
    Participant

    If it works for others i must be making some mistake. Tried with default theme same problem. It is some test development with many, many WP and Bbpress plugins. Could be that some of them is blocking.

    #143152
    Ricardo Bueno
    Participant

    I’m setting up/testing bbPress on this URL:
    http://www.contentsmartslab.com/membersite/forums/forum/content-smarts/

    I can’t seem to check the box that says “notify me of follow-up replies via email.” I have the subscribe option properly setup on the back-end. I’m wondering if I messed up the input CSS somewhere here, or something else. Any thoughts?

    #143149
    Stephen Edgar
    Keymaster

    @stagger-lee I just tested the code from https://codex.bbpress.org/enable-visual-editor/ and it worked fine.

    You could also try the following as a plugin, it has options to enable the full editor, though it sounds like you don’t want this so don’t enable it.

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

    #143142
    Mycelus
    Participant

    I am using WAMP to make a test bed for my site and I am trying to install bbPress on my locally hosted site.

    However, when I install the plugin, it installs fine, but the forum pages give a 404…

    How do I go about doing this?

    #143131
    Robin W
    Moderator

    ok, so if you’re not miles down the redesign, I’d copy across your current site and then mod from there

    see

    https://codex.bbpress.org/creating-a-test-site/

    for a lot of detail on this.

    #143119

    In reply to: No toolbar available

    Liberty
    Participant

    Sorry for my late reply.


    @robin-w

    I have read the site you gave me but I can’t find a solution for my problem.


    @lynqoid

    I have deleted every JavaScript and tested it. Nothing!
    I deleted the code of the function.php. Nothing!
    I deactivated every plug-in. Nothing!
    …and the CSS can’t be the fault because the toolbar is not disabled. It’s not there.

    I don’t know what the problem could be. I hope someone can help me.

    #143114

    In reply to: Menu Error

    Robin W
    Moderator

    I don’t get to a forum on any of those links, presume you are still testing, so can’t answer the 401 message.

    : http://propertycrowdz.com/forums/forum/rentals/ is the way bbPress shows the url.

    There is some logic behind it, but it does annoy some people

    The general index comes up as mysite.com/forums
    but an individual forum is a forum called rentals hence forum/rentals that belongs to the forums index, hence forums/forum/rentals.

    You can turn this off – Dashboard>settings>forums go to forum root slug and uncheck the forum prefix.

    Below that you can change the names, so for instance you can have “support” instead of forums if you want.

    Come back if you still got a 401 error, and I’ll take a look.

Viewing 25 results - 4,951 through 4,975 (of 11,598 total)
Skip to toolbar