fel64 (@fel64)

Forum Replies Created

Viewing 25 replies - 876 through 900 (of 1,001 total)
  • @fel64

    Member

    The login form is also fairly differently organised (with the original theme making better use of the space).

    In reply to: Quote Plugin Weirdness

    @fel64

    Member

    Not sure what black magic you just haxed up there (MySQL I am fairly clueless about), I just did this:

    $quoted = bb_get_user( $row->poster_id );

    My full modifications are:

    function bb_quote_message() {
    global $bbdb, $topic;
    $post_id = (int)$_GET['quote'];
    if ($post_id) {
    $row = $bbdb->get_row("SELECT * FROM $bbdb->posts WHERE post_id={$post_id} AND topic_id={$topic->topic_id} AND post_status=0");
    $//row->post_text = preg_replace( '(|
    )', '', $row->post_text );
    $row->post_text = preg_replace( '/<blockquote>.*</blockquote>/', '', $row->post_text );
    $row->post_text = str_replace( '', '', $row->post_text );
    $row->post_text = str_replace( '
    ', '', $row->post_text );
    $quoted = bb_get_user( $row->poster_id );
    $quotesince = bb_since( $row->post_time );
    $quotesince = ' - ' . $quotesince . ' ago ';
    $quotelink = get_post_link( $row->post_id );
    $quotelink = '<a href="' . $quotelink . '">&nbsp;&raquo;&nbsp;</a>';
    if ($row) echo htmlentities('<blockquote><cite>'.$quoted->user_login . $quotesince . $quotelink . "</cite>n".$row->post_text.'</blockquote>', ENT_COMPAT, 'UTF-8');
    }
    }

    function fel_addcitetag( $tags )
    { $tags['cite'] = array();
    return( $tags ); }

    add_filter( 'bb_allowed_tags', 'fel_addcitetag' );

    You can see my regex attempt to get rid of blockquotes, although for some reason despite it being marked as code the b-quote tags were still removed.

    I also switched from regexing the paragraph tags tostr_replaceing them, which is apparently much faster. Again, though, they’re filtered out.

    In reply to: Quote Plugin Weirdness

    @fel64

    Member

    Keith: Yeah, it can. Easily. By WP handling it I really meant being smart enough to leave it alone. :P

    Aphelionz, you’re right. I feel stupid for such an oversight to the nesting problem. >_< However, my perl regexes aren’t particularly good and it’s not working (nor is it returning an error).

    $row->post_text = preg_replace( '/<blockquote>.*</blockquote>/', '', $row->post_text );

    If anyone knows how to fix that that’d be great.

    @fel64

    Member

    Speaking of which, it doesn’t add a topic-slug either, which is required to have permalinks set to slug. I tried adding the topic_slug field and a variable to make it update, but when I did that it didn’t work at all :( Can someone else have a look at this too?

    @fel64

    Member

    I also added a snippet of code to append a link to the last post.

    Find the end of the function page_links_add_links and replace this

    return $title;
    }

    with this

    $felgtlpl = get_topic_last_post_link($topic->topic_id);
    $title = $title . ' <a href="' . $felgtlpl . '">&nbsp;&raquo;&nbsp;</a>';

    return $title;
    }

    @fel64

    Member

    To get rid of the Keymaster thing the easiest thing to do is set a custom member title for yourself. That’s what I did. ^^

    In reply to: Numbered Posts

    @fel64

    Member

    Better yet, find the entry #thread in your style.css file and change the list-style entry there. It makes for nicer code. :)

    @fel64

    Member

    Not as far as I know. Although it’s HIGHLY not recommended, you could edit the name in the database (totally 100% at your own risk). It might be easier to create a new account and make him key master too and perhaps running a MySQL query to associate all old posts to the new account …

    In short, there’s no graceful way to do it that I know of.

    In reply to: Numbered Posts

    @fel64

    Member

    You can in fact replace decimal with many funky things.

    From w3 schools:

    • none
    • disc
    • circle
    • square
    • decimal
    • decimal-leading-zero
    • lower-roman
    • upper-roman
    • lower-alpha
    • upper-alpha
    • lower-greek
    • lower-latin
    • upper-latin
    • hebrew
    • armenian
    • georgian
    • cjk-ideographic
    • hiragana
    • katakana
    • hiragana-iroha
    • katakana-iroha

    Still haven’t tried it myself, just about to :P

    In reply to: Numbered Posts

    @fel64

    Member

    I believe that if you attach this to your CSS file:

    ol#thread li {
    list-style-type: decimal;
    }

    you would see the post numbers without any extra code, certainly the most elegant method. There is likely already a definition for ol#thread, so you could simply add this property to that one. Bear in mind that this is entirely untested (will try it when I get home).

    @fel64

    Member

    Did you set pretty permalinks to true?

    @fel64

    Member

    Sorry. AJAX is alien to me. Your best bet would be finding an AJAX forum. They were quite helpful here with a javascript problem I had: http://www.webdeveloper.com/

    @fel64

    Member

    Damn right!

    bbPress can’t toast your bagels, but a plugin for it sure could!

    In reply to: Emoticons For bbPress?

    @fel64

    Member

    Unfortunately you’ll need someone with some Javascript mojo to do that. It’s been done often enough before, but I presume it still requires some knowledge. :P

    @fel64

    Member

    Thanks for coming back and telling me :D

    @fel64

    Member

    The nice thing is you don’t actually need any of that. People can still read your posts if you don’t.

    But I know what you mean; a truly polished interface would be intuitively sensible. I’m not sure what you’re thinking of when you say a plugin to improve it beyond the Quicktags plugin? Obviously minor improvements are always possible, but can you think of a change to make it much easier?

    That’s not rhetorical :P

    @fel64

    Member

    I have no idea how the bb environment can be detected, but I think I know why your $forumpage hack didn’t work; the WP headers are in different files and such.

    When setting $forumpage, try something like this:

    global $forumpage = true;

    When checking if $forumpage is true, do it something like this:

    global $forumpage;
    if( $forumpage = true )
    {
    ...
    }

    If you tell PHP that you want the global variable $forumpage it should work.

    Not too confident about this, but that should tell PHP to make them global (ie. available everywhere). Otherwise you’ll probably be calling different variables called $forumpage.

    @fel64

    Member

    Hey Henry, unfortunately it isn’t working for me. Going to your forum and clicking on the Chinese tab gets me an error page in FF but not in IE7:

    The page isn't redirecting properly
    Firefox has detected that the server is redirecting the request for this address in a way that will never complete.
    * This problem can sometimes be caused by disabling or refusing to accept cookies.

    No idea why!

    In reply to: No ajax on replies

    @fel64

    Member

    I think this is default. I’d personally love a plugin that ajaxified posts or, even better, it being in by default but not yet.

    @fel64

    Member

    And the problem is only for Chinese tags? Plain english tags with no special characters work okay?

    In reply to: new version

    @fel64

    Member

    It’s unsure. Hopefully soon. If you can’t live without, get the trunk version from SVN.

    In reply to: Quote Plugin Weirdness

    @fel64

    Member

    Bah, this is bb (and WP) trying to be clever. It’s annoying; they both mess with your code too much. >_< Although at least WP can handle nested blockquotes.

    In reply to: Some links do not work

    @fel64

    Member

    I’m surprised you have the page parameter at the end of URLs linking to topics, I never had that.

    @fel64

    Member

    I’d have to read the forums, once again, to figure out what you mean.

    Or you could just ask us here. :) A large part of these forums is just for help making it work. You’d be happier with bbPress in the long run.

    The markup thing for example is quite simple; I struggled with it initially but a random guess worked out, and the quicktags certainly help. Any text between two backticks (on a European/English keyboard, the button just above tab) will be rendered as code. The ‘markup’ thing refers to HTML, so to make that work you do this:

    <em> makes your text italic </em>

    <br />
    like so will create a single new line.

    <ul> or <ol> will create a ‘list’ structure. Simply put <li> and </li> around each seperate list element. End the list by putting </ul> or </ol>.

    To create links, you do this: <a href="www.example.com/linklocation">link text</a>.

    In reply to: Numbered Posts

    @fel64

    Member

    Actually I think it does work. There was something I saw here about the OLs in threads having startnumbers (which didn’t validate was the point, I think), implying that you could change the OL styling and possibly display the (in the context of the thread) proper post numbers. I’ll look into it, if someone else doesn’t already know?

Viewing 25 replies - 876 through 900 (of 1,001 total)