Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 24,851 through 24,875 (of 32,432 total)
  • Author
    Search Results
  • #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?

    #74227
    #74475
    Markus Pezold
    Participant

    We have the same problem today with the FBC-Plugin.

    I seems to be a “hot” topic – and that’s probably the reason why we search for the last 2 hours for a solution. :) *selfironic*

    Here the cookie-names and paths – they are identical. So the error eventually is not in seeting the cookies, but in reading of the cookies. !?

    After Login in WordPress

    wordpress_logged_in_672b8ff18484c1d9d7de0f05d907543d – Path: /wp/

    wordpress_logged_in_672b8ff18484c1d9d7de0f05d907543d – Path: /

    wordpress_672b8ff18484c1d9d7de0f05d907543d – Path: /wp/wp-content/plugins

    wordpress_672b8ff18484c1d9d7de0f05d907543d – Path: /wp/wp-admin

    After Login in BBpress

    wordpress_logged_in_672b8ff18484c1d9d7de0f05d907543d – Path: /wp/

    wordpress_logged_in_672b8ff18484c1d9d7de0f05d907543d – Path: /

    wordpress_672b8ff18484c1d9d7de0f05d907543d – Path: /

    wordpress_672b8ff18484c1d9d7de0f05d907543d – Path: /wp-admin

    wordpress_672b8ff18484c1d9d7de0f05d907543d – Path: /wp/wp-admin

    wordpress_672b8ff18484c1d9d7de0f05d907543d – Path: /wp/wp-content/plugins

    Path of Installation:

    http://www.mysteria30000.de/wp -> WordPress

    http://www.mysteria3000.de/forum –> bbPress

    Greetings

    Markus

    #74226
    johnhiler
    Member

    Ah sure, we could add that! Anyone interested in maintaining the Plugin Compatability part of the Codex?

    #74225
    omikami08
    Member

    Is there one that shows a list of compatible/working plugins for the different versions? WordPress has something like that:

    https://codex.wordpress.org/Themes/Theme_Compatibility/2.7

    https://codex.wordpress.org/Plugins/Plugin_Compatibility/2.7

    I’m asking because if it’s not there it might be a good addition.

    #74351

    If it wasn’t for Ipstenu mentioning to dump cookies and cache, I would have gone insane trying to log in after upgrade. This is vital info that may be worth adding to the upgrading instructions, and makes it quicker to get in the admin area and reactivate the plugins (or else, one is stuck with a broken looking forum) :-)

    Loving the new admin interface of the 1.0 version to match WP!

    #14965
    floch69
    Member

    Hi,

    I’m about to switch my old forum to a bbpress solution.

    Was looking around DB schema and found that post were wrapped up in a <p> tag.

    What’s the reason fon that?

    Is it possible to disable this behaviour?

    In that case, which part of the code is doing this?

    Thanks for your help!

    Cheers,

    Florent

    #74397

    To achieve integration between 0.9.05 & WordPress 2.7.1, I overwrite the bb_capabilities in wp_usermeta for my user by sql query as I don’t have phpmyadmin and I am using custom table prefixes.

    I’m at a loss why you would have to do that anyway… I’ve never heard of anyone having to go in via SQL and making those changes except in the case of ‘reverse’ integration (where by you started with bbPress and are now adding on a WP site). In theory, if you’re starting with everything brand new, you just do WP first and then bb and it should work.

    Looking at your doc, you also mention changing the wp_ prefix to rocking_ which is totally fine, but later on you have this:

    Add these two lines in bb-config.php

    $bb->custom_user_table = 'wp_users';
    $bb->custom_user_meta_table = 'wp_usermeta';

    Those too should be rocking_users and rocking_metadata

    #74462
    Markus Pezold
    Participant

    Hi massbase,

    the code from Ohna “(bb_is_user_logged_in())” works perfect in my installation. No more problems with that.

    #74422

    Use this in header :

    <?php
    // URL location of your feed
    $feedUrl = "http://feeds2.feedburner.com/ashfameblog?format=xml";
    // Replace the above URL with yours
    $feedContent = "";

    // Fetch feed from URL
    $curl = curl_init();
    curl_setopt($curl, CURLOPT_URL, $feedUrl);
    curl_setopt($curl, CURLOPT_TIMEOUT, 3);
    curl_setopt($curl, CURLOPT_FOLLOWLOCATION, true);
    curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
    curl_setopt($curl, CURLOPT_HEADER, false);

    // FeedBurner requires a proper USER-AGENT...
    curl_setopt($curl, CURL_HTTP_VERSION_1_1, true);
    curl_setopt($curl, CURLOPT_ENCODING, "gzip, deflate");
    curl_setopt($curl, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.3) Gecko/2008092417 Firefox/3.0.3");

    $feedContent = curl_exec($curl);
    curl_close($curl);
    ?>

    Use this to show :

    <?php
    $count=0;
    // Did we get feed content?
    if($feedContent && !empty($feedContent))
    {
    $feedXml = @simplexml_load_string($feedContent);
    if($feedXml)
    {
    ?>
    <ul>
    <?php foreach($feedXml->channel->item as $item): if($count==6) { break; } ?>
    <li><a href="<?php echo $item->link; ?>"><?php echo $item->title; ?></a></li>
    <?php $count++; endforeach; ?>
    </ul>
    <?php }} ?>

    #74459
    Markus Pezold
    Participant

    Hi all,

    is this a function from bbPress 1.0 Release Candidate? In 0.9.0.5 it seems not to work:

    "Fatal error: Call to undefined function is_user_logged_in() in ../forum/bb-templates/scoun/front-page.php on line 3"

    #64934
    Joseph
    Member

    martenk, thanks so much. That plugin was what I was looking for. AMAZINGLY easy!

    Here it is again for anyone that just wants to be able to create a page in the admin that links to the blog without editing the core files (which wouldn’t be fun to think about when you update).

    http://txfx.net/code/wordpress/page-links-to/

Viewing 25 results - 24,851 through 24,875 (of 32,432 total)
Skip to toolbar