Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 26,751 through 26,775 (of 32,481 total)
  • Author
    Search Results
  • #68104
    chrishajer
    Participant

    It’s not a secret, it’s just not bbPress specific, it’s PHP. You need to loop through the array that is returned by that function. If you’re not comfortable learning enough PHP to accomplish that with the function, maybe you’d be better off the the widget. That’s why WordPress created widgets in the first place. It’s for people who don’t want to mess with PHP code. It’s drag and drop. Maybe enabling widgets in your theme would be easier than learning the proper way to loop through this array.

    #64335
    myu
    Member

    hi,

    tried the mb_encode_mimeheader() thing.. but can’t get it to work as desired. :(

    could i please get a bit more of instruction where to put it in with what parameter(s)?

    —-what i have tried


    towards the end of function bb_mail() in bb-includes/pluggable.php

    $headers = trim(join(defined('BB_MAIL_EOL') ? BB_MAIL_EOL : "n", $headers));

    //--added--
    $headers = mb_encode_mimeheader($headers, 'utf-8', 'B', defined('BB_MAIL_EOL') ? BB_MAIL_EOL : "n");
    //--end add--

    return @mail($to, $subject, $message, $headers);

    Although it shows fine as it comes on my Apple Mail, as momo-i and somebody else mentioned, utf8 can get garbled…

    Thank you in advance

    #68103
    patung
    Member

    Ok, so it’s a secret… ;)

    This is what I tried <?php bbpress_live_get_topics(); ?>

    and also <?php bbpress_live_get_topics("1"); ?>

    Don’t know if they are right, but anyway I just noticed it says it needs 2.6.2 and I just use 2.6.

    Also, would this plugin make any special claims on cpu and load average, because I suspect it might, just by activating, not even using it on a page?

    #68249

    In reply to: No avatars show up

    chrishajer
    Participant

    Avatars are turned on the the admin settings?

    Do you have this in your template’s post.php:

    <?php post_author_avatar_link(); ?>

    Also, this appears in profile.php:

    <?php if ( $avatar = bb_get_avatar( $user->ID ) ) : ?>

    <div id="useravatar"><?php echo $avatar; ?></div>

    <?php unset($avatar); endif; ?>

    #68261

    In reply to: wordpress Header

    chrishajer
    Participant

    Follow the instructions in the last section of this page:

    https://bbpress.org/documentation/integration-with-wordpress/#func

    You want access to the WordPress functions get_footer() and get_header() so you need to include WordPress in your bbPress.

    #51607

    In reply to: Google Adsense

    lenen-nl
    Member

    I’m a bit scared messing around with the adsense code.

    #68235
    Shagalaga
    Member

    no volunteers? :-(

    #4120
    agitainment
    Member

    Hi.

    I recently installed bbPress on my WordPress site here at http://agitainment.com/ics/forum/.

    I’ve built a theme based on 1col_fixed 1.1 (I believe it’s kakumei with most of the CSS stripped out). In any case, when I go to my forums I can see my Gravatars and default avatars in kakumei, but when I switch on my theme they disappear.

    Is there a php file I’m missing or a block of code somewhere I need to copy over from the kakumei theme to get these to work? If so, where should I put the code?

    Thanks!

    #4115
    wiseacre
    Member

    Hi. This si not a true plugin – just a stupid script for removing “deleted” topics and posts from the DB. Thanks in advance for any feedback.

    $link=mysql_connect("host","user","password");
    mysql_select_db("database");
    //delete topics metadata
    $res=mysql_query("SELECT topic_id FROM bb_topics WHERE topic_status>0;") or die(mysql_error());
    while($row=mysql_fetch_row($res)) {
    mysql_query("DELETE bb_meta.* FROM bb_meta WHERE object_type='bb_topic' AND object_id=$row[0];") or die(mysql_error());
    };
    mysql_free_result($res);

    //delete posts metadata
    $res=mysql_query("SELECT post_id FROM bb_posts WHERE post_status>0;") or die(mysql_error());
    while($row=mysql_fetch_row($res)) {
    mysql_query("DELETE bb_meta.* FROM bb_meta WHERE object_type='bb_post' AND object_id=$row[0];") or die(mysql_error());
    };
    mysql_free_result($res);

    //delete topics & posts
    mysql_query("DELETE bb_topics.* FROM bb_topics WHERE topic_status>0;") or die(mysql_error());
    mysql_query("DELETE bb_posts.* FROM bb_posts WHERE post_status>0;") or die(mysql_error());
    mysql_query("DELETE bb_meta.* FROM bb_meta WHERE meta_key='deleted_posts';") or die(mysql_error());

    //some extras - attempt to "correct" autoincrement
    $row=mysql_fetch_row(mysql_query("SELECT MAX(topic_id) FROM bb_topics;"));
    if($row[0]!="") {
    $correct=$row[0];
    }
    else {
    $correct=1;
    };
    mysql_query("ALTER TABLE bb_topics AUTO_INCREMENT=$correct;") or die(mysql_error());

    $row=mysql_fetch_row(mysql_query("SELECT MAX(post_id) FROM bb_posts;"));
    if($row[0]!="") {
    $correct=$row[0];
    }
    else {
    $correct=1;
    };
    mysql_query("ALTER TABLE bb_posts AUTO_INCREMENT=$correct;") or die(mysql_error());

    $row=mysql_fetch_row(mysql_query("SELECT MAX(meta_id) FROM bb_meta;"));
    if($row[0]!="") {
    $correct=$row[0];
    }
    else {
    $correct=1;
    };
    mysql_query("ALTER TABLE bb_meta AUTO_INCREMENT=$correct;") or die(mysql_error());

    mysql_close($link);

    #4112
    meitershaker
    Member

    Hello,

    i have a problem with the rss feed of topics: many topics have only the title displayed, with “1/01” date :/ why?

    Bye

    #68221
    threevisual
    Member

    thanks, I download the latest zip file from the link provided but I’m now getting the following error:

    Warning: bb_install(/home/wired/public_html/bbpress/bb-includes/backpress/functions.core.php) [function.bb-install]: failed to open stream: No such file or directory in /home/wired/public_html/bbpress/bb-admin/class-install.php on line 106

    Fatal error: bb_install() [function.require]: Failed opening required '/home/wired/public_html/bbpress/bb-includes/backpress/functions.core.php' (include_path='.:/usr/php4/lib/php:/usr/local/php4/lib/php') in /home/wired/public_html/bbpress/bb-admin/class-install.php on line 106

    #68098
    patung
    Member

    I don’t have widgets enabled….so what do I do with this – bbpress_live_get_topics()

    I mean what code do I actually put in the sidebar theme file?

    #68228
    restivz77
    Member

    I have been googling around for solutions to this issue for like 10 hours straight and I can’t find anything :( any help would be really appreciated. thanks!

    #4108
    threevisual
    Member

    Hey, I thought I’d try out the latest 1.0 alpha release (2) but when I go to install I get the following error:

    Fatal error: Call to undefined function: bb_glob() in /home/wired/public_html/forums/bb-admin/class-install.php on line 322

    Any idea how to fix this? One for the bugs list?

    #68184
    satranc
    Member

    Hi all,

    When i want to install

    i got this error:

    Fatal error: Call to undefined function bb_glob() in xxxxxxxxxx/bb-admin/class-install.php on line 322


    svn trunk revision: 1789

    #68179
    ear1grey
    Member

    I have the code managed through svn and after a quick svn switch http://svn.automattic.com/bbpress/tags/1.0-alpha-2 (followed by an svn update for good measure) everything appears normal.

    (+1 beer on Sam et al next visit)

    #68130
    Sam Bauers
    Participant

    I’ve added the ability to do this to the development trunk. If you want to backport this to an older bbPress, you can follow the changes here:

    https://trac.bbpress.org/changeset/1786

    Then drop the function <?php bb_latest_topics_pages(); ?> wherever you want it in the front-page template to show pagination.

    #68039
    qlister
    Member

    ok thanks chrishajer for the specific instructions, I will try it out and let you know of the outcome

    thanks, really appreciate it :)

    #4097
    epiphone
    Member

    Im going to intergrate my WordPress Theme into my bbPress forum, so I need to make sure that functions like Header and Sidebar can be used in bbPress. So I’ve been reading up and found out that you need to place this code in the bb-config.php:

    require_once(‘path/to/wp-blog-header.php’);

    However when I place the code. I suddenly can’t log into the bbPress forum anymore. When I click login nothing happens the page will load but not display links like Username –> Admin —> Log out just the normal page as if a guest was browsing the forum.

    I am placing the code below the first <php line? Am I doing something wrong?

    Additional Info:

    WordPress Version: 2.6.2

    bbPress Version: 0.9.2

    #67247

    In reply to: about sessions

    meitershaker
    Member

    but how to display the admin menu (admin link) in the header of my wordpress, when i’m connected to bbpress?

    thanks :)

    #68020

    In reply to: Viewing User IPs

    chrishajer
    Participant

    I think maybe it’s a bug. I just modified bb-admin/view-ip.php line 11, from this:

    $post_query = new BB_Query( 'post', array( 'ip' => $ip, 'per_page' => 30 ) );

    to this:

    $post_query = new BB_Query( 'post', array( 'poster_ip' => $ip, 'per_page' => 30 ) );

    Basically change ‘ip’ to ‘poster_ip’ and then it works. Not sure how long that’s been broken. I have a 0.9.0.2 installation that does not work, then the alpha r1637 also does not work.

    If this works for you, I can file a bug to trac bringing it to the developers attention.

    #4082
    irr1449
    Member

    My site currently does not have a user management system where people can register etc. I’m looking for a system to integrate that I can just piggyback off of and access the users table to do my own development.

    Would bbPress be a good fit here? I played around with the code a little bit and I just included “bb-load.php” and I was able call functions like ” bb_get_current_user_info( ‘id’ )” without actually displaying anything related to the forum.

    The only downside is that it added about .2 seconds to my average php render times.

    #4092
    kuroir
    Member

    I’m wondering if there’s a way to change the default Permalink structure and prefixes.

    For example :

    http://www.exolimpo.com/foro/topic/post-de-prueba

    I would like to change topic for something else.

    and

    http://www.exolimpo.com/foro/forum/anime

    I would also like to change Forum, since Foro already means forum in spanish.. so “Forum Forum” is reiterative.

    If there’s a way to do this tell me, I don’t mind editing a little bit of code in the core, I just need a little bit of direction.

    #68050
    Sam Bauers
    Participant

    The display of that empty option is suppressed in 1.0 when it isn’t available.

    It’s only ever visible to admins anyway, so it wasn’t a huge deal.

    Turns out there is an error in 0.9 that stops the “throttle_time” option from being set.

    If you run this raw SQL on your database it should set the option to 30 seconds which will force a checkbox to show up in that form.

    INSERT INTO bb_topicmeta VALUES (NULL, '0', 'throttle_time', '30');

Viewing 25 results - 26,751 through 26,775 (of 32,481 total)
Skip to toolbar