Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 24,876 through 24,900 (of 32,468 total)
  • Author
    Search Results
  • #74519
    Sam Bauers
    Participant

    Does your site always have “www” in front of it?

    In any case, try changing the COOKIE_DOMAIN in WordPress like so (note the dot in front of the domain):

    define('COOKIE_DOMAIN', '.site.com');

    Also enter this value in bb-config on the bbPress side:

    $bb->cookiedomain = '.site.com';

    Doing this will log you out, but you should be able to just log back in.

    #74358

    Single quotes are bad HTML anyway and shouldn’t be used…

    Checking with trunk: If I add in a link: <a href="http://bbpress.org">This is a link</a> it works. If I edit that post, I get this: <a href="http://bbpress.org&quot;">This is a link</a> It gets even weirder as it goes on.

    Why is this really familiar? I think we had this once before…

    (tags working, pagination of users working. We’ll get there! :) )

    #74357
    the_Wish
    Member

    Thank you for your continuing work and effort on bbPress.

    I upgraded from RC1 to RC2 and something seems to be messy with the way additional markup is handled.

    So far, users could use syntax like this:

    <a href='http://bbpress.org'><img src='https://bbpress.org/test.jpg' /></a>

    to link a picture for example.

    Now with RC2, the ‘…’ upper commas aren’t recognized any longer but instead you’d have to write:

    <a href=http://bbpress.org><img src=https://bbpress.org/test.jpg /></a>

    and “…” quotation marks will be automatically added.

    Now the problem is that once the user edits a comment with such markup later on, the now present “…” will again not be recognized and turned into broken code instead.

    #74501

    Looking forward to it. :)

    Arturo
    Participant

    i’ve upgraded wp from 2.7.1 to 2.8, checked all the key for the cookie and

    AUTH_KEY in wp-config is the same of BB_AUTH_KEY in bb-config, the same for SECURE_AUTH_KEY – BB_SECURE_AUTH_KEY,

    LOGGED_IN_KEY – BB_LOGGED_IN_KEY, NONCE_KEY – BB_NONCE_KEY.

    i’ve installed and activated the plugin bbPress Integration 1.0-rc-2 configured with the url of bbpress (http://www.site.com/forums/) saved the option, copy/past in wp-config.php for the “code” in the box which is:

    define(‘COOKIEHASH’, ‘e99db1aecc456188d6dc1ccc37528ff8’);

    define(‘COOKIE_DOMAIN’, ‘.www.site.com’);

    define(‘SITECOOKIEPATH’, ‘/wp-admin’);

    define(‘COOKIEPATH’, ‘/’);

    i’m able to login in bbpress side, and i see the cookie wordpress_e99db1aecc456188d6dc1ccc37528ff8 for /forums/bb-admin, /forums/bb-plugins, /forums/my-plugins, /wp-admin, /wp-content/plugins and /.

    i’ve other 2 cookies bb-user-settings-1 and bb-user-settings-time-1 for /forums/bb-admin.

    when i try to go in wp-admin i’m slogged from wp and 2 new cookies appear, wordpress_test_cookie.

    when i try to login in WP side i’m redirected to the login page every time.

    if i remove the code generated by the Sam’s plugin i can login but i’m logged out from bbpress…

    how resolve this problem? thanks for the help.

    #74470
    Florian
    Member

    Thanks. I manually added your fix to my installation and it seems to work fine. :)

    #74255
    Sam Bauers
    Participant

    We have bbPress physically located a subdirectory within WordPress.com (WPMU), you can call that “bbpress”. We do it this way because we point *.wordpress.com to the same host (well not exactly, but for the point of the example let’s say we do). Anyway, because on WordPress.com all blogs are given a subdomain, we need to intercept the forum subdomains and push them to the bbPress code before WPMU executes. That’s what this .htaccess code does.

    You could do it without fewer rewrite rules if you didn’t use pretty permalinks.

    #74515
    Sam Bauers
    Participant

    I tend to use these terms and they are all potentially mutually exclusive, no one type of integration absolutely depends on the other although the first one generally requires the second one to work (99.9% of the time).

    • Cookie integration – Sharing of login cookies with WordPress
    • User database integration – Sharing of user data tables with WordPress
    • Deep integration – Including the WordPress codebase (PHP) inside bbPress to allow use of WordPress functions inside bbPress

    #74254

    Thanks Sam. I’ve yet to try this, but I will tomorrow and will let you know how it works. I suspect probably better than I could ever do on my own. :)

    My guess, is this works if bbPress is installed in a directory off the WordPress root called “/bbpress/” ?

    Does this mean that some/all of the code above goes into the WordPress .htaccess file to prevent it from taking over, or does it go in the bbPress .htaccess file?

    #74483
    Markus Pezold
    Participant

    Hi again,

    the code doesn’t work 100% in my installation.

    After the Login in WordPress – my testuser is shown as “logged”, but I can’t go to the Administration. :( The System doesn’t redirect me. At the same time my testuser ist shown as “logged in” in bbPress and there I can go to the admin.

    When I test the login from bbPress first nothing seems to happen. I’m not logged in in both bbPress and WordPress.

    hmpf … So … I’m going to test tomorrow again.

    #74469
    Sam Bauers
    Participant

    Change that add_option() to backpress_add_option()

    This is now fixed in trunk.

    #74468
    Florian
    Member

    For the time being I could fix the problem. Since I do not know what the implications are, it would probably still be better if one of you guys would take a look on it.

    Line 654 and 655 are:

    if ( true === $elapseDelay )

    add_option( ‘disable_fsockopen’, $endDelay, null, true );

    Since the forum works fine most of the time, I assume that add_option thing isn’t terribly important, so I just extended the if statement:

    if ( true === $elapseDelay && function_exists(“add_option”))

    Couldn’t see any negative side effects yet, but since this error only appeared sometimes this might be an illusion. :) In any way I have no idea what this is supposed to do in the first place, so it’s a bit of blind hacking…

    #74447
    Shagalaga
    Member
    #74466
    Shagalaga
    Member

    <?php if ( !bb_is_user_logged_in() ) : ?>

    HTML

    <?php endif; // bb_is_user_logged_in() ?>

    this very good to add extra information or Ads for people who are not logged in ;-)

    Yes it works!

    #74465
    massbase
    Member

    @jjj good thing you left in the 0.9 code in, the forum needs more detailed function support. cheers.

    #74482
    Markus Pezold
    Participant

    Hi Vizworld,

    thanks for your fix – I will test it soon – after a little “distance” from my computer. :)

    Today – it’s to sunny … so i must go to the mountains. :)

    #74497
    johnhiler
    Member

    Sweet, glad it’s working now! :-)

    #74495
    johnhiler
    Member

    Your database is still storing variables pointing to talkspirit.letsdoo.org… so your header area is still pointing to talkspirit URL’s.

    Check out this call to your css file:

    <link rel=”stylesheet” href=”http://talkspirit.letsdoo.org/my-templates/bbVanilla/style.css&#8221; type=”text/css” />

    Here’s the code that generates that (in my header.php at least):

    <link rel=”stylesheet” href=”<?php bb_stylesheet_uri(); ?>” type=”text/css” />

    You should be able to fix this using phpmyadmin. Try running this query to find the row you need to change:

    SELECT * FROM bb_topicmeta WHERE meta_key=’uri’

    Then edit the row so that the meta_value for that row is the url for your new site…

    #74489
    Ohna
    Member

    Ok, I find a solution :

    <?php echo bb_get_avatar( $member->ID ); ?>

    #74230

    Think of this as a reference post we’ll go back to, in order to get information to make a tubularly cool super sexy bbPress Codex magnifique!

    Sorry, it’s been a day.

    #74229
    johnhiler
    Member

    Yah, the codex will be a wiki with lots of information. We’ll list all the functions and try to make it easier for plugin/theme developers to learn the ropes!

    #14967
    Ohna
    Member

    Hi all,

    In “bbPress 9.0.5” I used a custom function to display author avatar outside the topic.php, I try the same function on bbPress 1.0 rc 2 and no longer works, can you help me?

    Custom function:

    function topic_author_avatar( $size = '50', $default = '', $post_id = 0 ) {
    if ( ! bb_get_option('avatars_show') )
    return false;

    $author_id = get_topic_author();
    if ( $link = get_user_link( $author_id ) ) {
    echo '<a href="' . attribute_escape( $link ) . '">' . bb_get_avatar( $author_id, $size, $default ) . '</a>';
    } else {
    echo bb_get_avatar( $author_id, $size, $default );
    }
    }

    #74228
    massbase
    Member

    I hope this codex isnt going to be just a really long forum post.

    I hope the codex lists all bbpress functions, like wordpresses so’s we can build our own themes and stuff.

    #74478
    Vizworld
    Member

    Ok.. I’m not 100% on this, but it seems the cookie hashing algorithm changed in WP2.8 .

    In WP2.7, in wp-includes/pluggable.php (line 512)

    if ( $expired < time() ) {

    do_action('auth_cookie_expired', $cookie_elements);

    return false;

    }

    $key = wp_hash($username . ‘|’ . $expiration, $scheme);

    $hash = hash_hmac(‘md5’, $username . ‘|’ . $expiration, $key);

    and in 2.8:

    // Quick check to see if an honest cookie has expired

    if ( $expired < time() ) {

    do_action('auth_cookie_expired', $cookie_elements);

    return false;

    }

    $user = get_userdatabylogin($username);

    if ( ! $user ) {

    do_action(‘auth_cookie_bad_username’, $cookie_elements);

    return false;

    }

    $pass_frag = substr($user->user_pass, 8, 4);

    $key = wp_hash($username . $pass_frag . ‘|’ . $expiration, $scheme);

    $hash = hash_hmac(‘md5’, $username . ‘|’ . $expiration, $key);

    So, in 2.8 the hash is salted with 4 character’s of the USer’s password. The “freshly_baked_cookies” plugin hasn’t been upgraded to match this change, so it always fails to match the hashed cookies.

    Unfortunateyl,the get_userdatabylogin function doesn’t seem to exist in bbpress…..

    #74401

    ashframe, even the admin plugin says it’s supposed to be for when you do reverse integration. Which is why I’m asking why you think you need it in the first place :) I totally get that you need to make the change manually due to your specific setup. I don’t get why the change is required in general for a bog standard WP + BB setup.

    bbPress shouldn’t be writing over the value in the DB. IIRC, it’s supposed to pull the WP values to create new BB values in the BB tables, once integration is setup in bbPress.

    Try it WITHOUT doing the muckity muck with the bb_capabilities, maybe?

Viewing 25 results - 24,876 through 24,900 (of 32,468 total)
Skip to toolbar