Forum Replies Created
-
In reply to: Which filter/action hook should I use?
I’m sorry if I just copy and paste what I said before but I’m not sure you saw.
Then the
somequote
function finds theli
whereid
ispost-#
, extracts the post text (this depends somewhat on the page HTML but should work) and puts it in the post box at the bottom. Thesomequote
function can also use the DOM probably to take out blockquotes.The key bit is that the function is only passed the post ID. It can get the post HTML perfectly simply itself with the getElementById method. And then remove the
<blockquote>
elements.In reply to: bbPress Login from WordPressThat may have been factually accurate, but telling him that it’s been solved and he should go search is not helpful. Linking him to a solution would be.
In reply to: plugin: bb-PollsCan you use
$bbdb->escape()
? In future you could even use$bbdb->prepare()
but I’m not sure how that one works.In reply to: bbPress Login from WordPressAre your usertables integrated? If they are it shouldn’t matter what login form you use and your userdetails should be identical, a change in one system resulting in a change in the other. In that case you can simply but the WP login forms back and integrate cookies.
If they are not integrated and you don’t want to do so, a solution could be to load bbPress when you load WP [edit: but again unless you’re integrated you’ll have function name collisions so that’s not an option] and use the
login_form()
I believe it is template tag.Or you could just look at what the bbP output login form is like, copy the HTML into wordpress and let users use that. No reason why that shouldn’t work.
ganzua, that’s not all that helpful.
In reply to: Which filter/action hook should I use?What I think you should do is use a bit of nifty javascript, like so:
<a href="" onclick="somequote( /* post_id */ ); return false;">Quote</a>
Then the somequote function finds the li with id
post-#
, extracts the post text (this depends somewhat on the page HTML but should work) and puts it in the post box at the bottom. Thesomequote
function can also use the DOM probably to take out blockquotes. Quoting people isn’t something that needs bookmarking, at least not for my tastes, and reloading the page is annoying. But then quoting people is usually annoying anyway. You’re on a forum, why do you have to quote someone else’s post if other people can see it just above? Meh, personal preferenceIn reply to: bbSyncYeah. Someone’s already tagged it modlook but it seems that Trent, mdawaffe and matt are all away or not checking it.
In reply to: plugin: bb-PollsSerializing data is only bad if you are going to be constantly unserializing it in the same bbpress instance.
_Anything_ is bad if you do it unnecessarily. I don’t understand why you were unhappy with serialising earlier in this case.
Obviously topicmeta is there to be used for topicmeta. That doesn’t mean it needs to store everything that could be construed as topicmeta. My question wasn’t what where the orthodox place to store topicmeta was, but a comparison of unserialising very large arrays vs. a single query. But then I think that serialising is linear, anyway, so it probably remains very good value.
In reply to: plugin: bb-PollsI’m _not_ saying it’s better. It could be. I’m just wondering about other people’s thoughts and reasons on optimising this.
In reply to: plugin: bb-PollsCan someone demonstrate what the polls are like? Has someone got one live to look at?
_ck_, you’re storing who voted for what in the topicmeta, right? You mentioned that unserialising stuff was a huge performance hit earlier, wouldn’t this be an issue especially with a large number of voters? What are your thoughts about implementing a bb_votes table to record who voted and how? (I’m not saying that’s better, I’m just wondering what your thoughts are on this because it interests me
)
LOL! so why did everyone cry out for a poll plugin then?
I’m not sure everybody did.
In reply to: bbSyncAlright. That makes it somewhat more difficult because I cannot tell what functions are called with that hook, but maybe it is possible to find out.
No post, you say? The mystery deepens.
Thanks for the phpinfo. Unfortunately OS X is somewhat difficult for me … perhaps I’ll be able to do this at a friend’s house. We shall see.
Cheers.
In reply to: Encoding problemI think you posted it on trac already? Which was the right place to post it. It might not be fixed immediately but it should be soon.
In reply to: Good model plugin for newbie plugin author to study?What? do_action syntax is like this:
do_action( $tag, $function_name [, $priority] );
$latlong
is the value, in this case latitude/longitude.In reply to: mysql_query() OR $bbdb->get_results() ?You need something like TortoiseSVN that’ll let you apply patches to files.
In reply to: Should I get an email when new users are created?I don’t get emails for dudes registered through bb and you shouldn’t. bb updates the database but wp’s registering hooks are not triggered AFAIK.
In reply to: Good model plugin for newbie plugin author to study?You could just SELECT topic_id, meta_value FROM topicmeta WHERE meta_key = ‘topic_geolocation’, AND more stuff applied to meta_value if you want. It’s doable in one query.
In reply to: Caching in bbPress?There is soft user/topic caching, but there’s no hard caching yet. If you look at the code, in cache.php, you’ll see that it’s written to enable file-based caching in bb-cache/, but doesn’t seem to do so at the moment. It probably will in future I guess? If you fiddle you could probably turn it on. mdawaffe is now working on xml-rpc when he’s working on bb at all, so it’s not the next feature at least. I also think he was planning something else for .8.4.
In reply to: Full Content of Most Recent Post on Front-Page?Turn the time-string into a timestamp to be turned into a time-string.
<?php echo date( 'g:i A', strtotime( $latestpost->post_time ) ); ?>
There’s a template function that gives you the link to the latest post in the topic. I believe it’s called
get_topic_last_post_link()
but I’m not sure.In reply to: bbPress themes / templates directory, does it exist?I’m sure that folks have thought of that but I think that like official documentation that’s a post-1.0 priority.
In reply to: Plugin: [REL] SignatureActually,
post_form
is called immediately before the form is closed.https://trac.bbpress.org/browser/trunk/bb-includes/template-functions.php#L163
In reply to: Good model plugin for newbie plugin author to study?Yeah, really avoid doing anything to the tables and use topicmeta instead. By far easiest for you and nicest for the users, too, plus the additional overhead is minimal.
The metadata is returned when you call get_topic() like Sam said.
$topic = get_topic();
echo $topic->topic_geolocation; //echoes whateverIn reply to: Redirect TrackbacksNot possible yet as trackbacks aren’t yet implemented in bb. But I’ll add it to bbSync when it’s possible.
In reply to: AdityaNaik.comLoading bb when you load wp, coolio. That’s what I wanted to know.
In reply to: One svn repo for multiple projects?The important thing is being able to tag, branch and trunk, and I believe you can do that on any folder. So you can do that with no real problem. Not sure how milestones, bug reports etc. will be split, though.
This is what google gives me: http://svnbook.red-bean.com/en/1.1/ch05s04.html
In reply to: bbSyncDid you try downloading from the plugin browser? https://bbpress.org/plugins/topic/56
Trent if you see this could you take out the rapidshare link from the first post and replace it please?
In reply to: Plugins SVN ProblemI really don’t know. Maybe, especially if it happens again, you could send an email on the bbDev list just to get mdawaffe aware of it.