Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 26,351 through 26,375 (of 32,466 total)
  • Author
    Search Results
  • #69588
    _ck_
    Participant

    I’m afraid I do qualify for too many of the “Granny” points – large fonts, too many cats, health problems, etc. LOL!

    But I bet your granny can’t write PHP or javascript so that makes me feel better somehow… ;-)

    #69585

    I don’t see any ads (and I block them too).

    Immelody, I would suggest making the border around the login info boxes (for name and password) darker. I almost missed where they were and wondered how people logged in :)

    #69505

    In reply to: counting forums

    _ck_
    Participant

    Okay if you want something simple you can make this into a mini-plugin:

    (call it forum-totals.php)

    <?php
    /*
    Plugin Name: Forum Totals
    */

    function forum_totals() {
    global $forum_id;
    $forum = get_forum( $forum_id ); $topics=$forum->topics; $posts=$forum->posts;
    $forums=get_forums(array('child_of' => $forum_id)); $count=0;
    if ($forums) {foreach ($forums as $forum) {$count++; $topics+=$forum->topics; $posts+=$forum->posts;}}
    echo "<tr style='background:#ccc;'><td align='right'>$count total forums:</td><td class='num'>$topics</td><td class='num'>$posts</td></tr>";
    }

    function forum_topics_including_subforums( $forum_id = 0 ) {
    echo apply_filters( 'forum_topics', get_forum_topics_including_subforums( $forum_id ), $forum_id );
    }

    function forum_posts_including_subforums( $forum_id = 0 ) {
    echo apply_filters( 'forum_posts', get_forum_posts_including_subforums( $forum_id ), $forum_id );
    }

    function get_forum_topics_including_subforums( $forum_id = 0 ) {
    $forum_id=get_forum_id( $forum_id );
    $forum = get_forum( $forum_id ); $topics=$forum->topics;
    $forums=get_forums(array('child_of' => $forum_id));
    if ($forums) {foreach ($forums as $forum) {$topics+=$forum->topics;}}
    return apply_filters( 'get_forum_topics', $topics, $forum_id );
    }

    function get_forum_posts_including_subforums( $forum_id = 0 ) {
    $forum_id=get_forum_id( $forum_id );
    $forum = get_forum( $forum_id ); $posts=$forum->posts;
    $forums=get_forums(array('child_of' => $forum_id));
    if ($forums) {foreach ($forums as $forum) {$posts+=$forum->posts;}}
    return apply_filters( 'get_forum_posts', $posts, $forum_id );
    }
    ?>

    Install and activate it and then you need to put

    <?php forum_totals(); ?>

    anywhere you want to see it, on front-page.php or forum.php templates.

    It should go between the endwhile and the </table>

    Like this:

    <?php  endwhile; ?>
    <?php forum_totals(); ?>
    </table>

    To use the replacement functions for forum_topics() and forum_posts() which include the totals for a forum including it’s subforums, simply replace them in your templates with forum_topics_including_subforums(); and forum_posts_including_subforums();

    #4377
    #69573
    _ck_
    Participant

    The state the trunk is in right now needs a great deal more bug reports – I find at least one new problem every time I try it because they keep changing chunks of code that are critical with backwards compatibility.

    You don’t want to unleash it as a regular release in that state, even as an alpha, because despite my constant warnings and explanations, people use the alpha on live, active sites, usually because they absolutely have to use the very newest WordPress despite it’s bloat and bugs.

    I’m fairly certain there will be another alpha release before the end of the year though.

    If you know how to use SVN then you can help contribute with quality bug reports on TRAC.

    #65027

    In reply to: Profile not updating.

    It’s maaaagic… :)

    #69054
    Nipon
    Member

    I did as johnjamesj said (except that i left “secure auth” cookie salt as blank because I don’t see it anywhere) I am on wp 2.7rc1 and bb1.0a2. After installing, BB integrated and extracted the wp admin id to assign it the keymaster role. But I could not login in the newly created forum. On the WP side, I was stripped of my admin status and told that I don’t have the permissions.. bla bla. After initial panic, I edited wp_capabilities (under wp_usermeta). It was changed by BB to

    a:1:{s:9:"keymaster";b:1;}

    I changed it to

    a:1:{s:13:"administrator";b:1;}

    and got back admin powers in wp much to my relief.

    But the problem remains, I can’t login to BB. Something is seriously wrong.

    #4380
    Immelody
    Member

    I tweaked two similiar themes to create one that looks nearly identical. I wanted to post them here. If anyone would like me to zip the themes up, I would be willing to.

    I do want to give credit to the person who created the themes in the first place. I’m not great with coming up with raw code so really all the credit is theirs.

    bbPress original theme – http://bbshowcase.org/forums/?bbtheme=MistyMorning-bbpress

    WordPress original theme – http://themeterminal.com/demo/index.php?wptheme=Ad+Clerum

    My merged theme – http://www.asparenting.com

    #69561
    wiseacre
    Member

    I mark it as resolved :)

    > Rev. 1828 seems working …

    > Our support guys say it’s depends of files permissions – they must be not more 755.

    After

    chmod -R 755 bbpress

    it’s working too …

    And I don’t use dreamhost :))

    Thanks all :)

    #69571
    wiseacre
    Member

    I know what is SVN, man :) And use it every day, for bbpress tests too. But alphas are good for bug reports, help others and wordpress integration testing. We sould discuss one named pie of code. I love digits (rev numbers are digits too), it’s my job, but the people is normal guys collection.

    #69570
    _ck_
    Participant

    Oh and by the way, you don’t have to wait for official releases, simply install a SVN client and you can keep in sync with the very newest trunk copy (or any other release) any time you’d like.

    It’s the same technique as for WordPress so use these instructions

    https://codex.wordpress.org/Installing/Updating_WordPress_with_Subversion

    also see this topic for more details/ideas

    https://bbpress.org/forums/topic/svn-procedure-for-checking-out-bbpress

    and if your server is on apache, here’s how to easily install SVN as a client instead of the full package:

    https://bbpress.org/forums/topic/svn-procedure-for-checking-out-bbpress#post-18739

    #4376

    I got to thinking, maybe we’re doing it all wrong.

    Rather than try to work WordPress into bbPress, why not just include the bb-config.php file inside the wp-config.php file instead.

    Viola, from what I can tell, everything works like a charm. CK, your bbCode plug-in breaks some of the WordPress tags/shortcodes though, [caption] etc…

    This way, bbpress can be directly referenced inside the entire website, and WordPress can use it’s functions AND the ones from bbPress to micromanage the login situation.

    I really need to investigate this more, but I think that I might be on to something with this whole integration issue.

    A simple plug-in could be made to include the core WordPress queries inside bbPress for pages, categories, etc… Without having to duplicate load everything inside the header, etc…

    Okay, so I just did this like 20 minutes ago and I’m a little giddy about the idea, and I’m sure there’s a myriad of reasons why this won’t work, but I think it’s a neat idea…

    #69558
    chrishajer
    Participant

    Can you look at any logs to see why the 500 error is occuring? Sounds like the web server does not allow the directives you’re trying to use in .htaccess.

    BTW, I use AddType application/x-httpd-php5 .php on almost every install without a problem. Maybe the server just doesn’t support it. Does your host have instructions for enabling PHP5 for your webspace?

    #4375
    wiseacre
    Member

    Ok, guis, WP 2.7 is here. Give us bbpess alpha 3 to test it. :)

    Because of … there are only 59 active tickets ;)

    #69553
    _ck_
    Participant

    Try replacing that line in your .htaccess file with this

    AddHandler application/x-httpd-php5 .php
    AddType application/x-httpd-php5 .php
    AddHandler application/x-httpd-php .php4
    AddType application/x-httpd-php .php4

    #4368
    thetimediva
    Member

    Hi

    I use instant teleseminar for recordings and they generate a code that you embed in your site etc. to display the player and download links.

    This is a sample of there code

    <iframe width=”452px” height=”130px” frameborder=”0″ scrolling=”no” src=”http://instantTeleseminar.com/replay.asp?eventid=5220734&preffix=custom”></iframe&gt;

    It won’t display the player… how do I get this to work?

    Is there an audio player plug in for bbpress like there is for wordpress?

    Thanks

    Ann

    #69522

    In reply to: Change Post Author?

    It isn’t about it being a regular basis, it’s about it being possible.

    In my testing and installing of bbPress, I usually bounce back and forth between a KeyMaster, an Admin, and a Member test account, and sometimes I am logged in and make a post under the wrong one. :)

    It’s more for convenience and possibility sake than it is for daily use or practicality.

    Forums with many users would just have a million entries in the drop down. Heck I dunno man I just thought of this idea! :)

    #69521

    In reply to: Change Post Author?

    _ck_
    Participant

    I have a bit of code that does an ajax-ish drop down of all members and adding something up near the topic meta area is really easy but I still don’t understand why you’d want to change the author of a topic on a regular basis?

    #69519

    In reply to: Change Post Author?

    Nothing with roles, actually something much simpler.

    As an administrator, I would like to have a drop-down list on the post-form.php that has a list of all forum members, so that I can assign or change the author of a post.

    Within the <?php if ( is_bb_tag() || is_front() ) : ?> there would be another drop down list, but rather than forum, would be the list of authors to say started that topic.

    #69452
    _ck_
    Participant

    I am making good progress re-organizing my old code and debugging some quirks despite it’s complexity and should have something for everyone to play with over the weekend.

    #69053

    @elwagar: Conversely, once they are registered you can assign them a role by going to the bbPress admin, WordPress Integration, and remapping. I feel like a plug-in could help this registration laziness along, but I also think this should just work correctly right away.

    I actually had a similar issue years ago integrating phpBB 2.x and osCommerce together, trying to get one to work inside the other with cookies and what-not was a really big problem, one that I never really did get working 100% correctly.

    I have no experience with bbPress Live, but it might be worth looking into. CK posted a really nice SQL example on how to grab information without a plug-in, so if you can’t get that to work, you could always put in a little manual labor. ;)

    #69503

    In reply to: counting forums

    _ck_
    Participant

    update: there is a better version a few posts down

    I had worked this out this quick and dirty routine but then I realized you might mean not to show it within the forum list. If you mean something different let me know.

    In front-page.php

    Change

    <?php  while ( bb_forum() ) :  ?>

    to

    <?php
    forum_totals("init");
    while ( bb_forum() ) :
    forum_totals();
    ?>

    and then this after the end of the forum list routine

    <?php  endwhile;  ?>

    to this

    <?php
    endwhile;
    forum_totals("finish");
    ?>

    This is the main function you can just drop at the bottom of front-page.php

    <?php
    function forum_totals($x="") {
    static $last_parent,$total_posts,$total_topics,$all_topics,$all_posts,$total_counter,$all_counter;
    if (function_exists('bb_get_forum_is_category')) {$category=bb_get_forum_is_category();} else {$category=false;}
    if ($x=="init") {$last_parent=false; $total_topics=0; $total_posts=0; $all_topics=0; $all_posts=0; $total_counter=0; $all_counter=0; return;}
    if ($x=="finish" || $last_parent!==$GLOBALS['forum']->forum_parent || $category) {
    if ($last_parent!==false && $total_counter>1) {echo "<tr><td align='right'>$total_counter subforums:</td><td class='num'>$total_topics</td><td class='num'>$total_posts</td></tr>";}
    $last_parent=$GLOBALS['forum']->forum_parent; $total_topics=$GLOBALS['forum']->topics; $total_posts=$GLOBALS['forum']->posts;
    $total_counter=0;
    } else {$total_topics+= (int) $GLOBALS['forum']->topics; $total_posts+=(int) $GLOBALS['forum']->posts;}
    $all_topics+= (int) $GLOBALS['forum']->topics; $all_posts+=(int) $GLOBALS['forum']->posts;
    if ($x=="finish") {echo "<tr><td align='right'>$all_counter total forums:</td><td class='num'>$all_topics</td><td class='num'>$all_posts</td></tr>";}
    elseif ($category) {$last_parent=false;} else {$all_counter++; $total_counter++; }
    }
    ?>

    #69051
    eliwagar
    Member

    :( I have just realized that…Bugfixing can be so frustrating…I will check again tonight…

    #68714

    @mvds: The idea is that logging into or out of either/or will do that action on both sides for a unified website function. If you log into or out of either, and it affects the other immediately, and you have admin access to both sides regardless of where you login, that’s a good thing. :)

    #69050

    Have you tried logging in and out of both your WordPress and bbPress installations and accessing both admin panels? I mean each combination each way.

    1. Log into WordPress; Check admin panel access and cookies; Log out of WordPress
    2. Log into bbPress; Check admin panel access and cookies; Log out of bbPress
    3. Log into WordPress; Check admin panel access and cookies; Log out of bbPress
    4. Log into bbPress; Check admin panel access and cookies; Log out of WordPress

    That is where the problem lies, and I have been running the most updated trunks of both bbPress and WordPress the entire time. :/

Viewing 25 results - 26,351 through 26,375 (of 32,466 total)
Skip to toolbar