miniBB ® miniBB®
miniBB Support Forums
 | Forums | Register | Reply | Search | Statistics | Manual |
Re-cycled miniBB Support Forums / Re-cycled /   

Advanced Recent Topics (more to follow on another extra page)

Page  Page 2 of 3:  « Previous  1  2  3  Next »  
Author Vishal
Registered
#16 | Posted: 12 Sep 2007 00:54 
I would still advise you to leave it as it was originally done (NOINDEX, NOFOLLOW). There's no need to index duplicate pages, I think.

They cannot be called duplicate pages. Duplicate pages are ones where the urls are different but the content is same. The last 100 discussions or so page is a good resource for search engines to index latest/recently updated content.

Author Vishal
Registered
#17 | Posted: 12 Sep 2007 01:33 
Try to put this in bb_plugins.php:

$metaRobots='INDEX,FOLLOW';

straight after

if ($viewlastdiscussions!=0 and $action=='advld') {

in the above code.


Excellent! I also added the following to further customize the page:

$title.='Last 100 Discussions';
$description='Last 100 discussions on the Work at Home Forum.';

Author tom322
Registered
#18 | Posted: 12 Sep 2007 13:38 
They cannot be called duplicate pages. Duplicate pages are ones where the urls are different but the content is same. The last 100 discussions or so page is a good resource for search engines to index latest/recently updated content.

But from what I can tell you have some of the exactly the same messages (eg. links to the latest forum threads) also on the index page... They perhaps won't be classified as "duplicate pages" but they may diminish the value/strength/importance of the index page.. It's my opinion at least..

Author Paul
Lead Developer
#19 | Posted: 19 Mar 2009 06:03 | Edited by: Paul 
This topic actually mentions just one extra page filled with Recent Topics in advanced mode.

However many of you would be interested in a case, when Recent Topics are listed one-by-one on extra pages, i.e. they would be paginated results listing certain amount of pages.

Here is the solution. First of all, insert into bb_plugins.php the code provided below:

/* Advanced latest discussions */

if ($action=='advld') {
$title.=$l_lastDiscussions;

$numRows=$viewlastdiscussions*10;
//$pageNavEx=pageNav($page, $numRows, "{$main_url}/{$indexphp}action=advld&page=", $viewlastdiscussions, FALSE, FALSE);
$pageNavEx=pageNav($page, $numRows, "{$main_url}/{$indexphp}action=advld", $viewlastdiscussions, FALSE, 'Gen');

$startLim=($page-PAGE1_OFFSET-1)*$viewlastdiscussions;
//$startLim=$viewlastdiscussions*$page+$viewlastdiscussions;
$endLim=$viewlastdiscussions;

$viewlastdiscussions="{$startLim}, {$endLim}";

if($row=db_simpleSelect(0,$Tf,'forum_id, forum_icon, forum_name')){
do{
$fIcon[$row[0]]=$row[1];
$fTitle[$row[0]]=$row[2];
}
while($row=db_simpleSelect(1));
}

$action='';
require($pathToFiles.'bb_func_ldisc.php');
$listTopics=$list_topics;
echo load_header();
if($list_topics!='') echo ParseTpl(makeUp('main_last_discussions_more'));
$action='advld';
}

/* --Advanced latest discussions */

Pay attention to $numRowsLD variable, it multiplies $viewlastdiscussions with 10, where 10 stands for the amount of pages you would like to display in the extra Recent Discussions section. It depends how many topics your forum contain actually, and what is the value of $viewlastdiscussions. There is no sense to install this add-on, if your forum has less than 10 x $viewlastdiscussions topics.

Then pay attention there should be another template for that stuff, under templates/main_last_discussions_more.html. This template is basically a copy of main_last_discussions.html, you only need to remove parts of HTML code providing Sorting by topics and replies. Because in that section, all topics will be listed by latest replies by default (in the current solution). Here is the example code for this template:

<table class="tbTransparent" style="margin-top:12pt">
<tr>
<td class="tbTransparent txtL" style="width:50%"><h1 class="headingTitle">{$l_lastDiscussions}</h1></td>
<td class="tbTransparent txtR" style="width:50%;vertical-align:middle"><strong>{$pageNavEx}</strong></td>
</tr>
</table>

<table class="forumsmb">

<tr>
<td class="rdficon" style="width:25px"><img src="{$main_url}/img/p.gif" style="width:25px;height:1px" alt="" /></td>
<td class="captionTop">{$l_topic}</td>
<td class="captionTop" style="text-align:center">{$l_replies}</td>
<td class="captionTop" style="text-align:center">{$l_views}</td>
<td class="captionTop" style="text-align:center">{$l_author}</td>
<td class="captionTop" style="text-align:center;white-space:nowrap;">{$l_lastAuthor}</td>
</tr>

{$listTopics}

<tr>
<td style="width:25px;"><img src="{$main_url}/img/p.gif" style="width:25px;height:1px" alt="" /></td>
<td style="width:70%"><img src="{$main_url}/img/p.gif" style="width:1px;height:1px" alt="" /></td>
<td style="width:40px;"><img src="{$main_url}/img/p.gif" style="width:1px;height:1px" alt="" /></td>
<td style="width:40px;"><img src="{$main_url}/img/p.gif" style="width:1px;height:1px" alt="" /></td>
<td style="width:15%;"><img src="{$main_url}/img/p.gif" style="width:1px;height:1px" alt="" /></td>
<td style="width:15%;"><img src="{$main_url}/img/p.gif" style="width:1px;height:1px" alt="" /></td>
</tr>

</table>

When you have done all the aforementioned, under "Recent Topics" title on the front forums page you will just need to put the link to the extra section. For example, it could be the following:

<!--advanced--><a href="{$main_url}/{$indexphp}action=advld">more...</a><!--/advanced-->

Good luck :-)

Author jontrac
Registered
#20 | Posted: 30 Oct 2009 04:57 
Great mod. I'm using it right now. Thanks Paul!

Author Danny2000
Registered
#21 | Posted: 3 Dec 2009 04:15 
in default latest discussions the thumbnail (file upload) appears.. but in this one /* --Advanced latest discussions */ I set as link in menu bar it doesn't appear.. is there any solution for it?

Author Paul
Lead Developer
#22 | Posted: 3 Dec 2009 05:33 | Edited by: Paul 
Add $action=='advld' to File Upload Hack's code, in these places:

if($action=='vtopic' or $action=='' or $action=='advld') {
...

[parseTopic part]
if($GLOBALS['action']=='vtopic' or $GLOBALS['action']=='' or $GLOBALS['action']=='advld') {

Actually I've put this code in the official add-on's package today.

Author Prince
Registered
#23 | Posted: 24 Aug 2011 00:17 
Paul:
if ($action=='advld') {

Can we use Mod_rewrite for this also? short link?

Instead of: domain.com/index.php?action=advld

We could put like:

domain.com/advld.html or domain.com/new.html

Author tom322
Registered
#24 | Posted: 24 Aug 2011 03:20 
I'm sure Paul has more important things to do, so here you may try this ; )

---------

In .htaccess file enter this:

RewriteRule ^new.html ./index.php?action=advld

Then domain.com/new.html should be working.

Author Prince
Registered
#25 | Posted: 24 Aug 2011 13:47 
tom322:
Then domain.com/new.html should be working.

Thanks.. working :)

Author Guest
#26 | Posted: 24 Jan 2012 00:56 
Paul:
Advanced latest discussions

It doesn't work with new version.. how can fix that?

Author tom322
Registered
#27 | Posted: 24 Jan 2012 06:58 
Guest:
how can fix that?

Remove it, you don't need it any more ;)

Author Paul
Lead Developer
#28 | Posted: 24 Jan 2012 11:25 | Edited by: Paul 
The new version (i.e. miniBB 3.x) includes this function by default.

Author Guest
#29 | Posted: 24 Jan 2012 16:18 
tom322:
Remove it, you don't need it any more ;)

Paul:
The new version (i.e. miniBB 3.x) includes this function by default.

But I don't want latest discussion appears on first page.. :) which link should it be for showing it in new page.. a link in menu bar for it?

Author Paul
Lead Developer
#30 | Posted: 24 Jan 2012 17:07 | Edited by: Paul 
Guest:
But I don't want latest discussion appears on first page.. :) which link should it be for showing it in new page.. a link in menu bar for it?

That's another story. And it's not quite lucky. In the current version, it's just impossible to have $viewlastdiscussions=0; (i.e. Recent Topics disabled) and the pagination to the next topics. Because this pagination is build on the $viewlastdiscussions setting, it provides amount of topics per page (i.e. you go from the first page to the 2nd, and there is the same amount of topics as on the 1st page, and so on). If the setting is disabled, what to take into attention as amount of topics per page? Obviously, there would be required a standalone setting for that...

Also, I think, I was too much concentrated on the primary layout and missed this thing out: obviously, if you have $startPageModern=FALSE; (i.e. the forums listed on top on the 1st page), you can't get it easily to put a navigation below the topics list. But it may be present there as well. I hope to work out it in the next update. Few core files need to be fixed for that. Thanks for discovering!

Then you need to remind me once again about your problem. There will be a little non-destructive code update available for it. I'll publish it here, if I won't forget ;)

Page  Page 2 of 3:  « Previous  1  2  3  Next » 
Re-cycled miniBB Support Forums / Re-cycled / Advanced Recent Topics (more to follow on another extra page) Top

Your Reply Click this icon to move up to the quoted message

 Short link for this topic:

 ?
Only registered users are allowed to post here. Please, enter your username/password details upon posting a message, or register first.


Before posting, make sure your message is compliant with our forum posting rules. If not, it may be locked or deleted with no explanation.
 
 
miniBB Support Forums Powered by Forum Software miniBB ® Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contacts
Install the Captcha add-on: protect your miniBB-forums from the automated spam and flood.
Captcha Addon for miniBB