Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 18,251 through 18,275 (of 32,499 total)
  • Author
    Search Results
  • #106604
    janoochen
    Member

    @ideoplasm Adding a voting or rating system into bbPress 2.0 is extremely easy.

    You can use this plugin: https://wordpress.org/extend/plugins/wp-postratings

    or this one: http://www.gdstarrating.com/

    Then just add the rating function in loop-topics.php (inside the loop).

    You can do the same for loop-replies.php

    I’m working in a voting forum myself.

    This is an example:

    <div class="topic-rating-count">
    <h4><?php if(function_exists('the_ratings')) { the_ratings(); } ?></h4>
    <span><?php _e( 'rating' ); ?></span>
    </div>
    <div class="topic-reply-count">
    <h4><?php bbp_topic_reply_count(); ?></h4>
    <span><?php _e( 'replies' ); ?></span>
    </div>
    <div class="topic-freshness">
    <h4><?php bbp_topic_freshness_link(); ?></h4>
    <span> <?php bbp_author_link( array( 'post_id' => bbp_get_topic_last_active_id(), 'size' => 14 ) ); ?>
    </span>
    </div>

    #38731
    The 12th Doctor
    Participant

    Can the plugins on the site be used on the 2.0 beta forum as well? Do i just do as i normally would and upload them to my plugins folder?

    Thanks

    Jon :)

    #38727
    janoochen
    Member

    This is how I start a custom loop for a WordPress loop:

    <br />
    <?php $custom_posts = new WP_Query(); ?><br />
    <?php $custom_posts->query('post_type=post&category=Uncategorized&order=ASC'); ?><br />
    <?php while ($custom_posts->have_posts()) : $custom_posts->the_post(); ?><br />
    <div class="project"><br />
    <a>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentyten' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_post_thumbnail(); ?></a><br />
    <h2><a>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentyten' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h2><br />
    <p><?php echo get_post_meta($post->ID, 'rw_services', true); ?></p><br />
    </div><br />
    <?php endwhile; ?><br />

    How to start a custom loop in bbpress 2.0, For example, topics from a certain forum or category? (and even show the reply count?)

    #106622
    Anointed
    Participant

    It is really hard to troubleshoot the problem with a link to the site itself. Need to read the code output to see what is happening

    #106631
    Anointed
    Participant

    edit the buddypress.css file line 1218

    table.forum {
    margin: -9px 0 20px;
    width: auto;
    }

    If you are using a child theme then it is better to make the change there, as every time buddypress is updated you will loose the rule above.

    #38714
    freque.unce
    Member

    Hi, I’ve just installed bbpress and I’m having problems with table spacing. The first few letters get cut off in the main index, I’m left with “opic Title” instead of “Topic Title”, and the thread titles are missing the first 2 letters as well. I’ve done a string search for “topic title” in the bbpress directory, but I can’t seem to find the related code. Any advice on how to fix this problem?

    http://www.noisechannel.org/forums/

    Wordpress 3.1.3

    BuddyPress 1.2.8

    BP-Framework 0.3.6

    Thank you! :)

    tooltrainer
    Member

    Cool, glad to hear there might be a fix for this even if it is somewhat obscure.

    And yeah, “too quickly”… I was gonna give you a pass on that one though… ;)

    Jonathan

    Probably should say “too quickly” but who’s counting? :)

    I’ll take a look. I imagine it’s a current_time() gmt issue. Might not make it into Beta 3, but it’s on the radar.

    tooltrainer
    Member

    OK, turns out he’s in Israel! So whatever timezone that is, I’m not sure. He’s an American so I had assumed he’s in the US but, obviously not.

    Any idea how this could be causing the speed errors?

    Also the grammar in that error message needs a little fix… “to” instead of “too”. :)

    Jonathan

    #106250
    Nate
    Participant

    i’d like to add to this if possible, as i think i’m encountering the same problem as leemon. if my custom theme is doing a bit’o hijacking with the css, where would i find and disable this body class code?

    #38703
    valked1n
    Member

    SQL ERROR!

    >>> Database: xxxxxxxxxxx (localhost)

    >>>>>> CREATE TABLE IF NOT EXISTS bb_posts (

    post_id bigint(20) NOT NULL auto_increment,

    forum_id int(10) NOT NULL default 1,

    topic_id bigint(20) NOT NULL default 1,

    poster_id int(10) NOT NULL default 0,

    post_text text NOT NULL,

    post_time datetime NOT NULL default ‘0000-00-00 00:00:00’,

    poster_ip varchar(15) NOT NULL default ”,

    post_status tinyint(1) NOT NULL default 0,

    post_position bigint(20) NOT NULL default 0,

    PRIMARY KEY (post_id),

    KEY topic_time (topic_id, post_time),

    KEY poster_time (poster_id, post_time),

    KEY post_time (post_time),

    FULLTEXT KEY post_text (post_text)

    ) TYPE = MYISAM DEFAULT CHARACTER SET ‘utf8’;

    >>>>>> You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘TYPE = MYISAM DEFAULT CHARACTER SET ‘utf8” at line 16

    Key master email not sent!

    I am using XAMPP and I tried to integrate it with WP which I installed it into the same database.

    can anyone please help me ?

    Pomy
    Participant

    zaerl you didn’t say anything for my sad mood..?

    OK, your solution is really difficult for me… Can you make it more easy? I cannot write a plugin, that’s why I’m here to looking for your kind help… can you do it for me? I’ll really appreciate.

    I’m also frustrated from bbPress as Plugin like other senior bbPress developers. But I hope there will always remain a good space for bbpress standalone lovers. Matt cannot ignore it. I hope :)

    — OK, let me ask above question with another angle…

    Is it possible to make pagination just for forums on a custom page? if it is difficult to show on front page? something like

    http://www.blog.com/forums/view-all-forums.php ? – just an idea?

    And I just thought that I’ll also need pagination for forums in admin setting and for zearl visiblity setting near future when I’ll have thousands of forums. (user/forum)

    Please see the following screenshots, to understand what I’m taking about..

    — For Forums Pagination in Admin Setting — Screenshot

    — For Forum Pagination in Zaerl Visibility setting — Screenshot

    I know its a little big job for you. But can you do it for me? It’s really important, I’ll really appreciate your kindness if you will make a plugin or easy script for this solution.

    — and I also know your time is really precious, And time is money… can you give me your personal contact email? So that we can discuss about it further?

    I hope I’ll try to mange your time. Thanks Again.

    #106602

    I’d use a custom taxonomy, and a creative UI. Seems it could be done pretty easily with the right developer. :)

    Daaaaaave
    Member

    John removing the bb config file fixed it straight away.

    you sir are a genius or i am moron ;)

    If you ever come to Australia ill buy you a beer.

    #95516
    traveljunkie
    Member

    Haven’t found the time to look into it in depth yet, so in the meantime I sorted things with these two functions:

    /**
    * Search only our forums and fix topic tags
    * @since 1.0
    */
    function click_help_add_to_search( $query )
    {
    if( $query->is_search )
    $query->set( 'post_type', array( 'topic', 'reply' ) );

    if( ! empty( $query->query_vars['topic-tag'] ) )
    $query->set( 'post_type', array( 'topic' ) );

    return $query;
    }
    add_filter( 'pre_get_posts', 'click_help_add_to_search' );

    /**
    * Remove error404 class from the body
    * @since 1.0
    */
    function click_help_remove_error404( $classes )
    {
    if( in_array( 'bbPress', $classes ) )
    {
    $error = array_search( 'error404', $classes );
    unset( $classes[$error] );
    }

    return $classes;
    }
    add_filter( 'body_class', 'click_help_remove_error404' );

    #100807

    In reply to: Where is the importer?

    Laurens Offereins
    Participant

    Found out it’s got something to do with my earlier conversion from phpbb to bbpress standalone. But it still got me confused:

    All the logins work perfectly after the first conversion (phpbb > bbpress 1.0), but after conversion from 1.0 to 2.0 all the logins block. Only accounts newly created in 1.0 get through in 2.0.

    In the database there’s a visible difference between logins from phpbb (start with $H$7) and bbpress 1.0 (start with $P$9). Since there is no login error in bbpress 1.0 I don’t think it’s a problem with the phpbb conversion (used this converter recommended somewhere on this forum).

    Can someone give me a hint on how to solve this?

    #105907

    In reply to: Where is the importer?

    Laurens Offereins
    Participant

    Found out it’s got something to do with my earlier conversion from phpbb to bbpress standalone. But it still got me confused:

    All the logins work perfectly after the first conversion (phpbb > bbpress 1.0), but after conversion from 1.0 to 2.0 all the logins block. Only accounts newly created in 1.0 get through in 2.0.

    In the database there’s a visible difference between logins from phpbb (start with $H$7) and bbpress 1.0 (start with $P$9). Since there is no login error in bbpress 1.0 I don’t think it’s a problem with the phpbb conversion (used this converter recommended somewhere on this forum).

    Can someone give me a hint on how to solve this?

    Pomy
    Participant

    :-(

    #95512
    traveljunkie
    Member

    I’ve copied the template files across to the theme. There’s only minimal adjustments been made. It’s on my local machine, so can’t provide a link. Here’s a bit more info. It’s on a subdomain on a multisite installation.

    Just found out that the topic tags template never shows any topics and there’s quite a few tagged topics.

    I’ll dig a bit deeper into the code and let you know when I find something.

    #95511

    Just making sure since you said “trunk” :)

    What theme are you using? Can you link me to your site to see what’s happening? I just checked my installs with bbp-twentyten or using theme compat, and can’t duplicate.

    #95510
    traveljunkie
    Member

    SVN plugin branch. This is a topic for it after all ;)

    kai920
    Member

    I’m against the idea of using wp_register(); since it redirects you to wp-login.php to sign-up instead of using a registration page in the theme. Also, the idea with community sites like bbPress and BuddyPress, is usually to keep members out of the admin area. Promoting them to enter it seems counter intuitive.

    Thanks, I missed the part where you mentioned integrating the register/login pages into bbP. Looking forward to more discussion and potential solutions on this.

    Would wp_register() not actually display an admin link, since we’d only use it if ( !is_user_logged_in() )?

    #95505
    Spiralspeaks
    Member

    I figured it out.. uploaded another theme, edited and it works.. added some tweaks in the theme functions viola good combination :)

    Home › Forums › Happy Talk › Why choose bbpress?

    Forums › Happy Talk › Why choose bbpress?

    #106569
    Paul Gregory
    Member

    Assuming you’ve already added a blank page with the slug ‘forums’:

    Change the page template to “bbPress – Forums (Index)”

    OR

    Include the shortcode [bbp-forum-index] in your page text

    Also, go to the Permalinks page if you haven’t recently so everything else works.

    See also https://bbpress.org/forums/topic/bbpress-20-theme-compatibility

    There are a number of other things you’re probably going to have to do. I’m working on a checklist.

    Paul Gregory
    Member

    Yeah, that specific function’s not at all the right one, it seems to be a well-meaning but naive tip on kai920’s part.

    But the basic idea of having a Register link within the bbPress Login Widget is sound, and I’m a bit concerned that it seems to be problematic.

    There needs to be a good bundled method of having a link to Register that does NOT show up when a user is already logged in, and the Login Widget is the most logical place to put it. (Obviously it’s trivial to add a Register link to a menu or widget area that would be present all the time).

    Two naff, but workable, solutions:

    1) Add a field in the bbPress Login Widget for the registration page URL, with “/wp-login.php” set as the default. When the Login Widget is displaying the Log In details, display the registration link (if not blank and if registration is enabled). When the Login Widget is displaying the current user details and log out link, don’t show the registration link.

    2) Encourage users to install a pair of simple widgets. I don’t know if decent ones exist, but they’d be called something like Logged In Text and Not Logged In Text, which as their names suggest are like Text widgets but only show their contents if is_user_logged_in() condition is true or false. It’s then simple to add a Register link or whatever to a Not Logged In widget, which could be placed above or below the bbPress Login Widget. If I can’t find an existing pair I’ll knock them out myself soon, although I suspect what I’ll end up doing on most sites is conditionally displaying one entire sidebar or another.

    The reason both are naff is that it seems pretty clear that there should be a function or method that returns the correct (custom) login page, and the absence of it is causing problems.

    Is WP completely unaware of custom registration pages? It seems so. There should be somewhere central that the URLs (or page IDs) of custom Register and Login pages etc are set – and that this should be site based rather than theme based, much like you can set the front page and posts page in WP Reading Settings.

    Of course, that’s arguably a WP issue not a bbP issue, but bbP as plugin is at liberty to extend WP in useful ways because that’s what plugins do.

    From what you’re saying it sounds like this isn’t part of immediate bbP plans.

    I don’t know whether I’m missing a setting, or if it’s something you’ve fixed since b2 but: having registered using a bbPress registration page, the email that people get with their password includes a link to /wp-login.php rather than my /log-in page that uses the bbPress login template. Using that leaves people in an inappropriate interface that they are probably not intended to see, and will confuse (and lose) users.

    Am I expected to override this myself with a plugin or in my template? That would mean hard-coding page references. It doesn’t seem right.

    I think bbP should just bite the bullet and allow users to specify their login and register pages under Settings. And indeed specify the View Profile page etc. It seems to me that bbP really needs to know where the login page is, and searching for a page with either the bbPress Login template or the Login shortcode (the “magic” method) seems prone to error.

    All that said, I don’t want to seem too negative – I am liking bbPress 2.0 a lot and thank you (and everyone involved) for your time on it.

Viewing 25 results - 18,251 through 18,275 (of 32,499 total)
Skip to toolbar