Forum Replies Created
-
In reply to: Alter Loop for Paged Forum Pages?
$forum_one_topics = $bbdb->get_results("SELECT * FROM $bbdb->topics WHERE forum_id = $forum_id AND topic_status = 0 AND topic_sticky = 0 ORDER BY topic_id DESC LIMIT $limit OFFSET $offset");
updated to leave out sticky posts from the second loop (added AND topic_sticky = 0 to query).
If you leave out ‘$forum_id = 1;’ it will work on multiple forums.
I’ve done this so that my front page summary shows latest active posts, but my specific forum pages list by topic order.
In reply to: “pretty” permalinks in bbPressAs an aside, some hosts such as GoDaddy can take around 30 minutes for the .htaccess file to be read and implemented.
In reply to: latest wordpress stories (code)and my final correction on the random thing!
$stories = $bbdb->get_results("SELECT post_title, guid FROM site_posts WHERE post_type='post' AND post_status='publish' ORDER BY post_date_gmt DESC LIMIT 0,10");
shuffle($stories);previous example was getting a random 10 from all posts.
This get’s 10 latest posts, then randomizes them with the ‘shuffle’.
cheers!
In reply to: latest wordpress stories (code)On my version I’m fetching 10 latest rows, randomizing, then displaying 5 stories.
$bbdb->get_results("SELECT post_title, guid FROM site_posts WHERE post_type='post' AND post_status='publish' ORDER BY rand() LIMIT 0,10");
Admittedly, I didn’t make the correct alterations to the previous example. Anyway, it should give people an idea of what to do.
oh, and _ck_ I hadn’t spotted your earlier post – it would have made it a lot easier for me to figure out if I had!
In reply to: List all Tags?yes, that appears to be the problem, and most likely something to do with fetching the user id of the tag poster. As this will be, at this point, set to the last person who used that tag, and the current user cannot see who posted a tag unless it is theirs. So there will be some permissions problem going on.
let this be a lesson to you regarding editing core files!
In reply to: List all Tags?actually, mine does that too. Hadn’t noticed until now.
I’m not sure why it would do that but will have a look into it.
In reply to: Fatal error: Call to undefined functionget_header() is a wordpress function. If you try and load that within bbPress it will not know what to do with it, hence the error.
There are various discussion about this on this forum, but as yet I haven’t seen a successful way of loading wordpress function into bbPress.
In reply to: WordPress MU Cookies aren’t correct…In reply to: Plugin: Allow additional or custom profile fieldsDoes anyone know a way to adapt this to have a checkbox option, rather than a textfield?
In reply to: List all Tags?To get the ‘who posted that tag’ functionality in 1.06 you need to edit a core file (which is frowned upon – but we really need to moderate inappropriate tags and ban if necessary).
bb-includes/function.bb-template.php
and replace line 2529 with this:
$poster = get_user_name( $tag->user_id );
return "<small> - <a href="/forum/profile.php?id=$tag->user_id">$poster</a></small> [<a href='$url' class='delete:$list_id:tag-{$tag->tag_id}_{$tag->user_id}' title='$title'>×</a>]";where /forum/ is the subfolder of your forum.
It appears to be working well – users have their name next to the tags they posted, and the ability to delete their own tag; whilst not seeing who added the other tags.
In reply to: Theme template files to change for 1.0?in topic.php in your theme folder use
<?php bb_topic_admin(); ?>
instead of the ‘<?php topic_delete_link(); ?> <?php topic_close_link(); ?> <?php topic_sticky_link(); ?><?php topic_move_dropdown(); ?>’ (line 55)
Come to think of it I may have updated a core file.
and topic-tags.php becomes
<div id="topic-tags">
<p><?php _e('Tags:'); ?></p>
<?php if ( bb_get_topic_tags() ) : ?>
<?php bb_list_tags(); ?>
<?php else : ?>
<p><?php printf(__('No <a href="%s">tags</a> yet.'), bb_get_tag_page_link() ); ?></p>
<?php endif; ?>
<?php tag_form(); ?>
</div>(just replace the entire page)
This does break the improvements I suggested in https://bbpress.org/forums/topic/list-all-tags#post-23142 though. Although I have edited the core files (which is not encouraged) to bring back the functionality of showing who posted a tag to moderators.
In reply to: Theme template files to change for 1.0?When I switched to 1.0 the problems I remember were mostly on the administration side of things.
deleting tags with the little x in threads broke – there was a new function that pulled in all the moderator functions.
Moving topics to a different forum code.
From a users point of view their username linking to their website.
There may have been a few more…
all these were easily fixed by comparing with the kakumei theme that came in 1.0.
This looks great. I was very confused why WPMU doesn’t supply a list of numbers in the cookie like WP2.7 does. It was causing me to not be able to log into WPMU…
I will give this a go. Thanks.
the easiest way to deal with this may be to add a rel=”nofollow” to user urls.
Have a look at this:
https://bbpress.org/forums/topic/add-nofollow-to-links#post-4294
In reply to: Registration after Integrationalthough you may want to go and read this: https://bbpress.org/forums/topic/first-pass-at-a-fix-for-deep-integration-in-trunk
In reply to: Registration after Integration@circuit – I had the same problem when importing the wordpress header. It is not recommended to import wordpress as it causes unexpected errors like the one you have seen. It is advised to use plugins to replicate wordpress functionality – although I have not seen one to date.
At the moment I am faking my wordpress theme in bbpress.
I presume future versions of bbpress will allow deeper integration.
In reply to: Profile edit does not update website field (fail)Yes, saw that it was fixed, thanks.
Just noticed that I couldn’t update ‘Rex’ because he had another account with the same email address which he must have made before I installed the ‘no duplicate email addresses’ plugin.
In reply to: Profile edit does not update website field (fail)I’m not sure what the pattern is… we have one user by the name of Rex that won’t allow email address updates. That is the only one we’ve found, users like ‘tom’, or ‘Tom’ update fine.
In reply to: tag remove fail@ganzua, are you using v1.06a?
In reply to: Profile edit does not update website field (fail)Just noticed now that on *some* users I am unable to update their email address. There doesn’t appear to be a pattern as yet.
If they’ve previously posted, or short usernames doesn’t make any difference.
Is this a known bug?
In reply to: tag remove failUpdate:
the little x next to tags does delete them in an ajax style. The problem was after updating from 0.9 to 1.0 I did not update my themes properly.
topic_tags(); now covers the whole thing – taking the add tag form from line 2457 on functions.bb-template.php
of course! why didn’t I think of that?
Anyway, thank you very much. You deserve an award. Both those options work.
come on, someone must know how to do this.
I can limit it to one forum with this:
<?php $topics = get_latest_topics( 1 ); ?>
but I want $topics to get forums 1 and 2 (but not 3).
In reply to: Registration after IntegrationIpstenu – thanks for replying. On another test installation where I’ve been experimenting with integration the registration is working fine through bbP. Not sure why it wasn’t on the other installation I was running.
In reply to: Registration after IntegrationCan someone just confirm that user registration should work through bbPress after integrating WP2.7 and bbP 1.06a?
…and if so why mine isn’t!!??!!