Commit in phpslash-dev/include/modules/story on MAIN
Story.class +10 -5 1.13 -> 1.14
<pre class="comment">
Fixes bug: implements article_updatehits
</pre>
<hr /><a name="file1" /><div class="file">
<span class="pathname">phpslash-dev/include/modules/story<br /></span>
<div class="fileheader"><big><b>Story.class</b></big> <small id="info">1.13 -> 1.14</small></div>
<pre class="diff"><small id="info">diff -u -r1.13 -r1.14
--- Story.class 24 Apr 2005 14:12:46 -0000 1.13
+++ Story.class 28 Apr 2005 03:46:52 -0000 1.14
@@ -1,6 +1,6 @@
</small></pre><pre class="diff" id="context"> <?php
</pre><pre class="diff" id="removed">-/* $Id: Story.class,v 1.1<span id="removedchars">3 2005/04/24 14:12:46</span> lems1 Exp $ */
</pre><pre class="diff" id="added">+/* $Id: Story.class,v 1.1<span id="addedchars">4 2005/04/28 03:46:52</span> lems1 Exp $ */
</pre><pre class="diff" id="context">
/*
* Class: Story
</pre><pre class="diff"><small id="info">@@ -243,8 +243,8 @@
</small></pre><pre class="diff" id="context"> }
/* Returns the HTML for the Story */
</pre><pre class="diff" id="removed">- function getStory($story_id, $mode, $argv_ary="", $tpl="") {
-
</pre><pre class="diff" id="added">+ function getStory($story_id, $mode, $argv_ary="", $tpl="")
+ {
</pre><pre class="diff" id="context"> global $relatedlinks;
$default_tpl = "story.tpl";
</pre><pre class="diff"><small id="info">@@ -436,9 +436,14 @@
</small></pre><pre class="diff" id="context"> 'TITLE' => $ary["title"],
'RELATED' => $related
));
</pre><pre class="diff" id="removed">- }<span id="removedchars"> </span>
</pre><pre class="diff" id="added">+ }
+ if ( $_PSL['article_updatehits'] == "true" )
+ {
+ $sql_article_update_hits = "UPDATE psl_story set hits=hits+1 where story_id=$story_id";
+ $this->db->query($sql_article_update_hits);
+ }
</pre><pre class="diff" id="context"> return $thestory;
</pre><pre class="diff" id="removed">- }
</pre><pre class="diff" id="added">+ } /* end getStory() */
</pre><pre class="diff" id="context">
/* flexible getStories function
* pass variables inside the array
</pre></div>
http://www.badgers-in-foil.co.uk/projects/cvsspam/ - CVSspam - 0.2.10
|