<?xml version="1.0" encoding="UTF-8"?><!-- generator="bbPress" -->

<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
>

<channel>
<title>bbPress support forums User Favorites: intellivision</title>
<link>http://bbpress.org/forums/</link>
<description>bbPress support forums User Favorites: intellivision</description>
<language>en</language>
<pubDate>Fri, 21 Nov 2008 22:52:00 +0000</pubDate>

<item>
<title>mazdakam on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-10102</link>
<pubDate>Fri, 10 Aug 2007 10:34:58 +0000</pubDate>
<dc:creator>mazdakam</dc:creator>
<guid isPermaLink="false">10102@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;:D _CK_ i could not udrestand what should i do you mean i found &#60;/p&#62;
&#60;p&#62;function get_view_count ( $topic_id )&#60;br /&#62;
and&#60;br /&#62;
function initialize_view_count( $topic_id )&#60;/p&#62;
&#60;p&#62;and put this line above them?&#60;br /&#62;
if (!$topic_id) return;
&#60;/p&#62;</description>
</item>
<item>
<title>_ck_ on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-10078</link>
<pubDate>Thu, 09 Aug 2007 15:48:20 +0000</pubDate>
<dc:creator>_ck_</dc:creator>
<guid isPermaLink="false">10078@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;Ah I know what it is after studying the code a bit.&#60;br /&#62;
They never planned on  $topic_id being null or not set, so it's being inserted into the query as blank.&#60;/p&#62;
&#60;p&#62;mysql is getting something like&#60;br /&#62;
&#60;code&#62;SELECT meta_value FROM $bbdb-&#38;gt;topicmeta WHERE topic_id =  AND meta_key=&#38;#39;views&#38;#39;&#60;/code&#62;&#60;br /&#62;
see the blank before AND? It's unacceptable to mysql, needs to be a value.&#60;/p&#62;
&#60;p&#62;hack&#60;br /&#62;
&#60;code&#62;function get_view_count ( $topic_id )&#60;/code&#62;&#60;br /&#62;
and&#60;br /&#62;
&#60;code&#62;function initialize_view_count( $topic_id )&#60;/code&#62;&#60;/p&#62;
&#60;p&#62;and make a new first line for each that says&#60;br /&#62;
&#60;code&#62;if (!$topic_id) return;&#60;/code&#62;&#60;/p&#62;
&#60;p&#62;Should be a dirty workaround until the author can take a look.
&#60;/p&#62;</description>
</item>
<item>
<title>mazdakam on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-10073</link>
<pubDate>Thu, 09 Aug 2007 10:33:31 +0000</pubDate>
<dc:creator>mazdakam</dc:creator>
<guid isPermaLink="false">10073@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;i got this error too
&#60;/p&#62;</description>
</item>
<item>
<title>outchy on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-9370</link>
<pubDate>Thu, 26 Jul 2007 13:53:54 +0000</pubDate>
<dc:creator>outchy</dc:creator>
<guid isPermaLink="false">9370@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;this works really well on the front page, although i'm having a slight issue with my dashboard.  when this plugin is active, i get the following error text on the right-hand side:&#60;/p&#62;
&#60;p&#62;Recently Moderated&#60;/p&#62;
&#60;p&#62;* Post on&#60;/p&#62;
&#60;p&#62;bbPress database error: [You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND meta_key='views'' at line 1]&#60;br /&#62;
      SELECT meta_value FROM bb_topicmeta WHERE topic_id = AND meta_key='views'&#60;/p&#62;
&#60;p&#62;bbPress database error: [You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' 'views', )' at line 1]&#60;br /&#62;
      INSERT INTO bb_topicmeta ( meta_id, topic_id, meta_key, meta_value) VALUES ( NULL , , 'views', )&#60;br /&#62;
      Welcome to SK6Fans.com by neddi.&#60;/p&#62;
&#60;p&#62;Here is a &#60;a href=&#34;http://www.manonfire.cc/images/errortext.png&#34;&#62;screenshot&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;Any thoughts?
&#60;/p&#62;</description>
</item>
<item>
<title>_ck_ on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-9276</link>
<pubDate>Tue, 24 Jul 2007 16:22:30 +0000</pubDate>
<dc:creator>_ck_</dc:creator>
<guid isPermaLink="false">9276@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;I've now come up with an extremely easy/fast way to grab and display the views per forum in the forum list on the front page (or forums with sub-forums.&#60;/p&#62;
&#60;p&#62;Here's the plugin:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;function forums_views_append($forums) {
global $bbdb; $sum_meta_value=&#38;quot;SUM(meta_value)&#38;quot;;
$forums_views = $bbdb-&#38;gt;get_results(&#38;quot; SELECT $sum_meta_value,forum_id FROM $bbdb-&#38;gt;topicmeta LEFT JOIN $bbdb-&#38;gt;topics ON $bbdb-&#38;gt;topicmeta.topic_id = $bbdb-&#38;gt;topics.topic_id  WHERE $bbdb-&#38;gt;topicmeta.meta_key=&#38;#39;views&#38;#39;  GROUP BY $bbdb-&#38;gt;topics.forum_id&#38;quot;);
foreach ($forums_views as $forum_views) {$forums[$forum_views-&#38;gt;forum_id]-&#38;gt;views=$forum_views-&#38;gt;$sum_meta_value; }
return $forums;
}
add_filter(&#38;#39;get_forums&#38;#39;,&#38;#39;forums_views_append&#38;#39;);&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;To display the views, edit your front-page.php template and insert a views header and views column like so:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;th&#38;gt;&#38;lt;?php _e(&#38;#39;Views&#38;#39;); ?&#38;gt;&#38;lt;/th&#38;gt;
	&#38;lt;th&#38;gt;&#38;lt;?php _e(&#38;#39;Topics&#38;#39;); ?&#38;gt;&#38;lt;/th&#38;gt;
	&#38;lt;th&#38;gt;&#38;lt;?php _e(&#38;#39;Posts&#38;#39;); ?&#38;gt;&#38;lt;/th&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;.&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;td&#38;gt;&#38;lt;?php echo $forum-&#38;gt;views; ?&#38;gt;&#38;lt;/td&#38;gt;
	&#38;lt;td&#38;gt;&#38;lt;?php forum_topics(); ?&#38;gt;&#38;lt;/td&#38;gt;
	&#38;lt;td&#38;gt;&#38;lt;?php forum_posts(); ?&#38;gt;&#38;lt;/td&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;Since there is no clean way to store forum meta data right now in bbpress (apparently an oversight) this will run on every time the forums list is displayed. Maybe not such a good idea for very busy forums, even though it's a single mysql query (nifty eh?).&#60;/p&#62;
&#60;p&#62;Eventually I'll figure out a nice way to store this and only update upon new posts or new topics to reduce overhead (or a cron job perhaps).
&#60;/p&#62;</description>
</item>
<item>
<title>_ck_ on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-9220</link>
<pubDate>Sun, 22 Jul 2007 13:38:51 +0000</pubDate>
<dc:creator>_ck_</dc:creator>
<guid isPermaLink="false">9220@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;Here's a plugin to extend the topic-views plugin and add a &#34;most-views&#34; view page (ie. view.php?view=most-views)&#60;/p&#62;
&#60;p&#62;It does it with a minimum number of mysql calls, just 10 to display an entire page on my setup. You have to hack your views.php template to add the views column,  use $topic-&#38;gt;views for the view count to use the cached data in memory instead of an extra mysql query for each topic.&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;function most_views_views( $views ) {
	global $views;
	$views[&#38;#39;most-views&#38;#39;] = &#38;#39;Topics with the most views&#38;#39;;
	return $views;
}
add_filter(&#38;#39;bb_views&#38;#39;, &#38;#39;most_views_views&#38;#39;);

function most_views( $view ) {
global $bbdb, $topics, $view_count;
switch ( $view ) :
case &#38;#39;most-views&#38;#39; :
$limit = bb_get_option(&#38;#39;page_topics&#38;#39;);
$where = apply_filters(&#38;#39;get_latest_topics_where&#38;#39;,&#38;#39;&#38;#39;);
$most_views = $bbdb-&#38;gt;get_results(&#38;quot;SELECT topic_id FROM $bbdb-&#38;gt;topicmeta WHERE meta_key=&#38;#39;views&#38;#39; ORDER BY cast(meta_value as UNSIGNED) DESC LIMIT $limit&#38;quot;);
foreach (array_keys($most_views) as $i) {$trans[$most_views[$i]-&#38;gt;topic_id] =&#38;#38; $most_views[$i];} $ids = join(&#38;#39;,&#38;#39;, array_keys($trans));
$topics =&#38;quot;SELECT * FROM $bbdb-&#38;gt;topics WHERE topic_id IN ($ids) $where ORDER BY FIELD(topic_id, $ids)&#38;quot;;
$topics = $bbdb-&#38;gt;get_results($topics);
$view_count  = count($topics);
$topics = bb_append_meta( $topics, &#38;#39;topic&#38;#39; );
	break;
default :
	do_action( &#38;#39;bb_custom_view&#38;#39;, $view );
endswitch;
}
add_action( &#38;#39;bb_custom_view&#38;#39;, &#38;#39;most_views&#38;#39; );&#60;/code&#62;&#60;/pre&#62;</description>
</item>
<item>
<title>_ck_ on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-9216</link>
<pubDate>Sun, 22 Jul 2007 10:51:44 +0000</pubDate>
<dc:creator>_ck_</dc:creator>
<guid isPermaLink="false">9216@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;The topic metadata is returned with every set of topics returned to bbpress.&#60;/p&#62;
&#60;p&#62;In the front page (or any topic page) for example, in the loop it can be found as $topic-&#38;gt;views&#60;/p&#62;
&#60;p&#62;There is no need for an extra mysql query. It's possible to make a function that's called with $topic if you don't want to do it as simple as above.
&#60;/p&#62;</description>
</item>
<item>
<title>cweb on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-8793</link>
<pubDate>Mon, 09 Jul 2007 19:34:56 +0000</pubDate>
<dc:creator>cweb</dc:creator>
<guid isPermaLink="false">8793@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;Hrmmm, I just installed the plugin, reviewed the steps a few times to make sure I was correct.  My view count hasn't been incrementing at all, stays fixed at the Post count.  In fact, today a few View counts have actually decremented from the Post count, weird.  Seems like a simple enough plugin, did I miss some setup with the database?
&#60;/p&#62;</description>
</item>
<item>
<title>gspark on "Importing from phpBB"</title>
<link>http://bbpress.org/forums/topic/importing-from-phpbb#post-8546</link>
<pubDate>Wed, 27 Jun 2007 23:46:13 +0000</pubDate>
<dc:creator>gspark</dc:creator>
<guid isPermaLink="false">8546@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;too bad it doesn't work for phpbb3
&#60;/p&#62;</description>
</item>
<item>
<title>HowToGeek on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-8097</link>
<pubDate>Fri, 15 Jun 2007 20:20:59 +0000</pubDate>
<dc:creator>HowToGeek</dc:creator>
<guid isPermaLink="false">8097@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;fel64: I'd think that's the best way to handle it for normal usage.&#60;/p&#62;
&#60;p&#62;Personally, I moved that functionality into a memcached module... not entirely useful for regular installs.
&#60;/p&#62;</description>
</item>
<item>
<title>fel64 on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-8081</link>
<pubDate>Fri, 15 Jun 2007 10:46:23 +0000</pubDate>
<dc:creator>fel64</dc:creator>
<guid isPermaLink="false">8081@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;I suppose you could make the variable static, meaning it'll be the same every time that function is called, and then check if there's already something in it before you do the query again. Your query would then be selecting the thirty topics last posted in, of course.
&#60;/p&#62;</description>
</item>
<item>
<title>wittmania on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-8077</link>
<pubDate>Fri, 15 Jun 2007 01:38:12 +0000</pubDate>
<dc:creator>wittmania</dc:creator>
<guid isPermaLink="false">8077@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;I'm open to suggestions... since it's not part of the $topic global, but rather in the topicmeta table, that's the only way I could think to do it.&#60;/p&#62;
&#60;p&#62;It works as it is, but if you've got a better idea as to how it could work better, I'm all ears.
&#60;/p&#62;</description>
</item>
<item>
<title>HowToGeek on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7958</link>
<pubDate>Sun, 10 Jun 2007 06:06:34 +0000</pubDate>
<dc:creator>HowToGeek</dc:creator>
<guid isPermaLink="false">7958@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;One issue with this plugin is that it does a separate SQL call for every single topic on the page.... that's 30 unnecessary SQL calls per topic list view.&#60;/p&#62;
&#60;p&#62;You might want to take a look at that...
&#60;/p&#62;</description>
</item>
<item>
<title>wittmania on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7781</link>
<pubDate>Thu, 31 May 2007 22:28:06 +0000</pubDate>
<dc:creator>wittmania</dc:creator>
<guid isPermaLink="false">7781@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;OK... it is now available through &#60;a href=&#34;http://bbpress.org/plugins/topic/53&#34;&#62;the plugin browser&#60;/a&#62;!
&#60;/p&#62;</description>
</item>
<item>
<title>AphelionZ on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7758</link>
<pubDate>Thu, 31 May 2007 02:09:24 +0000</pubDate>
<dc:creator>AphelionZ</dc:creator>
<guid isPermaLink="false">7758@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;Thanks for this - I just put it on my site and it works really well. Good job!
&#60;/p&#62;</description>
</item>
<item>
<title>wittmania on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7725</link>
<pubDate>Tue, 29 May 2007 21:40:22 +0000</pubDate>
<dc:creator>wittmania</dc:creator>
<guid isPermaLink="false">7725@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;Version 1.5 is now available &#60;a href=&#34;http://blog.wittmania.com/bb-topic-views/&#34;&#62;here&#60;/a&#62;.  Some of the changes:&#60;/p&#62;
&#60;ul&#62;
&#60;li&#62;Made major modifications to the internal architecture of how the plugin works, including putting several repeated tasks into functions, based on the hacks listed above.&#60;/li&#62;
&#60;li&#62;Added separate function calls that makes it possible to show an unformatted view count, a list of most viewed topics, and a table of most viewed topics.&#60;/li&#62;
&#60;li&#62;Improved documentation to explain how to modify tables on front/forum/tags pages to use the show_view_count() function.&#60;/li&#62;
&#60;/ul&#62;
&#60;p&#62;This plugin will also be available in the plugin browser just as soon as the submission gets approved.
&#60;/p&#62;</description>
</item>
<item>
<title>WhiteSquaw on "Importing from phpBB"</title>
<link>http://bbpress.org/forums/topic/importing-from-phpbb#post-7614</link>
<pubDate>Thu, 24 May 2007 01:06:34 +0000</pubDate>
<dc:creator>WhiteSquaw</dc:creator>
<guid isPermaLink="false">7614@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;Thanks, it`s useful!
&#60;/p&#62;</description>
</item>
<item>
<title>wittmania on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7131</link>
<pubDate>Mon, 30 Apr 2007 14:30:50 +0000</pubDate>
<dc:creator>wittmania</dc:creator>
<guid isPermaLink="false">7131@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;I haven't tested this yet, but it looks like the mods that fel64 and Sam have proposed here should work.  So, instead of rushing a new version of the plugin out today, I think I'll just save these changes (and some other functionality I'm working on) for the next major release.  Hopefully I can get a new version of it out in the next couple of weeks.
&#60;/p&#62;</description>
</item>
<item>
<title>sambauers on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7126</link>
<pubDate>Mon, 30 Apr 2007 04:45:27 +0000</pubDate>
<dc:creator>sambauers</dc:creator>
<guid isPermaLink="false">7126@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;Change:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;function get_view_count( $topic_id )
{
	$view_count = $bbdb-&#38;gt;get_var(&#38;quot;SELECT meta_value FROM $bbdb-&#38;gt;topicmeta WHERE topic_id = $topic_id AND meta_key=&#38;#39;views&#38;#39;&#38;quot;);&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;To:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;function get_view_count( $topic_id )
{
	global $bbdb, $topic;

	$view_count = $bbdb-&#38;gt;get_var(&#38;quot;SELECT meta_value FROM $bbdb-&#38;gt;topicmeta WHERE topic_id = $topic_id AND meta_key=&#38;#39;views&#38;#39;&#38;quot;);&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;????
&#60;/p&#62;</description>
</item>
<item>
<title>smurfdude on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7121</link>
<pubDate>Mon, 30 Apr 2007 02:02:06 +0000</pubDate>
<dc:creator>smurfdude</dc:creator>
<guid isPermaLink="false">7121@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;fel64, thanks for changing it for me. However i get an error when i replace the function with yours, then add &#38;lt;?php $view_count = get_view_count(); echo $view_count; ?&#38;gt;&#60;/p&#62;
&#60;p&#62;The error is: &#60;/p&#62;
&#60;p&#62;Fatal error: Call to a member function on a non-object in bb-topic-views.php&#60;/p&#62;
&#60;p&#62;Actually, adding &#38;lt;?php display_view_cont(); ?&#38;gt; was the very first thing i tried adding earlier. But it didn't do anything. I have no idea how to write php but am always trying to edit files and see what i can achieve by myself. But in most cases end up getting no where.
&#60;/p&#62;</description>
</item>
<item>
<title>fel64 on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7120</link>
<pubDate>Sun, 29 Apr 2007 21:02:23 +0000</pubDate>
<dc:creator>fel64</dc:creator>
<guid isPermaLink="false">7120@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;All I did was split &#60;code&#62;display_view_count()&#60;/code&#62; into two functions, &#60;code&#62;display_view_count()&#60;/code&#62; and &#60;code&#62;get_view_count()&#60;/code&#62;. If for example you wanted the views in a seperate column, you'd add the column HTML and then add&#60;br /&#62;
&#60;code&#62;&#38;lt;?php $view_count = get_view_count(); echo $view_count; ?&#38;gt;&#60;/code&#62;&#60;/p&#62;
&#60;p&#62;This is what I replaced &#60;code&#62;display_view_count( $title )&#60;/code&#62; with, here for Smurf's convenience. You're about to get mail.&#60;/p&#62;
&#60;p&#62;Oh, before I forget - hopefully now that plugins need activation in 1.0-alpha, there's also an activation hook or the like. That would let you do a lot of preparation first, making the code much easier. :)&#60;/p&#62;
&#60;p&#62;Edit: there is! &#60;a href=&#34;http://bbpulp.org/w/index.php?title=API/actions/bb_activate_plugin_XXX&#34;&#62;bb_activate_plugin_XXX&#60;/a&#62;. Maybe you can use that - if you want to and figure it out, tell us/make an entry on the wiki. :)&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;function display_view_count ($title)
{
	global $bbdb, $topic;
	$topic_id = $topic-&#38;gt;topic_id;

	$view_count = get_view_count( $topic_id );

	//Builds the text to be appended to the title
	$count_display = &#38;quot; &#38;lt;em&#38;gt;($view_count views)&#38;lt;/em&#38;gt;&#38;quot;; //This sets the view count var to the existing number of views, if greater than 0
	//Makes this plugin play nice with the Page Links plugin by putting the pages (if they exist) on a new line
	if (function_exists(&#38;#39;page_links_add_links&#38;#39;)) {
		$count_display .= &#38;quot;\n&#38;quot;;
	}
	$title .= $count_display;

	return $title;
}

function get_view_count( $topic_id )
{
	$view_count = $bbdb-&#38;gt;get_var(&#38;quot;SELECT meta_value FROM $bbdb-&#38;gt;topicmeta WHERE topic_id = $topic_id AND meta_key=&#38;#39;views&#38;#39;&#38;quot;);

	if ( $view_count &#38;lt;= 0 ) {
		//If the view count hasn&#38;#39;t been initialized...
		if ($topic-&#38;gt;topic_posts &#38;gt;= 1) {
			/* Sets the new record to the number of posts that have been made in a topic */
			$view_count = $topic-&#38;gt;topic_posts; //sets the view_count number
		} else {
			$view_count = 0; //can&#38;#39;t think of a time when this would be necessary (phantom topics???)
		}

		//Adds the record to the DB so it isn&#38;#39;t zero any longer
		$bbdb-&#38;gt;query(&#38;quot;INSERT INTO $bbdb-&#38;gt;topicmeta ( meta_id, topic_id, meta_key, meta_value) VALUES ( NULL , $topic_id, &#38;#39;views&#38;#39;, $view_count )&#38;quot;);
	}

	return $view_count;
}&#60;/code&#62;&#60;/pre&#62;</description>
</item>
<item>
<title>wittmania on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7117</link>
<pubDate>Sun, 29 Apr 2007 19:36:19 +0000</pubDate>
<dc:creator>wittmania</dc:creator>
<guid isPermaLink="false">7117@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;@fel, Hack away... I'd be interested in seeing the code so I could incorporate it in the next version of the plugin.  If you're willing, please e-mail it to me at mike at wittmania dot com.&#60;/p&#62;
&#60;p&#62;Thanks!
&#60;/p&#62;</description>
</item>
<item>
<title>fel64 on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7116</link>
<pubDate>Sun, 29 Apr 2007 19:18:12 +0000</pubDate>
<dc:creator>fel64</dc:creator>
<guid isPermaLink="false">7116@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;Wittmania, it's a really easy hack - in fact, if you simply take the code that gets the pageviews and seperate it into a different function, you could call that both from the current function you have to automatically append it and use it as a template tag. If you don't fancy doing it, is it alright if I quickly hack it for Smurf?
&#60;/p&#62;</description>
</item>
<item>
<title>wittmania on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7113</link>
<pubDate>Sun, 29 Apr 2007 18:43:15 +0000</pubDate>
<dc:creator>wittmania</dc:creator>
<guid isPermaLink="false">7113@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;@Sam, I use your excellent Page Links plugin, and I wrote mine specifically to be compatible with yours.  In fact, I wouldn't have known what filter to use if it weren't for your plugin.&#60;/p&#62;
&#60;p&#62;I set the priority of my filter as &#60;code&#62;99&#60;/code&#62; (yours is set to &#60;code&#62;100&#60;/code&#62;), so it fires directly before yours.  Also, my plugin checks to see if the &#60;code&#62;page_links_add_links&#60;/code&#62; function exists, and if it does it automatically drops the page links to a new line below the title in order to make things a little more sightly.&#60;/p&#62;
&#60;p&#62;@smurfdude, I thought about that, too.  I initially decided against that route so I could have it function without having to edit any template files.  The way it works right now is that it is inserted with a filter that is triggered when (and where) the topic title is fed to the page.  If you're feeling really ambitious, you can go into &#60;code&#62;bb-topic-views.php&#60;/code&#62; to see how the mechanics of the plugin work.  From there, you could change some things around so you could put the views count in its own column.  Eventually I may add that functionality within the plugin, but that's not a high priority right now.&#60;/p&#62;
&#60;p&#62;Speaking of priorities, the next to-do on my list is to add functionality where a user can add a template tag that will display the top 5 (or 10, or whatever) most viewed posts, either as &#60;code&#62;&#38;lt;li&#38;gt;&#60;/code&#62; items so you can use it anywhere, or in a format similar to the way the Latest Discussion area is laid out.  Stay tuned...
&#60;/p&#62;</description>
</item>
<item>
<title>smurfdude on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7110</link>
<pubDate>Sun, 29 Apr 2007 15:58:28 +0000</pubDate>
<dc:creator>smurfdude</dc:creator>
<guid isPermaLink="false">7110@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;Is there a way to stop it showing next to the topic title and place it wherever I want? I was thinking of making an extra column to add views in to, instead of having them appear in the title link.
&#60;/p&#62;</description>
</item>
<item>
<title>sambauers on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7107</link>
<pubDate>Sun, 29 Apr 2007 12:01:40 +0000</pubDate>
<dc:creator>sambauers</dc:creator>
<guid isPermaLink="false">7107@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;You might want to check and make sure it is compatible (i.e. works along side with my plugin &#60;a href=&#34;http://bbpress.org/plugins/topic/43&#34;&#62;Page links for bbPress&#60;/a&#62;. Although it is probably fine, I think we using the same hook to write data to the screen and it would be terrible if we were stepping on each others toes.
&#60;/p&#62;</description>
</item>
<item>
<title>wittmania on "Plugin: bb-Topic-Views"</title>
<link>http://bbpress.org/forums/topic/plugin-bb-topic-views#post-7097</link>
<pubDate>Sun, 29 Apr 2007 04:13:10 +0000</pubDate>
<dc:creator>wittmania</dc:creator>
<guid isPermaLink="false">7097@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;bb-Topic-Views keeps track of how many times each topic has been viewed, and then displays the count alongside the title of the topic on the front page, on forums pages, and on tags pages.&#60;/p&#62;
&#60;p&#62;The plugin is written in such a way that it does not double-count views when a visitor browses to a different page in the same topic.  If no view count record exists for a specific topic, the plugin will create a record for it.  Rather than setting the initial view count to zero, the plugin sets it to the number of posts in the topic, because it has obviously been viewed at least as many times as people have posted in it!  This is especially nice for adding the plugin to existing bbpress forums so the view count isn't zero for every single topic.&#60;/p&#62;
&#60;p&#62;You can download it here: &#60;a href=&#34;http://blog.wittmania.com/bb-topic-views&#34; rel=&#34;nofollow&#34;&#62;http://blog.wittmania.com/bb-topic-views&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;You can see it in action here: &#60;a href=&#34;http://blog.wittmania.com/bbpress&#34; rel=&#34;nofollow&#34;&#62;http://blog.wittmania.com/bbpress&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;---&#60;br /&#62;
By the way, I've only tested this plugin in browser environments where cookies were enabled.  This plugin doesn't set any cookies (directly, anyway), but it does use session variables which are usually passed as cookies.  So, if anyone runs into any bugs, please let me know!&#60;/p&#62;
&#60;p&#62;I'm also very open to suggestions as to how I could streamline or improve the code.  Thanks!
&#60;/p&#62;</description>
</item>
<item>
<title>lingmiester on "Importing from phpBB"</title>
<link>http://bbpress.org/forums/topic/importing-from-phpbb#post-4233</link>
<pubDate>Fri, 09 Feb 2007 05:13:13 +0000</pubDate>
<dc:creator>lingmiester</dc:creator>
<guid isPermaLink="false">4233@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;Hey all,&#60;/p&#62;
&#60;p&#62;I'm not sure, but this script does not work and seems to send all your emails to spammers.  Careful.  Use Bruno's instead.
&#60;/p&#62;</description>
</item>
<item>
<title>jaim3 on "Importing from phpBB"</title>
<link>http://bbpress.org/forums/topic/importing-from-phpbb#post-2127</link>
<pubDate>Fri, 08 Dec 2006 22:29:03 +0000</pubDate>
<dc:creator>jaim3</dc:creator>
<guid isPermaLink="false">2127@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;Hi, &#60;/p&#62;
&#60;p&#62;I enhaced the excellent Bruno Torres' script and made it able to import bbCode, as well as to cleanly import topics marked as &#60;em&#62;closed&#60;/em&#62;, &#60;em&#62;sticky&#60;/em&#62; and &#60;em&#62;announcements&#60;/em&#62;, as well as some other improvements and bugfixing.&#60;/p&#62;
&#60;p&#62;Have a look at this: &#60;a href=&#34;http://bbpress.org/forums/topic/402&#34;&#62;http://bbpress.org/forums/topic/402&#60;/a&#62;
&#60;/p&#62;</description>
</item>
<item>
<title>erikgloom on "Importing from phpBB"</title>
<link>http://bbpress.org/forums/topic/importing-from-phpbb#post-1369</link>
<pubDate>Mon, 13 Nov 2006 18:27:40 +0000</pubDate>
<dc:creator>erikgloom</dc:creator>
<guid isPermaLink="false">1369@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;Interesting.  Shouldn't be too difficult to convert &#38;#38; import from any forum to another.
&#60;/p&#62;</description>
</item>

</channel>
</rss>
