Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'code'

Viewing 25 results - 29,126 through 29,150 (of 32,499 total)
  • Author
    Search Results
  • #59880
    benbeltran
    Member

    ahh, I see :) It’s nice. Well, if you ever need hosting, do contact me. That’s the least I could do for the best bbpress plugin coder :D.

    #60077

    In reply to: top 100 bbPress sites

    benbeltran
    Member

    @airdrawndagger: Thanks :D I’m glad it made you switch to this great software.

    @vlp: Sorry, I didn’t quite understand. The page number, like for every page on the forum that’s displayed on the front page? If it’s that, there’s a plugin for that :o… but I get the feeling that’s not what you meant.

    @baptiste: I like the blue theme from baptiste.us … :) Though maybe the blue text should be a bit clearer when its on blue backgrounds.

    #60076

    In reply to: top 100 bbPress sites

    baptiste
    Member

    Not much traffic – but I’ve got Refresh going for my plugin blog and forums. Matches quite nicely – I mucked with the themes a bit but the ports were done by others thankfully. Getting the integration and WP sidebar on the forums took some fun mucking in the code…

    http://plugins.baptiste.us/

    http://plugins.baptiste.us/forums/

    One of these days I’ll diff the changes I made to the Refresh port to get it to match the WP theme and have everything line up properly…

    This site is still under development:

    http://onthepitch.org/talk/

    Still need to tweak the theme some, but I’ve made a variety of navigational changes. Click any topic and look at the meta section. Click on a forum and note the navigation links. Click on a subforum and note the breadcrumb trail. On the front page – I like having the latest posts first, but added a ‘Forums’ column to indicate where they were and make it easier for folks to jump into a forum (no scrolling down for active forums)

    Still a bit to do, but it’s working better each day. The theme will eventually be green – thus the green ads. I keep trying to convince myself NOT to shoehorn in AJAX posting – but I really miss it – something that made bbPress ‘cool’

    #60413
    fel64
    Member

    Some things you can change in the template, some things are hardcoded. I’m not sure what you mean but if something isn’t done in the template and you think it should be changed (everywhere) then you can report bugs, defects, possible enhancements on trac: http://trac.bbpress.org.

    #60419

    In reply to: avatar

    fel64
    Member

    I suggest giving your post div an appropriate min-height. It’s easiest and most elegant. Forget tables.

    #60074

    In reply to: top 100 bbPress sites

    benbeltran: Your forum is what made me decide on going with bbpress :)

    #60352

    benbeltran: That’s why I put “theme” in the topic title, rudely looking to steal what someone else had already created :) I know, I’m terrible!

    #60123

    C’mon! Anyone? My users are abandoning the forum :(

    #55739

    In reply to: Anonymous posting

    rashantha
    Member

    i don’t see any instruction on how to use this code. do you have any tips?

    #55738

    In reply to: Anonymous posting

    matt123
    Member

    Just wanted to put up a link to where to find the code to make anonymous posting happen. It took me a lot of searching before I found it. Works like a charm only problem is that it tries to let you pm the anonymous person.

    https://trac.bbpress.org/ticket/633

    #60406

    In reply to: Anonymous Post

    rashantha
    Member

    okay so i found some talk about anonymous post.

    it seem like there is no solution at the moment other than a suggestion of ‘anonymous’ ‘anonymous username/password combo.

    how about a simple plugin that ask to decode a number sequence like in facebook.

    does anyone have anything like this?

    #60366
    chrishajer
    Participant

    Did you try recounting from the admin panel?

    Admin > Site Management > Recount

    "The following checkboxes allow you to recalculate various numbers stored in the database. These numbers are used for things like counting the number of pages worth of posts a particular topic has. You shouldn't need to do do any of this unless you're upgrading from one version to another or are seeing pagination oddities."

    (sure wish blockquotes were styled here!)

    #2333
    gusext
    Member

    Hi all.

    (Sorry for my bad english. I tried to be verbose in order to avoid my bad english affect your understanding)

    I wrote a plug-in, in order to have the best rewrite rules (in my opinion :p ) in the world.

    this plugin achieves two things:

    One: I need to show, in the URL, the logical parent-to-child relation between forums and topics, so

    http://www.example.com/bbpress/topic/my-sweet-dog

    URL has to show the forum that contains the topic, and become

    http://www.example.com/bbpress/forum/pets-discussions/topic/my-sweet-dog

    when performing the rewrite, the rules totally ignore the forum part, so it’s only a visual thing.

    and, more difficult,

    Two: I need to shorten the URL and have fewer subdirectories, so

    http://www.example.com/bbpress/forum/pets-discussions/topic/my-sweet-dog

    has to lose the useless “/forum/” and the useless “/topic/” parts, and become

    http://www.example.com/bbpress/pets-discussions/my-sweet-dog

    ATTENTION: you cannot do the second thing without the first thing. you must be able, in rewrite rules, to discriminate between a topic and a forum. you then will have that forums have one string (the forum slugged name), while topics have two strings (the forum slugged name and the topic slugged name), so you can do that, and /pets-discussion/my-sweet-dog will belong to “My Sweet Dog” topic in “Pets Discussions” forum

    In order to do so, I need to

    – modify forum link creation

    – modify topic link creation

    – modify rewrite rules

    – avoid a forum to have a reserved name, as using bbpressfolder/forumname to reach a forum is risky! I have to prevent a forum from having a slugged name like “bb-admin”!!! here’s a list of reserved words:

    – all words with a dot. those are files, like style.css and so on. the slugged names never have a dot. I have only to avoid rewrite of dotted words.

    – all bbpress subfolders and special folders. these are all that start with

    bb-* , my-*

    – every other reserved word already used by rewrite engine:

    tag, profiles, view, rss

    All this is achieved adding a “r-” string in front of the slugged string. so a forum named “My Forum!” will have “r-my-forum” as slugged name. Unfortunately, this filter operates also for topic names and maybe other things. this mean that a topic named “rss” will have “r-rss” as slugged name. Not so bad, in facts.

    So these are the operations:

    – add a filter to get_forum_link (delete the “/forum” part)

    – add a filter to get_topic_link (add the “forum/slug-forum-name” in the link, and eliminate the “/forum” and “/topic” parts)

    – modify the rewrite rules (I used IIS isapirewrite, but apache is pretty the same)

    – add a filter to bb_slug_sanitize (avoid a forum to have a reserved word as slugged-name, like “rss”, “profiles”, “my-plugins”, etc

    And there is the code for these operations:

    function my_get_forum_link_filter( $link , $forum_id = 0 ) {
    //retrieve the forum object
    $forum = get_forum( get_forum_id( $forum_id ));

    //check for rewrite
    $rewrite = bb_get_option( 'mod_rewrite' );
    if ( $rewrite ) {
    //what kind of rewrite there is? slug use "forum_slug" column, else the column is "forum_id"
    $column = ($rewrite === 'slugs')?('forum_slug'):('forum_id');

    // change /forum/pets-discussions in /pets-discussions
    // this work only if the rewrite module is modded!
    // and this work only if the slugged name will NEVER
    // be a reserved word like "rss" or "bb-images"
    // and this is achieved by a filter on bb_slug_sanitize
    $link = str_replace('forum/' . $forum->$column , $forum->$column, $link);
    }
    return $link; // Very important line!
    }

    add_filter( 'get_forum_link', 'my_get_forum_link_filter' );

    function my_get_topic_link_filter( $link, $topic_id = 0) {
    //retrieve the topic object
    $topic = get_topic( get_topic_id( $topic_id ));

    //retrieve the forum object that is the topic container
    $forum = get_forum( get_forum_id( $topic->forum_id ));

    //check for rewrite
    $rewrite = bb_get_option( 'mod_rewrite' );
    if ( $rewrite ) {
    //what kind of rewrite there is? slug use "forum_slug" column, else the column is "forum_id"
    $column = ($rewrite === 'slugs')?('forum_slug'):('forum_id');

    //create the "forum/pets-discussions" chunk to show the hierarchical relation forum->topic
    $forum_nice_uri = "forum/" . $forum->$column . "/";

    //attach the hierarchical chunk to the link
    $link = str_replace(bb_get_option('uri'), bb_get_option('uri') . $forum_nice_uri, $link);

    // change /forum/pets-discussions/topic/my-sweet-dog in /pets-discussions/my-sweet-dog
    // this work only if the rewrite module is modded!
    // and this work only if the slugged name will NEVER
    // be a reserved word like "rss" or "bb-images"
    // and this is achieved by a filter on bb_slug_sanitize
    $link = str_replace('forum/' . $forum->$column , $forum->$column, $link);
    $link = str_replace('topic/' . $topic->$column , $topic->$column, $link);
    }

    return $link; // Very important line!
    }

    add_filter( 'get_topic_link', 'my_get_topic_link_filter' );

    function my_bb_slug_sanitize_filter( $text_slug, $text_original = '', $length = 0 ) {
    // add "r-" by regex when the string begins with "bb-" or "my-" or is a reserved word
    return preg_replace('/^(my-.*|bb-.*|rss|tags|view|profiles)$/', 'r-$1', $text_slug);
    }

    add_filter( 'bb_slug_sanitize', 'my_bb_slug_sanitize_filter' );

    And there’s the rewrite rules! ATTENTION!!!!! these rules are for IIS isapirewrite, so these are to be modded to work with apache! sorry but I don’t have any apache installation to play with. It’s a simple task, anyway. Every regex guru and regex accolite can do that. Even a regex wannabe can find out googling.

    #	first we rewrite the pages for normal slug-rewrite usage

    RewriteRule /bbpress/tags/([^/?]+)/page/([0-9]+)(?:?(.*))? /forum2/tags.php?tag=$1&page=$2?3&$3: [I,L]
    RewriteRule /bbpress/tags/([^/?]+)/?(?:?(.*))? /forum2/tags.php?tag=$1?2&$2: [I,L]
    RewriteRule /bbpress/tags/?(?:?(.*))? /forum2/tags.php(?1?$1:) [I,L]
    RewriteRule /bbpress/profile/([^/?]+)/page/([0-9]+)(?:?(.*))? /forum2/profile.php?id=$1&page=$2?3&$3: [I,L]
    RewriteRule /bbpress/profile/([^/?]+)/([a-z-]+)(?:?(.*))? /forum2/profile.php?id=$1&tab=$2?3&$3: [I,L]
    RewriteRule /bbpress/profile/([^/?]+)/([a-z-]+)/page/([0-9]+)(?:?(.*))? /forum2/profile.php?id=$1&tab=$2&page=$3?4&$4: [I,L]
    RewriteRule /bbpress/profile/([^/?]+)/?(?:?(.*))? /forum2/profile.php?id=$1?2&$2: [I,L]
    RewriteRule /bbpress/view/([a-z-]+)/page/([0-9]+)(?:?(.*))? /forum2/view.php?view=$1&page=$2?3&$3: [I,L]
    RewriteRule /bbpress/view/([a-z-]+)(?:?(.*))? /forum2/view.php?view=$1?2&$2: [I,L]
    RewriteRule /bbpress/rss/(?:?(.*))? /forum2/rss.php?1&$1: [I,L]
    RewriteRule /bbpress/rss/forum/([0-9]+)(?:?(.*))? /forum2/rss.php?forum=$1?2&$2: [I,L]
    RewriteRule /bbpress/rss/topic/([0-9]+)(?:?(.*))? /forum2/rss.php?topic=$1?2&$2: [I,L]
    RewriteRule /bbpress/rss/tags/([a-z-]+)(?:?(.*))? /forum2/rss.php?tag=$1?2&$2: [I,L]
    RewriteRule /bbpress/rss/profile/([0-9]+)(?:?(.*))? /forum2/rss.php?profile=$1?2&$2: [I,L]

    # then we have a rule for special words, so they are left as they are, and the isapi module does not proceed further

    RewriteRule /bbpress/(my-.*|bb-.*|rss|tags|view|profiles)(/.*)? /forum2/$1$2 [I,L]

    # then we have the forum and topic rules.
    # ATTENTION: we DO NOT rewrite a dottet word, because dotted words can be files like style.css and so on

    # before there are the topic rewrites, that are longer
    # ATTENTION: note that the forum name is totally skipped trough ?: notation. In facts, bbpress doesn't need the forum name when reading a topic
    RewriteRule /bbpress/(?:[^./?]+)/([^./?]+)/page/([0-9]+)(?:?(.*))? /forum2/topic.php?id=$1&page=$2?3&$3: [I,L]
    RewriteRule /bbpress/(?:[^./?]+)/([^./?]+)/?(?:?(.*))? /forum2/topic.php?id=$1?2&$2: [I,L]

    # and after there are the forum rewrites, that are shorter
    RewriteRule /bbpress/([^./?]+)/page/([0-9]+)(?:?(.*))? /forum2/forum.php?id=$1&page=$2?3&$3: [I,L]
    RewriteRule /bbpress/([^./?]+)/?(?:?(.*))? /forum2/forum.php?id=$1?2&$2: [I,L]

    And that’s all. I hope someone can use this plugin :)

    Gus

    email: shiawase at gmail dot com

    #2331
    wpitn2shape
    Member

    I want to hook, et whatever, into the author id of a post to make my avatars plugin work with BBPress.

    The docs just say it’s the same as WordPress, but not exactly. The tags are different and my original plugin doesn’t work anyway (or perhaps it’s an integration problem with my installs. I’m running MU).

    I’m looking for equivalents like these or anything related

    $the_author = get_the_author_id();

    Where are the docs for the plugin API, basically? I don’t require you to look into what exact hooks, etc. I need, just lead me to info. If you want to do more, that’s fine, too. :-)

    #60363
    wpitn2shape
    Member

    An update:

    I don’t think my integration in general is working too well, because my avatar from my own avatar plugin is not displaying my user’s av. Of course this could be my plugin, and perhaps I need to work on an integration for THAT, too – ha ha.

    But I’m really worried about my MU integration..

    Looking closer I think it is the plugin in the sense that the post doesn’t bring up WP-type post code, but BBPress and the plugin doesn’t have that written. It’d have been nice for it to be more integrated on its own. I read others use their plugins on the forum pages. Sigh.

    #2326
    baptiste
    Member

    I’ve been working on updating a theme to be more ‘navigable’. I found the new_topic function could not be used when viewing a topic, so I modified the function to return a proper ‘Add New Topic’ link when called from a topic view (topic.php)

    The code changes can be found in ticket 736:

    http://trac.bbpress.org/ticket/736

    Here I added a ‘New Topic’ link in the topic meta section:

    http://onthepitch.org/talk/topic/coaching-youth-soccer

    #59879
    _ck_
    Participant

    I need to go back and change the bottom into a table like I did with the FutureKind theme. That will solve both the border on the headers and the spacing is an easy fix with line-height. I haven’t released it because I still have to clean up some CSS laziness that I did and put in some conditional code for bb-topic-views (so it will still work right if people don’t have it installed)

    The server load on dreamhost is always wrong (as with their microtime so the page render time is always wrong). Dreamhost uses a NFS filesystem where the files are remote from the server the code is executing on. So if there is a file queue, the load will be artificially high, it’s not CPU load, it’s disk load (which affects the overall load numbers).

    I only paid $20 for that dreamhost (for a year promo) and will not be renewing. It’s mind-boggling that some people pay over $100 a year for that hosting.

    #57091
    baptiste
    Member

    I put together a plugin that will allow you to include navigation links to flip forward or backward through forums and/or topics within a forum.

    http://plugins.baptiste.us/plugins/nav-links-for-bbpress/

    This is a first stab. No online config, etc. yet – just the main code to get the right links and forum/topic IDs. I hope to add some things to it and improve the API a bit to let templates get individual ‘next’ or ‘previous’ links.

    I ended up having to do direct DB queries – I couldn’t find a way in the main bbPress code to get me the info I needed, but I’m not super familiar with the core code either so I may have missed something. But no functions or class methods jumped out at me.

    I’ll post the bbPress plugin URL for it once it’s approved, but you can download it from the link above.

    Here’s a look at what it does on a forum I’m still setting up/messing with.

    Topic Nav – look in the meta section under the RSS link:

    http://onthepitch.org/talk/topic/test-topic-2

    Forum Nav – look under the list of topics:

    http://onthepitch.org/talk/forum/soccer-parents

    Yes – I know the forum navigation disappears in forums with no posts – side effect of the action hook I used to insert (it seems to return without applying filters when there are no posts – which I guess makes sense if you’re figuring there’s nothing to ‘filter’. But many filers append :( )

    This definitely makes navigation for my setup much easier.

    #59878
    neyoung
    Member

    When are you going to make kakumei too available _ck_ ? I’ve been drooling over it for a week or two now :)

    #59877
    benbeltran
    Member

    Aha! It’s nice, I think it needs a small bottom border on the Views and Hot Tags headers, you know, like the other headers ^_^.

    Again, I think the list of views could use a bit more space between lines.

    Seriously, what’s with your serverload O_O. Do you want some free hosting for that stuff? It’s not healthy to live in a server with 9+ server load.

    #60301
    chrishajer
    Participant

    Do you have a file called /my-templates/ronjroy/screenshot.png ? AFAIK, it needs to be a png, it needs to be called screenshot.png and it needs to be in that directory. If it is, then I’m not sure what the problem is. That works for me. Mine is 300×225 also, not sure what happens when it’s smaller or larger than that.

    #60259
    _ck_
    Participant

    It’s kinda offtopic for here but it’s such an easy fix.

    The reason why the news doesn’t turn white is because the link does not have the class “current_page_item” set. It should be something like <a class=current_page_item href= but I am not familiar with your menu system, if it’s hard coded or if it’s part of some plugin.

    I am guessing it’s hard coded and then it would be just a matter of editing the template for the news page to add class=current_page_item

    #57090
    baptiste
    Member

    This is definitely worth doing. bbPress needs to have template functions that allow you to get the ‘next’ or ‘previous’ forum and topic. This would allow themes to include nice navigation links like ‘Next Thread’, ‘Next Forum’ instead of always having to jump to the front. WordPress does this for posts.

    I’ve looked all around and I’m just not seeing anything like this.

    I’m going to mess around with some code – it looks like the BB_Walker has a stepping ability built in that SHOULD make this pretty trivial, but I’m still getting comfortable with the inner bbPress classes and such. I’ll post here if I come up with anything. If anyone else has tried this or knows of a plugin that exists already – let me know. I couldn’t find one. Again – this isn’t pagination when you have lots of posts/threads. This is when you are in a topic or post view, being able to navigate to the next post, thread, or forum – i.e. like flipping pages of a book.

    #58895
    _ck_
    Participant

    No I don’t mean a folder within a folder, that’s just fine and not a problem. I mean executing one within the other where they are both running at the same time on one page. That’s a huge amount of code and memory for any server, shared or dedicated.

    The nice thing about the registration and login process is you can route back to any page you want as the wordpress system is much more developed. I have the code around here somewhere and posted it before…

    see #5 on the list in this post:

    https://bbpress.org/forums/topic/user-intregation-between-wordpress-038-bbpress-not-work?replies=7#post-10428

    #58893
    _ck_
    Participant

    Ah apparently Detective’s method is for sites running WP at the same time as bbPress (not just integrated, running within each other – which I do not recommend). So this won’t work for most people.

    I solved the problem by forcing all registration links to go through WordPress but obviously that’s not a perfect answer (and needs core hacks).

    So this problem needs to be revisted again :-(

Viewing 25 results - 29,126 through 29,150 (of 32,499 total)
Skip to toolbar