_ck_ (@_ck_)

Forum Replies Created

Viewing 25 replies - 926 through 950 (of 2,186 total)
  • In reply to: bbpress INSIDE theme?

    _ck_
    Participant

    @_ck_

    Your layout is already very much like a standard forum structure. You have a header and a footer and a content area on the left.

    Simply build a bbPress theme that is identical to your website by taking apart your current page structure and putting it into the appropriate templates and make a path to /forums/ or whatever you want to call it.

    Or you could go for full/complex integration but it will double your page creation time.

    In reply to: Codex linking?

    _ck_
    Participant

    @_ck_

    There’s no way your version works because the str_replace is executed immediately and the $2 isn’t available at that time. The regex would either have to use a callback or be expanded to catch words (or look on php.net for the /e modifer)

    In reply to: Codex linking?

    _ck_
    Participant

    @_ck_

    Untested. Actually the forum is deleting some of the code so use it from here:

    http://pastebin.com/f54a958de

    <?php
    /*
    Plugin Name: Wiki Link
    */
    add_action('post_text','wiki_link',200);
    function wiki_link($text) {
    $url="http://example.com/path_to_wiki?terms=";
    $text=preg_replace("/([[(.+?)]])/si","<a class='wiki_link' href='$url$2'>$2</a>",$text);
    return $text;
    }
    ?>

    the above is missing two $2, should look like

    <a class='wiki_link' href='$url$2'>$2</a>

    In reply to: Codex linking?

    _ck_
    Participant

    @_ck_

    It’s probably a 5 line plugin to do that.

    Give me an example of what the destination URL looks like.


    _ck_
    Participant

    @_ck_

    There was a lighttpd “pro” on the irc channel last week named “rockerdan”

    There are also several threads around here about it:

    http://www.google.com/search?q=Lighttpd+site%3Abbpress.org&num=100


    _ck_
    Participant

    @_ck_

    I believe I reported this bug and another problem with the pagination links a few weeks ago and it was fixed in the trunk. What version are you using?


    _ck_
    Participant

    @_ck_

    One more tip for the next update would be to go through all the images and optimize them for size. Some of them are way too big and considering that most of them have to load for a single page, it starts to add up.

    I recommend pngoptimizer for drag and drop ease

    http://psydk.org/PngOptimizer.php

    (don’t forget to clean up the backups it makes)

    And the gifs can use some optimization too.

    The massive light.png file can be made into a 90% progressive jpg at one third the filesize with no visible degradation.

    http://xs134.xs.to/xs134/08520/light463.jpg (rename backto light.jpg)

    Last but not least, here’s a cleaned up screenshot replaecment that’s half the filesize.

    http://xs134.xs.to/xs134/08520/screenshot299.png

    (sorry you’ll have to rename it back too)


    _ck_
    Participant

    @_ck_

    I created a separate database for bbPress with separate users.

    You somehow changed your wordpress settings to look at the users in the new, blank, bbpress install. Therefore noone can login. The wrong cookies aren’t helping.

    You need to delete bbpress and change your wordpress wp-config.php to point back to the user table in the old wordpress database.


    _ck_
    Participant

    @_ck_

    Trac schedules are meaningless. It’s just arbitrary dates picked a long time ago.

    There is only one person actively working on 1.0 at this time so progress is slow.

    Do not plan on any schedule for production use and do not use alpha on live sites.

    https://bbpress.org/forums/tags/10


    _ck_
    Participant

    @_ck_

    bbPress has an advanced WHERE filter on every mysql query.

    You could write a plugin that simply tallys their post (and cache that cause you don’t want to do it each time) and then manipulate the WHERE filter based on the result.

    It’s a very strange request so don’t expect me to do it for you ;-)

    See my Hidden Forums plugin to see how the filters work.

    In reply to: Super Sticky Problem

    _ck_
    Participant

    @_ck_

    I think it’s confusing too and I am not sure why they did that.

    You could try at the start of the forum.php template

    global $super_stickies;

    or maybe

    $stickies=array_merge($stickies,$super_stickies);

    but php may renumber the topics causing it to fail.

    or try

    $stickies=$stickies+$super_stickies;

    Of course this will show all super stickies in each forum.

    A real plugin would have to be written to do this properly.


    _ck_
    Participant

    @_ck_

    I suspect the buddypress support forum is your best bet unless Trent happens to know the answer (and notices the question here).


    _ck_
    Participant

    @_ck_

    Never hack the core.

    Especially when that function is right there designed to be filtered.

    see this apply_filters( 'get_profile_info_keys', array(

    It means you can make a simple plugin to modify the info keys on the fly.

    Untested but should work as a plugin:

    /*
    Plugin Name: Allow Title Edit
    */
    add_filter ('get_profile_info_keys', 'allow_title_edit');

    function allow_title_edit($array) {
    if (bb_current_user_can('participate')) {
    global $bbdb;
    $array[$bbdb->prefix.'title']= array(0, __('Custom Title'));
    }
    return $array;
    }


    _ck_
    Participant

    @_ck_

    I think vannak did that, and it’s 10 seconds:

    https://bbpress.org/forums/topic/bbpress-is-slow-like-godaddy-says/page/2#post-21978

    What happens if you upload a random file and name it test.txt ?

    Since it can’t modify the php file, I guess it won’t be able to modify the text.txt file either but maybe it’s only because the php file is open by the same process.


    _ck_
    Participant

    @_ck_

    Well the creation errors aren’t exactly godaddy’s fault, it’s just something weird with windows I don’t completely know about since I hate IIS and won’t even test it.

    Makes no sense that a php program can’t create a file. Something is wrong there.

    Only intelligent thing I can find about it is here:

    http://us2.php.net/manual/en/function.fopen.php#50601

    Do you have some kind of security panel where you can give your account write permission to the /test/ directory?


    _ck_
    Participant

    @_ck_

    There are numerous other quirks too in bbPress’s parsing.

    For example paragraph tags are stripped inside of backticks.


    _ck_
    Participant

    @_ck_

    There is another search plugin for bbPress that appends a WordPress search to the bbPress search.

    https://bbpress.org/plugins/topic/wp-search/

    I will eventually add wordpress searching to super-search, I just ran out of time/interest.


    _ck_
    Participant

    @_ck_

    vannak, 10 seconds is very bad (the time is independent of where you access it from)

    chrishajer, something’s not right there, Windows must think you don’t have access rights to write to the directory. Whatever Windows’s equal to chmod has to be done.

    According to php.net the chmod in php actually does do something on some windows setups.

    So try replacing this line, like so:

    $file=dirname(__FILE__)."/test.txt"; $h=fopen($file, "wb"); fclose($h); chmod($file, 0777 );


    _ck_
    Participant

    @_ck_

    You did create the database first, right?

    If you already use wordpress, you can look at it’s wp-config.php file to see what settings it uses.


    _ck_
    Participant

    @_ck_

    Sam this is still broken. See the previous post. there are &38;‘s all over the site.


    _ck_
    Participant

    @_ck_

    There are only two other solid options IMHO. Vbulletin and SMF.

    If you are running a commercial or for-profit site, Vbulletin, otherwise SMF.

    You will never get them to blend with an existing site however

    and writing your own plugins for either can give one brain damage.


    _ck_
    Participant

    @_ck_

    Very nice and clean. Needs a tiny splash of color. Topic Icons plugin should do it ;-)

    In reply to: button for guests

    _ck_
    Participant

    @_ck_

    You almost have it. Try it this way:

    <?php if (bb_is_user_logged_in()) : ?>
    <li id="register_now"><a href="<?php bb_option('uri'); ?>register.php" class="pagelink">Join Now</a></li>
    <?php endif; ?>


    _ck_
    Participant

    @_ck_

    Make a directory called test, go in there and put this version of the script in there:

    <?php
    /*
    Experimental NFS detector - upload this file to server and chmod 777
    Script should take less than one second to run.
    If it takes more than one second, then it's likely NFS (or Windows or a bad configuration)
    Any error means the time is unreliable as the script has failed.
    */
    error_reporting(E_ALL);
    $file=dirname(__FILE__)."/test.txt"; file_put_contents($file,'');
    $time=strtok(microtime(),' ')+strtok('');
    for ($i=0; $i<=9999; $i++) {if (touch($file)) {clearstatcache(); filemtime($file);} else {break;}}
    echo ((strtok(microtime(),' ')+strtok(''))-$time)." seconds";
    ?>


    _ck_
    Participant

    @_ck_

    I am changing the behavior to be more intuitive.

    If they have highlighted text, it will create a link for them by just asking for the link.

    If there is no highlighted text, it will first ask for the link, then it will ask for the text for the link.

    Replace this function by with it’s one new line in BBcode-Buttons.js

    function edInsertLink(i, defaultValue) {
    if (!defaultValue) {defaultValue = 'http://';}
    if (!edCheckOpenTags(i)) {
    var URL = prompt('Enter the URL' ,defaultValue);
    if (URL) {BBcodeButtons.tagStart = ''; edInsertTag(i);}
    if (edCheckOpenTags(i)) {var myValue = prompt('Enter the text for the link', ''); edInsertContent(myValue); edInsertTag(i);}
    }
    else {edInsertTag(i);}
    }

    Or download 0.0.8 shortly.

Viewing 25 replies - 926 through 950 (of 2,186 total)