Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 14,126 through 14,150 (of 32,519 total)
  • Author
    Search Results
  • #135137
    remedy01
    Participant

    Hello,

    I am trying to add the logged in user’s forum topics to my BuddyPress site in a custom sidebar. I keep getting this error message:

    Fatal error: Call to undefined function bp_has_forum_topics()

    ..when inserting the following:

    <?php locate_template( array( 'forums/forums-loop.php' ), true ); ?>

    How can I easily list the logged in user’s forum posts without relying on the recent topics widget that ships with bbPress?

    Thanks

    #135133
    Robin W
    Moderator

    I hope this has a very simple solution.

    I need to either stop a BBpress template-tags function from happening, or over-ride it with a new one, but want to do this from a plugin, rather than amending BBpress code.

    Is there a line of code that simply stops a function within BBpress, or a quick way to overwrite one using a plugin.

    More detail below

    I want to revise the bbp_single_topic_description which is currently used in content-single-topic.php to show the phrase “This topic contains 2 replies, has 2 voices etc.” below a post

    The bbp_single_topic_description is defined in /includes/topics/template-tags.php

    I have written a pluggin that creates a new function, and uses the bbp_template_before_single_topic action hook in content-single-topic.php to display the new wording .

    ie

    add_action( 'bbp_template_before_single_topic',  'btv_single_topic_description');
    function btv_single_topic_description( $args = '' ) {
    	CODING STUFF;
    	}

    But I need to stop the old wording displaying as well as this.

    I have three approaches

    1. Just comment out the appropriate line in content-single-topic.php – simple to do, but of course gets overwritten by new releases
    2. Do something in the plugin that stops bbp_single_topic_description from working using code within my plugin – if this is easy, that is what I’d like to do, but as the function doesn’t have an action hook as far as I know, I don’t know how to remove it.
    3. Do something to make my function replace/overwrite the bbpress function, so that I don’t have to hook it anywhere?

    Can anyone help me with either 2 or 3 – I hope it’s an easy answer, but am stumped !

    #135131
    dbungard
    Participant

    I’m trying to make it so that only members of a certain s2member view specific styles in ONLY that forum. Please see below – it’s not working but Im not sure how to call the forum.

       <?php 
    	if (forum("professional-membership-2")){
    	if (current_user_can("access_s2member_level0")){ 
    echo '<style>
    .bbp-reply-form{display:none;}
    </style>';
    } elseif (current_user_can("access_s2member_level1")){
    echo '<style>
    .bbp-reply-form{display:none;}
    </style>';
    } elseif (current_user_can("access_s2member_level2")){
    echo '<style>
    .bbp-reply-form{display:none;}
    </style>';
    } elseif (current_user_can("access_s2member_level3")){
    echo '<style>
    .bbp-reply-form{display:none;}
    </style>';
    } else {
    }  
     }  ?>
    #135130
    cymnet
    Participant

    Hi there,
    I have recently installed bbPress on our site.
    It is a great feature.

    However,
    if you take a look at:
    http://cym.org/webmaster/support/forum/front-end-support/

    You will notice that the area where we can insert a new heading is covered up by the text editor.

    I cant find the code to amend the layout for this.

    Help!

    #135127
    bchhun
    Participant

    WordPress version: 3.5.2
    bbPress version: 2.3.2
    Number of plugins: 1 (bbpress)
    Active theme: Twenty-twelve
    Environment: Virtual machine built with Vagrant.
    Folder rights ?: All good.
    Have I fiddled with bbpress source code ?: not yet.

    I’m having the same issue as multiple topics I’ve seen here.

    The Nonce hidden field is in the form (inspected with Chrome dev tools) but I always get the “ERROR: Are you sure you wanted to do that?”

    Nonce error

    Unsal Korkmaz
    Participant

    Shortcode to display posts like ShowCase:
    http://theme.firmasite.com/showcase-shortcode/

    I would like to hear your suggestions on this. Please send a comment in post.

    #135102
    Nate
    Participant

    He’ll just tell you that the problem doesn’t exist.

    You know, when I mentioned it the 3 other times (along with another user that had the same complaint). Or the fact that any user can go in and edit (or delete) the bbPress codex pages.

    Nothing to see here, move along …

    #135092
    ignitionmedia
    Participant

    Update: I ended up added this to my fuctions.php and its a fix

    bbp_show_lead_topic

    #135073
    1. Remove the view=all query argument; does it work then?
    2. You’re not using the code from the codex page. $args['tinymce'] = true; is what turns the visual editor on.
    #135068
    tpcoopeer
    Participant

    Hi:

    I have a bad feeling that this is something that gets asked all the time and I just haven’t found the right search terms, but here it goes. Please just direct me to prior threads.

    If you visit my forum at: http://www.tnbizguide.com/forums/forum/tnbizguide-talk/

    You see that bbPress is being forced to wrap the menu and other items in awkward places instead of displaying everything on one line together that should be on one line?

    Is there any way to fix this a non-coder can handle? 🙂

    #135065
    Peter
    Participant

    I was able to fix this by using the following code:

    <?php if ( is_user_logged_in() ) { ?>
    
    <?php if ( bbp_show_lead_topic() ) : ?>
    		 
    <?php bbp_get_template_part( 'content', 'single-topic-lead' );	?>
                    			 
    <?php endif; ?>
    
    <?php } else { ?>
    					 
    <?php bbp_get_template_part( 'content', 'single-topic-lead' );	?>
                    			 		
    <?php } ?>
    #135063
    mcarrico
    Participant

    Two Questions:

    1. The Edit post button on the bar of the post is throwing a 404 error. It is trying to take me to the following url: http://intranet/index.php/forums/topic/the-cooking-thread/edit/?view=all and there does not seem to be a corresponding page. Is there something during initial setup that I missed to allow for this url to be populated upon post creation? I am still able to edit via the “Topics” area of the dashboard but I would like for this functionality to work for my users.

    2. I am trying to override the front-end post editor to be a rich editor. I have tried installing the tinyMCE plugin and replace the built in editor with the html tags via http://codex.bbpress.org/enable-visual-editor/ with the following code:
    function tmceeditor( $args = array() ) {
    $args[‘teeny’] = false;
    return $args;
    }
    add_filter( ‘bbp_after_get_the_content_parse_args’, ‘tmceeditor’ );

    but am having no luck. Again, the editor in the dashboard editor seems to be inheriting the tinyMCE functionality but I would like the user front-end to use this editor as well.

    Any help would be greatly appreciated.

    I am on WP 3.5.2 and bbPress 2.3.2 with a custom theme.

    #135062
    Peter
    Participant

    I edited content-single-topic.php and removed the ‘<?php if ( bbp_show_lead_topic() ) : ?>
    <?php endif; ?>` The post shows up when I click on the topic, but now if I login and click a topic the post displays twice. I am also using a child theme so I wont break anything.

    What I had before:

    <?php if ( bbp_show_lead_topic() ) : ?>
    
    <?php bbp_get_template_part( 'content', 'single-topic-lead' ); ?>
    
    <?php endif; ?>

    Hope this helps

    wallstreettrini
    Participant

    Why can i just remove the code attached to words in the front page?

    #135058
    Robin W
    Moderator

    I just added a new page called “forums” and put the text there.
    then put the forums index shortcode (bbp-forum-index put in square brackets) after it

    or is this not your problem?

    #135051
    akapope
    Participant

    Thanks for the help guys 🙂

    I figured it out, but thought I would update in case anyone comes across this as well. I admit this may not be the best solution; however it is working and I am happy.

    In the /wp-includes/post-template.php file, at line 427 I edited it to this:

    if ( is_single() ) {
    		$post_id = $wp_query->get_queried_object_id();
    		$post = $wp_query->get_queried_object();
    		$parent_id = get_post($post_id)->post_parent;
    
    		$classes[] = 'single';
    		if ( isset( $post->post_type ) ) {
    			$classes[] = 'single-' . sanitize_html_class($post->post_type, $post_id);
    			$classes[] = 'postid-' . $post_id;
    			$classes[] = 'parentforum-' . $parent_id;

    Where $parent_id = get_post($post_id)->post_parent;
    And $classes[] = 'parentforum-' .$parent_id;

    Are the additions.

    Then in the themes /style.css file I added something like:

    .parentforum-17,
    .postid-17 {
    background: #000000 url(http://alysiaworld.com/wp-content/uploads/2013/06/alysiasea.jpg) center top no-repeat fixed;
    }

    Boom Baby!

    #135048
    Chuck
    Participant

    Hi,
    I’m trying to add the forum’s description to be under the forum title on the page-front-forums (index) page. Just like it displays on the single-forum page. Could someone please show me the proper code?

    I’ve already changed the css .bbp-forums-list li to “display: block;”

    Thank you!
    Chuck S.

    #135047
    eonelson
    Participant

    I want to be able to have a form template that shows up when someone goes to post in a forum. i.e. I have a form for businesses to post if they have plants available. Instead of typing out the information in the forum, I would like a form to show up so they can just do drop downs or fill in the blanks.

    I’ve read lots of information, but some is a bit over my head so I’m not sure if I have found anything that will do this EASILY. I am not a coder, and do not feel comfortable editing code.

    Can a form be built in something like contact form 7 and then shortcoded in? I tried what I thought was that, and it didn’t work and not sure how to figure out what else to do.

    Thank you for all suggestions.

    Using WP 3.5.2, BBPress, 2.3.2 I don’t have a site that has anything to look at yet – just practicing for now.

    Thanks.

    eileen

    #135018
    Laughing Cat
    Participant

    +1
    I’m having the same issue, it only happens for non-admins on bbpress home archive, where I have latest topics and forum list shortcodes too (which work fine)

    has this issue been solved?

    #135014

    Topic: Featured slider

    in forum Plugins
    MoniqueR
    Participant

    Hello,

    I wonder if someone can help me out. For the last few days I am looking for a slider for my WordPress site. I am using the bbpress plugin. What I want to accomplish, what I am looking for is a featured slider which can display the latest topics and replys. I know there is a widget for it, but I would like to have it in a slide on my homepage. I cannot seem to find it. There a several beautifull sliders but they don’t support the option for adding topics and replys. They only work with latest posts/pages.

    Anybody who knows a plugin for this? (There are several which support custom content, but then I would have to right code for it, which I can’t.

    Hope someone can help me out.

    Regards,
    Monique

    #135010
    nickzee
    Participant

    I believe I have a good grasp of how bbpress and buddypress work together. My current setup is using bbpress as the forum and buddypress as the networking for members.

    My issue and questions are related to the links created by each of these plugins.

    Instead of linking to a forum archive page, I’ve created a separate page and am using short codes to add in the forum. I did it this way because I don’t like how WordPress (or the theme) adds “Archive” to the page header (in my case it’s “Forum Archive”). I also don’t like that Archive pages have limited sidebar options, and poor SEO (thanks to Yoast for making it better). But anyway, you can see I’m trying to stay away from the archive pages.

    The problem with my setup is the breadcurmbs above the forums. When navigation backwards, the breadcrumbs take you to the “forum archive”. Additionally, a link that is directly to a reply or topic, it is based off the forum archive. Foe Example:

    FORUM LINK: website.com/mvp-members/mvp-forums/ (shortcode method.)
    TOPIC/REPLY LINK: website.com/mvp-forums/topic/search-first/#post-18143

    Are there any tricks to getting these links to work seamlessly with each other? Or a different method of setting up the forums? Or any other advice?

    I appreciate it with thankfulness.

    #135008
    Rivac0m
    Participant

    So I followed what I thought was the correct order but it doesn’t seem to work as intended. Are we replacing all of loop-single-forum.php with the new code? or only a portion of it?

    Also if this is all theme related(minus the function call), couldn’t someone just upload their theme for others to use?

    #135007
    ZachMatthews
    Participant

    This is the answer I came up with and provided to some other people who have asked:

    Set Pinboard to 2 content columns, 2 Boxes Sidebar Columns, and 4 Footer Columns. Choose the first (farthest left) “Preferred Layout” option.

    Now, this is obviously going to dictate the look of the rest of your site. I got around that by doing a three-tier Multisite layout. It’s not hard to set up but it is a pain in the ass to have to re-install Pinboard and re-set every single option so the site is all the same, but that gives you the flexibility to have multiple different layouts and formats all within the same blog. I actually have one blog running my Blog, Articles, Podcasts, Video and About pages, then a second blog running my Photoblog database (which keeps the posts separate), and then finally the third blog running only bbPress. However, user profiles are integrated in a multisite so people stay logged in throughout the environment.

    One more thing to note: I moved the slider feature to my header by putting the slider section of the functions.php file actually in my search.php page, then deleting all other content from search. (My site only has search on the forums page). That makes the slider get called on each page first and you can tweak the menu layout and stuff to make it all appear up top. The only catch is the slider itself only works on the first page of a given blog (so it works on three of my pages). Everywhere else it is a static image, dictated by the oldest image chronologically amongst the slider pictures.

    Here’s my CSS:

    #slider .entry-title a {
    	display:none;
    }
    .flex-direction-nav, .flex-pauseplay {
    	display:none;
    }
    #bbpress-forums iframe, #bbpress-forums embed {
    	max-width: 640px !important;
    	height: 480px
    !important;
    	margin-left: 0px
    !important;
    }
    fieldset {
    	border: 0;
    }
    .fluid-width-video-wrapper {
    	padding-bottom: 20px !important;
    	padding-top: 53% !important;
    }
    .bbp-reply-content {
    	margin-left: 120px !important;
    }
    .bbp-topic-content {
    	margin-left: 120px !important;
    }
    #bbpress-forums div.bbp-the-content-wrapper textarea.bbp-the-content {
    	font-size: 15px !important
    }
    #bbpress-forums {
    	font-size:14px !important;
    }
    .bbp-topic-permalink {
    	font-size: 16px !important;
    }
    
    .bbp-reply-header a.bbp-reply-permalink {color: #00548c;}
    
    a.button.logout-link {
    	color:#f1f1f1 !important;
    	background-color: #111;
    }
    p {
    	font-size:14px;
    	margin-right: 20px;
    }
    button {
    	color:#fff !important;
    	background-color: #555;
    	padding: 6px 18px !important;
    	border-style: solid !important;
    	border-color: #000 !important;
    	border-width: 1px !important;
            border-radius: 5px;
    }
    input {
    	border: #9e9e9e 1px solid !important;
            border-radius: 5px;
            margin: 0 0 8px;
            box-shadow: inset 1px 1px 10px rgba(0, 0, 0, .2);
            background-color:#FCFCFC;
    }
    #sidebar-header {
    	float:none !important;
    	width: auto !important;
    	height: auto !important;
    	margin: 0 !important;
    	border-top: solid 1px #333 !important;
    	border-bottom: solid 1px #333 !important
    }
    #sidebar-header a {
    	padding:0 !important;
    }
    #bbpress-forums div.bbp-reply-header {
    	background-color:#c3c3c3;
    }
    .bbp-admin-links a {
    	color:#00548c !important;
    }
    
    .bbp-admin-links a:hover { 
    	color:#d54e21 !important;
    }
    #bbpress-forums ul.bbp-replies {
    	border: 1px solid #ccc;
    }
    #bbpress-forums .bbp-topic-content ul.bbp-topic-revision-log, #bbpress-forums .bbp-reply-content ul.bbp-topic-revision-log, #bbpress-forums .bbp-reply-content ul.bbp-reply-revision-log {
    	border-top: 1px solid #ccc;
    }
    #bbpress-forums .bbp-reply-content ul.bbp-reply-revision-log {
    	color:#666;
    }
    #bbpress-forums ul.bbp-reply-revision-log img.avatar {
    	margin-left: 3px;
    	margin-right: 3px;
    }
    .entry-content a img {
    	padding: 0;
    	margin-bottom: -3px;
    }
    .wp-editor-container {
    	border-color:  #aaa #aaa #aaa !important;
    }
    .quicktags-toolbar {
    	border-bottom: 1px solid #aaa !important;
    }
    #bbpress-forums ul.bbp-topics {
    	border: 1px solid #ccc;
    }
    .bbp-topics-front ul.super-sticky, .bbp-topics ul.super-sticky, .bbp-topics ul.sticky, .bbp-forum-content ul.sticky {
    	background-color: #f0f8ff;
    !important;
    }
    #bbpress-forums fieldset.bbp-form {
    	border: 1px solid #ccc;
    }
    #bbp_topic_title {
    	box-shadow: inset 1px 1px 10px rgba(0, 0, 0, .2);
    }
    #bbpress-forums div.bbp-the-content-wrapper textarea.bbp-the-content {
    	box-shadow: inset 1px 1px 20px rgba(0, 0, 0, .2);
    }
    input#bbp_topic_tags {
    	box-shadow: inset 1px 1px 10px rgba(0, 0, 0, .2);
    }
    .bbp-forum-title {
    	font-weight:400 !important;
            margin-left: 0px !important;
    }
    #bbpress-forums div.odd, #bbpress-forums ul.odd {
    	background-color: #f3f3f3;
    }
    #access {
    	background: #333 url(http://www.itinerantangler.com/global/body-bg12.png) repeat top left !important;
    	padding-left: 0 !important;
    	padding-right: 0 !important;
    }
    #access ul {
    	padding-left: 35px;
    }
    #bbpress-forums li.bbp-header {
    	background: #f1f1f1 url(http://www.itinerantangler.com/global/body-bg12.png) repeat top left !important;
    	border-top: none !important;
            width: 100%;
    }
    #footer-area {
    	background: #333 url(http://www.itinerantangler.com/global/body-bg12.png) repeat top left !important;
    }
    .entry-content a:hover {
    	color: #d54e21;
    }
    .entry-content a img, #attachment-nav a img {
    	border: none !important;
    	box-shadow: none !important;
    }
    .entry-content a:hover img, #attachment-nav a:hover img {
    	border: none !important;
    	box-shadow: none !important;
    }
    .onecol .onecol .entry-summary, .entry-content {
    	padding: 20px;
    }
    .entry-title {
    	margin-left: 20px;
    }
    .single .entry-title {
    	margin-left: 0 !important;
    	margin-bottom: -10px !important;
    }
    #bbpress-forums li.bbp-body ul.topic {
    	border-top: 1px solid #eee;
    	padding-top: 5px !important;
    	padding-bottom: 0px !important;
            padding-left: none !important;
            padding-right: none !important;
    }
    #bbpress-forums p.bbp-topic-meta {
    	margin: 0px 0 5px;
    }
    li.bbp-topic-title {
    	padding-left: 20px;
    
    }
    #url, #email {text-indent: 0px !important;}
    
    a.bbpl_button {width:25px !important;}
    
    #bbpress-forums li.bbp-body ul.forum, #bbpress-forums li.bbp-body ul.topic {padding-top: 8px;}
    
    #bbpress-forums li.bbp-header {padding-left: 0px !important;}
    
    li.bbp-forum-info {text-indent: 50px;}
    
    #bbpress-forums .bbp-forum-info .bbp-forum-content, #bbpress-forums p.bbp-topic-met {margin: 0px !important;}
    
    #bbpress-forums p.bbp-topic-meta img.avatar {margin-bottom: -3px !important;}
    #bbpress-forums div.bbp-template-notice img.avatar {margin-bottom: -3px !important;}
    
    li.bbp-header div.bbp-reply-content span#subscription-toggle {margin-right: 10px}
    
    div.bbp-template-notice, #bbpress-forums ul.bbp-replies, #bbpress-forums fieldset.bbp-form {border-radius: 5px !important;}
    
    .quicktags-toolbar {border-top-right-radius: 5px !important; border-top-left-radius: 5px !important;}
    
    #bbpress-forums fieldset.bbp-form input {padding: 3px;}
    #135004

    In reply to: Mark topic as closed

    weezies
    Participant

    Hello. Can you please advise which file the code above needs to be inserted in? I can definitely use this functionality. I’ve tried adding it in my theme’s functions.php but it doesn’t work there. Thank you!

    undsatca
    Participant

    I am currently trying do the same thing, set newest to oldest with the original topic post remaining on the top.
    I am a novice with code and CSS, and was curious where the code you provided for grex22 went. I am familiar with the .php location of bbpress, but can not find the information you posted.

    Thank you

Viewing 25 results - 14,126 through 14,150 (of 32,519 total)
Skip to toolbar