<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[PunBB Forums — how about add button next or previous topic ?]]></title>
		<link>https://punbb.informer.com/forums/topic/30042/how-about-add-button-next-or-previous-topic/</link>
		<atom:link href="https://punbb.informer.com/forums/feed/rss/topic/30042/" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in how about add button next or previous topic ?.]]></description>
		<lastBuildDate>Wed, 28 Sep 2016 03:22:52 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: how about add button next or previous topic ?]]></title>
			<link>https://punbb.informer.com/forums/post/156402/#p156402</link>
			<description><![CDATA[<p><a href="http://punbb.ru/topic6223-reliz-linker.html">http://punbb.ru/topic6223-reliz-linker.html</a></p>]]></description>
			<author><![CDATA[null@example.com (PanBB.Ru)]]></author>
			<pubDate>Wed, 28 Sep 2016 03:22:52 +0000</pubDate>
			<guid>https://punbb.informer.com/forums/post/156402/#p156402</guid>
		</item>
		<item>
			<title><![CDATA[Re: how about add button next or previous topic ?]]></title>
			<link>https://punbb.informer.com/forums/post/156401/#p156401</link>
			<description><![CDATA[<div class="quotebox"><cite>PanBB.Ru wrote:</cite><blockquote><p>Разберешься?</p><div class="codebox"><pre><code>    $bquery = array(
        &#039;SELECT&#039;    =&gt; &#039;MIN(bt.id), bt.subject&#039;,
        &#039;FROM&#039;        =&gt; &#039;topics AS bt&#039;,
        &#039;WHERE&#039;        =&gt; &#039;bt.id&gt;&#039;.$id,
    );
    $bresult = $forum_db-&gt;query_build($bquery) or error(__FILE__, __LINE__);
    $back = $forum_db-&gt;fetch_assoc($bresult);
    
    if(isset($back[&#039;MIN(bt.id)&#039;]))
        $tback = &#039;&lt;a href=&quot;&#039;.forum_link($forum_url[&#039;topic&#039;], array($back[&#039;MIN(bt.id)&#039;], sef_friendly($back[&#039;subject&#039;]))).&#039;&quot;&gt;&#039;.$back[&#039;subject&#039;].&#039;&lt;/a&gt;&#039;;
    
    $nquery = array(
        &#039;SELECT&#039;    =&gt; &#039;MAX(nt.id), nt.subject&#039;,
        &#039;FROM&#039;        =&gt; &#039;topics AS nt&#039;,
        &#039;WHERE&#039;        =&gt; &#039;nt.id&lt;&#039;.$id,
    );
    $nresult = $forum_db-&gt;query_build($nquery) or error(__FILE__, __LINE__);
    $next = $forum_db-&gt;fetch_assoc($nresult);
    
    if(isset($next[&#039;MAX(nt.id)&#039;]))
        $tnext = &#039;&lt;a href=&quot;&#039;.forum_link($forum_url[&#039;topic&#039;], array($next[&#039;MAX(nt.id)&#039;], sef_friendly($next[&#039;subject&#039;]))).&#039;&quot;&gt;&#039;.$next[&#039;subject&#039;].&#039;&lt;/a&gt;&#039;;
        
    echo $tback;
    echo $tnext;</code></pre></div><p>will you understand?</p><p>Or second embodiment:</p><div class="codebox"><pre><code>    $query = array(
        &#039;SELECT&#039;    =&gt; &#039;t.id, t.subject&#039;,
        &#039;FROM&#039;        =&gt; &#039;topics AS t&#039;,
        &#039;WHERE&#039;        =&gt; &#039;t.forum_id=&#039;.$cur_topic[&#039;forum_id&#039;]
    );
    $result = $forum_db-&gt;query_build($query) or error(__FILE__, __LINE__);
    
    $back = array();
    $next = array();
    while($topics = $forum_db-&gt;fetch_assoc($result))
    {
        if($topics[&#039;id&#039;] &lt; $id)
            $back[$topics[&#039;id&#039;]] = $topics[&#039;subject&#039;];
        else if ($topics[&#039;id&#039;] &gt; $id)
            $next[$topics[&#039;id&#039;]] = $topics[&#039;subject&#039;];
    }
    
    $back_id = max(array_keys($back));
    $back_subject = $back[$back_id];
    
    $next_id = min(array_keys($next));
    $next_subject = $next[$next_id];
    
    $tback = !empty($back_id) ? &#039;&lt;a href=&quot;&#039;.forum_link($forum_url[&#039;topic&#039;], array($back_id, sef_friendly($back_subject))).&#039;&quot; title=&quot;Old topic&quot;&gt;&#039;.$back_subject.&#039;&amp;nbsp;&amp;#9668;&amp;#9668;&amp;nbsp;&lt;/a&gt;&#039; : &#039;&#039;;
    
    $tnext = !empty($next_id) ? &#039;&lt;a href=&quot;&#039;.forum_link($forum_url[&#039;topic&#039;], array($next_id, sef_friendly($next_subject))).&#039;&quot; title=&quot;Next topic&quot;&gt;&amp;nbsp;&amp;#9658;&amp;#9658;&amp;nbsp;&#039;.$next_subject.&#039;&lt;/a&gt;&#039; : &#039;&#039;;
    </code></pre></div></blockquote></div><p>I have tried it but i messed up at then end. Is there any alternate route to do so.....!<br /><a href="http://www.Infantigo.xyz/"><span style="color: #FFFFFF">Infantigo</span></a></p>]]></description>
			<author><![CDATA[null@example.com (kerlinrao)]]></author>
			<pubDate>Wed, 28 Sep 2016 00:09:56 +0000</pubDate>
			<guid>https://punbb.informer.com/forums/post/156401/#p156401</guid>
		</item>
		<item>
			<title><![CDATA[Re: how about add button next or previous topic ?]]></title>
			<link>https://punbb.informer.com/forums/post/156283/#p156283</link>
			<description><![CDATA[<p>well, well... then it is better use the extension. see above.</p>]]></description>
			<author><![CDATA[null@example.com (PanBB.Ru)]]></author>
			<pubDate>Sun, 21 Aug 2016 19:09:42 +0000</pubDate>
			<guid>https://punbb.informer.com/forums/post/156283/#p156283</guid>
		</item>
		<item>
			<title><![CDATA[Re: how about add button next or previous topic ?]]></title>
			<link>https://punbb.informer.com/forums/post/156281/#p156281</link>
			<description><![CDATA[<div class="quotebox"><cite>PanBB.Ru wrote:</cite><blockquote><p>Разберешься?</p><p>will you understand?</p><p>Or second embodiment:</p></blockquote></div><p>No.. where i must place this?</p>]]></description>
			<author><![CDATA[null@example.com (kudataz)]]></author>
			<pubDate>Sun, 21 Aug 2016 18:01:13 +0000</pubDate>
			<guid>https://punbb.informer.com/forums/post/156281/#p156281</guid>
		</item>
		<item>
			<title><![CDATA[Re: how about add button next or previous topic ?]]></title>
			<link>https://punbb.informer.com/forums/post/156267/#p156267</link>
			<description><![CDATA[<p>Разберешься?</p><div class="codebox"><pre><code>    $bquery = array(
        &#039;SELECT&#039;    =&gt; &#039;MIN(bt.id), bt.subject&#039;,
        &#039;FROM&#039;        =&gt; &#039;topics AS bt&#039;,
        &#039;WHERE&#039;        =&gt; &#039;bt.id&gt;&#039;.$id,
    );
    $bresult = $forum_db-&gt;query_build($bquery) or error(__FILE__, __LINE__);
    $back = $forum_db-&gt;fetch_assoc($bresult);
    
    if(isset($back[&#039;MIN(bt.id)&#039;]))
        $tback = &#039;&lt;a href=&quot;&#039;.forum_link($forum_url[&#039;topic&#039;], array($back[&#039;MIN(bt.id)&#039;], sef_friendly($back[&#039;subject&#039;]))).&#039;&quot;&gt;&#039;.$back[&#039;subject&#039;].&#039;&lt;/a&gt;&#039;;
    
    $nquery = array(
        &#039;SELECT&#039;    =&gt; &#039;MAX(nt.id), nt.subject&#039;,
        &#039;FROM&#039;        =&gt; &#039;topics AS nt&#039;,
        &#039;WHERE&#039;        =&gt; &#039;nt.id&lt;&#039;.$id,
    );
    $nresult = $forum_db-&gt;query_build($nquery) or error(__FILE__, __LINE__);
    $next = $forum_db-&gt;fetch_assoc($nresult);
    
    if(isset($next[&#039;MAX(nt.id)&#039;]))
        $tnext = &#039;&lt;a href=&quot;&#039;.forum_link($forum_url[&#039;topic&#039;], array($next[&#039;MAX(nt.id)&#039;], sef_friendly($next[&#039;subject&#039;]))).&#039;&quot;&gt;&#039;.$next[&#039;subject&#039;].&#039;&lt;/a&gt;&#039;;
        
    echo $tback;
    echo $tnext;</code></pre></div><p>will you understand?</p><p>Or second embodiment:</p><div class="codebox"><pre><code>    $query = array(
        &#039;SELECT&#039;    =&gt; &#039;t.id, t.subject&#039;,
        &#039;FROM&#039;        =&gt; &#039;topics AS t&#039;,
        &#039;WHERE&#039;        =&gt; &#039;t.forum_id=&#039;.$cur_topic[&#039;forum_id&#039;]
    );
    $result = $forum_db-&gt;query_build($query) or error(__FILE__, __LINE__);
    
    $back = array();
    $next = array();
    while($topics = $forum_db-&gt;fetch_assoc($result))
    {
        if($topics[&#039;id&#039;] &lt; $id)
            $back[$topics[&#039;id&#039;]] = $topics[&#039;subject&#039;];
        else if ($topics[&#039;id&#039;] &gt; $id)
            $next[$topics[&#039;id&#039;]] = $topics[&#039;subject&#039;];
    }
    
    $back_id = max(array_keys($back));
    $back_subject = $back[$back_id];
    
    $next_id = min(array_keys($next));
    $next_subject = $next[$next_id];
    
    $tback = !empty($back_id) ? &#039;&lt;a href=&quot;&#039;.forum_link($forum_url[&#039;topic&#039;], array($back_id, sef_friendly($back_subject))).&#039;&quot; title=&quot;Old topic&quot;&gt;&#039;.$back_subject.&#039;&amp;nbsp;&amp;#9668;&amp;#9668;&amp;nbsp;&lt;/a&gt;&#039; : &#039;&#039;;
    
    $tnext = !empty($next_id) ? &#039;&lt;a href=&quot;&#039;.forum_link($forum_url[&#039;topic&#039;], array($next_id, sef_friendly($next_subject))).&#039;&quot; title=&quot;Next topic&quot;&gt;&amp;nbsp;&amp;#9658;&amp;#9658;&amp;nbsp;&#039;.$next_subject.&#039;&lt;/a&gt;&#039; : &#039;&#039;;
    </code></pre></div>]]></description>
			<author><![CDATA[null@example.com (PanBB.Ru)]]></author>
			<pubDate>Thu, 11 Aug 2016 11:27:15 +0000</pubDate>
			<guid>https://punbb.informer.com/forums/post/156267/#p156267</guid>
		</item>
		<item>
			<title><![CDATA[Re: how about add button next or previous topic ?]]></title>
			<link>https://punbb.informer.com/forums/post/156266/#p156266</link>
			<description><![CDATA[<p>Look here: <a href="http://punbb.ru/topic6223-reliz-linker.html">link</a></p>]]></description>
			<author><![CDATA[null@example.com (sempai)]]></author>
			<pubDate>Thu, 11 Aug 2016 10:15:09 +0000</pubDate>
			<guid>https://punbb.informer.com/forums/post/156266/#p156266</guid>
		</item>
		<item>
			<title><![CDATA[how about add button next or previous topic ?]]></title>
			<link>https://punbb.informer.com/forums/post/156265/#p156265</link>
			<description><![CDATA[<p>i think this optional will make easy user read topic without back to viewforum or index to see other topics <img src="https://punbb.informer.com/forums/img/smilies/big_smile.png" width="15" height="15" alt="big_smile" /><br />hwo to create coding like this? <br /><span class="postimg"><img src="http://i.giphy.com/lKXEBR8m1jWso.gif" alt="http://i.giphy.com/lKXEBR8m1jWso.gif" /></span></p>]]></description>
			<author><![CDATA[null@example.com (kudataz)]]></author>
			<pubDate>Thu, 11 Aug 2016 08:18:48 +0000</pubDate>
			<guid>https://punbb.informer.com/forums/post/156265/#p156265</guid>
		</item>
	</channel>
</rss>
