Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 25,501 through 25,525 (of 32,481 total)
  • Author
    Search Results
  • #5013
    technokelvin
    Member

    I installed WordPress 2.7.1 first then bbPress 1.0-Alpha-6. When I first installed I set the follow settings,

    bbPress Admin – Settings – WP Integration:

    WordPress address (URL): http://www.ascendanceradio.com/

    Blog address (URL): http://www.ascendanceradio.com/

    My main admin / keymaster has to log into both WP and bbPress to access both. I want to integrate it so I can log into one and access both.

    I realized that in WP my WP URL and Blog URL, they are both the same, was set to http://ascendanceradio.com (Without the www and /) so I changed it in the bbPress settings. You would think since both WP and bbPress now actually match things would get better? They got worse.

    I have a Maintenance Mode plugin that denies access to every page in WP (Excluding the forums since they aren’t a part of WP) unless you are logged in as an admin on the WP side. When the URL and Blog were set to http://www.ascendanceradio.com/ I could had to log into bbPress and then WP but could see all of the WP pages.

    Now that I changed the URL to exclude the www I can now log into bbPress AND be AUTOMATICALLY logged into WP BUT I can no longer see the WP pages indicating WP doesn’t see me as an admin. Not only that but when in the WP Admin and I try to log out it gives me an error:

    You are attempting to log out of AscenDance Radio

    Please try again.

    With a link back to my admin page. It never lets me log out and only happens after I go into bbPRess Admin Panel and change the URL / Blog to match the actual URL that WP has in its settings.

    It has nothing to do with the Maintenance Mode plugin either. I take it off and try to leave a comment on a post but bbPress and WP Admin see me logged in BUT the post requires me to enter my name and email address as if it doesn’t know I’m logged in.

    So basically bbPress and WP Admin knows I’m logged in but my actual WP Site had no clue.

    When I put,

    define(‘COOKIE_DOMAIN’,’.ascendanceradio.com’);

    define(‘COOKIEPATH’, ‘/’ );

    into both the wpconfig and bbpressconfig files it will no longer let me log into both WP and bbPress. If I log into WP first I can access all my WP Pages but when I try to log into bbPRess after the page just refreshes and my login information clears. If I log into bbPress first it lets me get into my WP Admin but my WP Pages can’t be access due to the plugin not recognizing I’m an admin. I also get the same error when trying to log out of the WP Admin.

    I tried only adding the cook domain / path code to ONLY wpconfig and receive the same error as mentioned in the above paragraph.

    I also just tried adding all that code from the Integration 101 8 step solution and get the same problems as mention in the big paragraph above.

    The closet I get to having it work is when I add www to all the bbPress settings. I just tried adding to the 8 step code snippet (the URL portions, I did not touch the cookie domain or any other domains) AND changing the URL and Blog to http://www.ascendanceradio.com and it lets me log into both giving me access to everything I want, bbPress / WP Admin AND WP Pages as my plugin now sees me as an admin.

    The only problem is that’s not integrated login.

    Do you think if I change, in WP Admin, my URL and Blog URL to http://www.ascendanceradio.com (As opposed to what it is now, http://ascendanceradio.com) it would fix the problem? I tried changing the name before and ruined my WP site and had to reinstall (Afterward I figured out I could have changed the value through myphpadmin and proceeded to cry for days). Could I ruin my WP site if I change the URL and Blog address to include www?

    Is there someway somewhere a function / cookie / database value is requiring a www and that’s why things seem to work better when I include it in my bbPress Admin Settings?

    I try to go to http://www.ascendanceradio.com and it automatically redirects me to http://ascendanceradio.com so I don’t understand why www would be needed for anything.

    I hope I was clear and concise enough to get some good help. I’ve spent over 8 hours debugging this before turning for help so anything at this point is greatly appreciated! Thanks!! :-)

    #66148
    tliebig
    Member

    @_ck_:

    A note on deep integration: As of 0.9.0.4, deep integration will break the localization due to the localization methods being used from WP’s core files (bb_settings.php line 75), causing the system to look for bbPress-language files in the WP language directory. Here’s what to fix to make bbPress load it’s own language files from bb_includes/languages when using deep integration:

    In line 376-377 of bb-settings.php, replace

    // Load the default text localization domain.
    load_default_textdomain();

    with

    // Load the default text localization domain.
    if ( !(defined('DB_NAME')) ) { // Include localization the bbPress-way when WP is not running.
    load_default_textdomain();
    }
    else {
    $locale = get_locale();
    $mofile = BB_LANG_DIR . "$locale.mo";

    load_textdomain('default', $mofile);
    };

    #72459
    johnhiler
    Member

    I stuck the code into bbPress in login-form.php, but it didn’t work.

    There’s a form on the WordPress side of things, in my WordPress header… I thought maybe that needed to be changed as well? It posts into the bbpress auth…

    #72458
    _ck_
    Participant

    You can do a similar hack on the wordpress side too, except it’s easier because wordpress doesn’t need a referer , you just do it in the url.

    ie.

    wp-login.php?redirect_to=<?php echo $_SERVER['REQUEST_URI']; ?>

    #72457
    chrishajer
    Participant

    This does not go in any WordPress files at all. It goes in your bbPress login-form.php template file, right before the closing </form> tag. That way, after submitting the form, bbPress directs the user back where they came from (all those SERVER VARIABLES in the code snippet.) I thought this did exactly what you were looking for. Where did you try to insert the code?

    #72456
    chrishajer
    Participant

    Sorry, I thought you said you were routing all the logins through bb-login.php – this *is* bbPress code. Where do you need to use the code? What are you trying to do again?

    You’re sending all your users through bbPress for login, but when a blog user gets sent to the forum for login, they’re not returned to the page they were on, but to the forum front page? Is that accurate?

    #72455
    johnhiler
    Member

    Ah it looks like that code is for bbPress… it has a reference to bb_get_option in it:

    <input type=”hidden” name=”re” value=”<?php echo “http://&#8221;.$_SERVER.$_SERVER[“REQUEST_URI”].’?’.$_SERVER[“QUERY_STRING”]; ?>” />

    <input type=”hidden” name=”_wp_http_referer” value=”<?php echo bb_get_option( ‘uri’ ) ?>” />

    If I stick it into a WordPress template for my header.php file, it crashes… any ideas how to make it work in WordPress?

    #72454
    johnhiler
    Member

    Ah that looks really promising – I’ll try it out! Thanks so much. :-)

    #5003
    #61598

    In reply to: How Do I Do This?

    robbert12
    Member

    Sorry to bump this topic, but I’m new to BBpress and after a long search on Google and in these forums, I arrived here.

    I want to do the same as on this picture: this picture.

    Unfortunately, I can’t get it to work on my forum. I posted the code of front-page.php below and emphasized the problem point (I think). I hope somebody can help me

    <?php bb_get_header(); ?>

    <div id="forums"><!-- Forums -->
    <?php if ( $forums ) : ?>
    <div id="sidebar"><!-- Sidebar -->

    <?php if ( bb_forums() ) : ?>
    <table id="forumlist">
    <thead>
    <tr>
    <th class="title"><?php _e('Forums'); ?></th>
    <!-- th><?php _e('Topics'); ?></th-->
    <th><?php _e('Posts'); ?></th>
    </tr>
    </thead>

    <tbody>
    <?php while ( bb_forum() ) : ?>
    <tr<?php bb_forum_class(); ?>>
    <td class="title"><?php bb_forum_pad( '<div class="nest">' ); ?><a>"><?php forum_name(); ?></a> <span><?php forum_description(); ?></span><?php bb_forum_pad( '</div>' ); ?></td>
    <!--td><?php forum_topics(); ?></td-->
    <td><?php forum_posts(); ?></td>
    </tr>
    <?php endwhile; ?>
    </tbody>
    </table>
    <?php endif; // bb_forums() ?>

    <?php if ( bb_is_user_logged_in() ) : ?>
    <h2><?php _e('Views'); ?></h2>
    <div class="sbox">
    <ul id="views">
    <?php foreach ( bb_get_views() as $the_view => $title ) : ?>
    <li class="view"><a>"><?php view_name( $the_view ); ?></a>
    <?php endforeach; ?>

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

    </div><!-- //sb -->

    <div id="content"><!-- Content -->
    <?php if ( $topics || $super_stickies ) : ?>
    <table id="sticky">

    <thead>
    <tr>
    <th class="title"><?php _e('Sticky'); ?></th>
    <th><?php _e('Posts'); ?></th>
    <th><?php _e('Freshness'); ?></th>
    </tr>
    </thead>

    <tbody>
    <?php if ( $super_stickies ) : foreach ( $super_stickies as $topic ) : ?>
    <tr<?php topic_class(); ?>>
    <td class="title"><?php bb_topic_labels(); ?> <big><a>"><?php topic_title(); ?></a></big></td>
    <td><?php topic_posts(); ?></td>

    <td><a>"><?php topic_time(); ?></a></td>
    </tr>
    <?php endforeach; ?>
    <?php else : ?>
    <tr>
    <td class="title">Er zijn geen belangrijke berichten beschikbaar</td>
    <td></td>
    <td></td>
    </tr>

    </tbody>
    </table>
    <?php endif; ?>

    <table id="lastest">
    <thead>
    <tr>
    <th class="title"><?php _e('Latest Discussions'); ?> — <?php new_topic(); ?></th>
    <th><?php _e('Posts'); ?></th>
    <th><?php _e('Freshness'); ?></th>
    </tr>
    </thead>

    <tbody>
    <?php if ( $topics ) : foreach ( $topics as $topic ) : ?>
    <tr<?php topic_class(); ?>>
    <td class="title"><?php bb_topic_labels(); ?> <a>"><?php topic_title(); ?></a></td>
    <td><?php topic_posts(); ?></td>
    <td><a>"><?php topic_time(); ?></a></td>
    </tr>
    <?php endforeach; endif; // $topics ?>
    </tbody>
    </table>
    <?php endif; // $topics or $super_stickies ?>
    </div><!-- //c -->
    <?php else : // $forums ?>

    <?php post_form(); endif; // $forums ?>

    </div><!-- //f -->

    <?php bb_get_footer(); ?>

    And this piece of code is wrong, I think;

    <table id="forumlist">
    <thead>
    <tr>
    <th class="title"><?php _e('Forums'); ?></th>
    <!-- th><?php _e('Topics'); ?></th-->
    <th><?php _e('Posts'); ?></th>
    </tr>
    </thead>

    <tbody>
    <?php while ( bb_forum() ) : ?>
    <tr<?php bb_forum_class(); ?>>
    <td class="title"><?php bb_forum_pad( '<div class="nest">' ); ?><a>"><?php forum_name(); ?></a> <span><?php forum_description(); ?></span><?php bb_forum_pad( '</div>' ); ?></td>
    <!--td><?php forum_topics(); ?></td-->
    <td><?php forum_posts(); ?></td>
    </tr>
    <?php endwhile; ?>
    </tbody>
    </table>

    I hope somebody can help me.

    Thanks in advance..

    citizenkeith
    Participant

    You’ll need to change this one:

    #latest tr, #forumlist tr, #favorites tr {behavior:url("/forums/my-templates/kakumei-too/images/hoverlite.htc");}

    #72446
    biodrama
    Member

    Thanks, Chris. Since I am getting registration emails to moderate, I am guessing register.php is the more likely route, but I am not a coder, and really appreciate your suggestions. Also, I just checked, and I was already running the Human Test plugin.

    #72445
    chrishajer
    Participant

    Yes.

    Or just replace register.php with

    <?php
    // silence is golden
    ?>

    You should look in your logs though to see where they are coming in. Sometimes they go right to bb-login.php as well. Anything related to login really. They’re not sitting there browsing the forum and clicking the [login] button.

    You can also install _ck_’s Human Test plugin to prevent most of the registrations:

    https://bbpress.org/plugins/topic/human-test/

    chrishajer
    Participant

    The problem is not that they SUPPORT PHP4, it’s that you WANT PHP5. Add this to your .htaccess if you’re at 1&1.

    AddType x-mapp-php5 .php

    That will force *.php files to be processed by PHP5. That should resolve the problem for you.

    #72439

    Finally got it working using _ck_’s plugin. Now I want the same login sync with my custom php pages. Any pointers regarding what I should be doing? I think I will need the code used in _ck_’s plugin and the bbPress core file. Am I right?

    diabolikal
    Member

    Hey guys, I’m getting the same problem, and my hosting is 1&1 and I’m sure they support PHP4. It is in my subfolder of the domain,

    http://www.ko-holic.com/bbpress

    Help!

    #72438

    Hello Kevin!

    Thanks for your reply! :D

    I did a clean install of WP 2.7 and then I activated Ann’s plugin.

    Then I added the code those three lines in wp-config.php and lost access to dashboard.

    Redirect Loop

    Firefox has detected that the server is redirecting the request for this address in a way that will never complete.

    The browser has stopped trying to retrieve the requested item. The site is redirecting the request in a way that will never complete.

    * Have you disabled or blocked cookies required by this site?

    * NOTE: If accepting the site’s cookies does not resolve the problem, it is likely a server configuration issue and not your computer.

    I am currently testing on localhost (XAMPP). Any idea what is causing this loop? May be I need to edit those lines but I dont know how to.

    I had to delete the plugin from the plugin directory to access dashboard again.

    I would not think of going beyond WP 2.7 unless I am unable to achieve the sync. And regarding the Open ID integration, I would like to keep myself away from it as I need to allow only registered users to login.

    chrishajer
    Participant
    chrishajer
    Participant

    X-Powered-By: PHP/4.4.9

    Are you using PHP4? I thought that was the source of this problem.

    What version did you install?

    adsearch
    Member

    Warning: cannot yet handle MBCS in html_entity_decode()! in /hsphere/local/home/xxxxxx/adsearch.co.in/forum/bb-includes/wp-functions.php on line 113

    Hello I have Installed the forum at the address given below

    http://adsearch.co.in/forum

    http://adsearch.co.in/fourms

    but at both the place I Get the same error.

    I did not integrate it with wordpress.

    what is the problem.

    adsearch
    Member

    Warning: cannot yet handle MBCS in html_entity_decode()! in /hsphere/local/home/xxxxxx/adsearch.co.in/forum/bb-includes/wp-functions.php on line 113

    Hello I have Installed the forum at the address given below

    http://adsearch.co.in/forum

    http://adsearch.co.in/fourms

    but at both the place I Get the same error.

    I did not integrate it with wordpress.

    what is the problem.

    #72437

    Hi Ashfame,

    First: i feel your pain in integrating WP2.7.1 and 0.9, i’m sure alot of us do – that said though, it’s definitely possible.

    Second: it’s definitely possible to achieve site wide login using either _ck_ or Ann’s plugins. Without a doubt using _ck_’s is far easier, as Ann’s comes with no documentation and there are steps required that no-one’s written out. It took me about an hour of searching and playing with Ann’s to get it to work, but once it did, it worked brilliantly.

    Basically follow the steps given on the 3rd page of the integration forum posts (hey dont expect documentation for something a sought after as this to be on an actual page – like the integration one – or even at the start of a post so it’s easily found). Then add in

    define(‘COOKIEPATH’, ‘/’ );

    define(‘SITECOOKIEPATH’, ‘/’);

    define(‘COOKIE_DOMAIN’, ”);

    to both the WP and BB configs. Obviously you can change the values.

    The other thing that really helped me, after alot of trial and error, was to set up WordPress first. Activate Ann’s plugin. It then automatically boots you our of the WP admin area. you have to go to/wp-login.php?action=logout and then entirely clear your cache and cookies.

    Then re-log in. The cookie WP sets will now be recognisable.

    Install BB AFTER this step to make life alot easier; as bbpress will recognise the admin cookie right form the word go :)

    Third: Ann’s method overwrites the ‘new’ wordpress cookie method, so the theory is that it’s future proof. at least throughout this WP2.7 branch. The bad news is, according to an automattic post i read yesterday, that the OpenID integration in WP2.8 may require a rewrite of all authentication in WordPress. If this happens then there is a good chance that all authentication in Automattic systems will have tot change, there’s just no way of future proofing against a company wide re-write. But if that doesn’t happen, then Ann’s plugin should work for a long time.

    Fourth: A the risk of reading form the _ck_ bible, there’s very little reason across the board to upgrade from WP2.5.1 to WP2.7.1 . There are no known security issues in 2.5.1. I’ve yet to come across a WP plugin that doesn’t work for 2.5.1, it’s a damn site easier to use, and it’s faster and more lightweight. Obviously, you may have different requirements that we don’t know about, but I would look long and hard at not using 2.7.1 if i were you.

    Good luck, Kev

    #4998

    I tried integrating them but messed up a lot. So trying a different approach what I want to achieve in my project.

    I need WP as CMS, bbPress as forum script and custom php code which will create a member’s area. I want site-wide login sync.

    Tried _ck_’s plugin but can’t make it to working even after using 0.0.3 version and I dont want to use Ann’s method of downgrading cookie of what WP 2.7.1 uses. Just because this project won’t be under me for long, so will opt a method which is more future proof. So I am thinking of directing all the login requests of WP & bbPress to my custom login page which will be the only means of login & logout on the site. I want to use plugins for both WP & bbPress so as to maintain future compatibility. I can always update those custom codes or can i have a plugin for that too.

    I may be running wild here but it seems quite easily feasible too.

    Waiting for your suggestions!

    #70397
    chrishajer
    Participant

    For reloading Apache after installing php5-mysql, you might end up doing this on CentOS:

    sudo /sbin/service apache2 restart

    or

    sudo /etc/init.d/apache2 restart

    or even

    sudo /usr/sbin/apache2ctl graceful

    One of those should restart the apache2 daemon.

    #70396
    chrishajer
    Participant

    On CentOS, you probably want rpm or the yum front end to it. Try this:

    yum install php5-mysql

    Maybe you need sudo in front of that command, depending on your system configuration. In that case sudo yum install php5-mysql.

    That should install the package for you on CentOS.

    http://www.centos.org/modules/newbb/viewtopic.php?post_id=49482&topic_id=14408

Viewing 25 results - 25,501 through 25,525 (of 32,481 total)
Skip to toolbar