Tech ? for Pax Vitae

Color Me Curious, but what is being used to pull up “Recent Threads” (of this forum) on ILovePhilosophy.com’s main page – far right TD? Is it a java applet/script or a .cgi script? Would like to do something similar on my Existentialism site.

Thank You!
Katharena

Have a look around phpbb.com , which is the author of this particular forum software. It’s all php, as far as I can see.

Hi Obw:
I’m wondering about ILP’s doorway-page. The page seems to be a separate entity from the phpbb forum software — but, it could be a phpbb hack that streams the info, of some sort – that would cool, but I was hoping it was using a perl or java script that could be easily incorporated into an html page. I’ll pull the source and have a closer look, next week.

Thank You!
Katharena

its all in a database. mysql puts the information for you to use at your pleasure with whatever type of script you want to access it. its all usin php here.

It’s just a MySQL php call that returns the information about what are the newest posts (i.e. most recently created) then finds the forum and topic title. It’s a couple lines of SQL. Just make sure you don’t list the same topic twice and that’s all the code does.

<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr><td class="Heading">Recent Threads</td></tr>
<tr><td align="left" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0" background="images/line.gif">
			<?php 
			if (GetDBAvailablity($db)) {
				
				$strQuery = 'select phpbb_forums.forum_name,  phpbb_posts.post_id, phpbb_posts.topic_id
							from phpbb_posts
							join phpbb_forums where phpbb_forums.forum_id = phpbb_posts.forum_id and
							phpbb_forums.auth_read = 0
							order by phpbb_posts.post_time desc
							limit 0, 21;';
							 
				$result = mysql_query($strQuery, $db);
				$intNumTopic = 8;
				$intCurTopic = 0;
				$bolFound=false;
				$intLastBlank=0;
				$AryStrLPgrp = array(0 => "");
				while(($myrow = mysql_fetch_row($result)) & ($intCurTopic < $intNumTopic))
				{
					$bolFound=false;
					
					/*Find the Topic info*/
					
					/* Check to see if topic in list */
					for($intI=0; $intI<$intNumTopic; $intI++) {
						if ($AryStrLPgrp[$intI] == $myrow[2]) {
							$bolFound=true;
						}
					}
					/* Only Display Topic once */
					if ($bolFound == false) {
						$AryStrLPgrp[$intLastBlank++] = $myrow[2];
						//Find Topic Title
						$strQuery = 'select phpbb_topics.topic_title from phpbb_topics
									where phpbb_topics.topic_id = ' . $myrow[2] . ' ;';
						$resultTopic = mysql_query($strQuery, $db);
						if ($myrowTopic = mysql_fetch_row($resultTopic))
						{
				?>
<tr><td valign="top" width="9"><img src="images/dotsm.gif" width="7" height="9"></td>
<td valign="top"><span class="RecentForum">
				<?
							printf("%s:", $myrow[0]);
				?></span><br><?php
							echo "<a target=\"_blank\" class=\"ForumLink\" href=";
							printf('"phpbb/viewtopic.php?p=%d#%d">%s', $myrow[1], $myrow[1], $myrowTopic[0]);
				?></a></a></td></tr>				<?php
							$intCurTopic++;
						}
					} // If ($bolFound == false)
				}
			}
			?>
</table></td></tr></table>

:sunglasses: Thanks DietCoke and Pax Vitae!

I’m looking forward to implementing the code on my site – perhaps during the 4th quarter. One of my sponsors has been “acquired” by another and that may free up a bit of space. I might try and pull it through a small pop-up.

Color Me Happy!
Katharena