Technical Details
Forum version : #ModernBBPosition : Founder
Concerned browser(s) : Mozilla Firefox, Google Chrome, Internet Explorer, Opera, Safari, Other
Who the problem concerns : All members
Forum link : http://whitneyai.forumotion.com/
This is a Hitskin.com skin preview
Install the skin • Return to the skin page
<ul class="linklist">
<!-- BEGIN switch_user_logged_in -->
<li><a href="{U_SEARCH_NEW}">{L_SEARCH_NEW}</a> • </li>
<li><a href="{U_SEARCH_SELF}">{L_SEARCH_SELF}</a> • </li>
<!-- END switch_user_logged_in -->
<li><a href="{U_SEARCH_UNANSWERED}">{L_SEARCH_UNANSWERED}</a></li>
<!-- BEGIN switch_user_logged_in -->
<li class="rightside"><a href="{U_MARK_READ}" accesskey="m">{L_MARK_FORUMS_READ}</a></li>
<!-- END switch_user_logged_in -->
</ul>
<link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<!-- BEGIN catrow -->
<!-- BEGIN tablehead -->
<div class="forabg">
<div class="inner"><span class="corners-top"><span></span></span>
<ul class="topiclist">
<li class="header">
<dl class="icon">
<dd class="dterm"><div class="table-title">{catrow.tablehead.L_FORUM}</div></dd>
</dl>
</li>
</ul>
<table id="example" class="topiclist table table-bordered" style="width: 100%;">
<thead style="display:none">
<tr>
<th><div class="table-title">{catrow.tablehead.L_FORUM}</div></th>
<th>{L_TOPICS}</th>
<th>{L_POSTS}</th>
<th><span>{L_LASTPOST}</span></th>
<th>Date</th>
</tr>
</thead>
<!-- END tablehead -->
<!-- BEGIN forumrow -->
<tbody>
<tr>
<td class="dterm" style="text-align:left;">
<div style="display: block; margin : 0 {catrow.forumrow.INC_LEVEL_RIGHT} 0 {catrow.forumrow.INC_LEVEL_LEFT};">
<h{catrow.forumrow.LEVEL} class="hierarchy">
<a href="{catrow.forumrow.U_VIEWFORUM}" class="forumtitle">{catrow.forumrow.FORUM_NAME}</a>
</h{catrow.forumrow.LEVEL}>
<br />
{catrow.forumrow.FORUM_DESC}
<!-- BEGIN switch_moderators_links -->
{catrow.forumrow.switch_moderators_links.L_MODERATOR}{catrow.forumrow.switch_moderators_links.MODERATORS}
<!-- END switch_moderators_links -->
{catrow.forumrow.L_LINKS}{catrow.forumrow.LINKS}
<strong>{forumrow.L_SUBFORUM_STR}</strong> {forumrow.SUBFORUMS}
</div>
</td>
<td class="topics">{catrow.forumrow.TOPICS} <dfn>{L_TOPICS}</dfn></td>
<td class="posts">{catrow.forumrow.POSTS} <dfn>{L_POSTS}</dfn></td>
<td class="lastpost">
<!-- BEGIN ads -->
<span class="AD_LastPA">
<span class="lastpost-avatar"><img src="{catrow.forumrow.ads.IMG}" alt="{catrow.forumrow.ads.TITLE}" /></span>
<span class="AD_LastInfos">
<b><a href="{catrow.forumrow.ads.LINK}">{catrow.forumrow.ads.TITLE}</a></b><br />
{catrow.forumrow.ads.DATE}<br />
{catrow.forumrow.ads.LOCATION}
</span>
</span>
<!-- END ads -->
<!-- BEGIN avatar -->
<span class="lastpost-avatar">{catrow.forumrow.avatar.LAST_POST_AVATAR}</span>
<!-- END avatar -->
<span>
<!-- BEGIN switch_topic_title -->
<a href="{catrow.forumrow.U_LATEST_TOPIC}" title="{catrow.forumrow.LATEST_TOPIC_TITLE}">{catrow.forumrow.LATEST_TOPIC_NAME}</a><br />
<!-- END switch_topic_title -->
{catrow.forumrow.USER_LAST_POST}
</span>
</td>
<td class="tdate" style="display:none">{catrow.forumrow.USER_LAST_POST}</td>
</tr>
</tbody>
<!-- END forumrow -->
<!-- BEGIN tablefoot -->
</table>
<span class="corners-bottom"><span></span></span></div>
</div>
<!-- END tablefoot -->
<!-- END catrow -->
<!-- BEGIN switch_on_index -->
<ul class="linklist">
<li><a href="{U_TODAY_ACTIVE}">{L_TODAY_ACTIVE}</a> • </li>
<li><a href="{U_TODAY_POSTERS}">{L_TODAY_POSTERS}</a> • </li>
<li class="last"><a href="{U_OVERALL_POSTERS}">{L_OVERALL_POSTERS}</a></li>
<!-- BEGIN switch_delete_cookies -->
<li class="rightside"><a href="{switch_on_index.switch_delete_cookies.U_DELETE_COOKIES}" rel="nofollow">{switch_on_index.switch_delete_cookies.L_DELETE_COOKIES}</a></li>
<!-- END switch_delete_cookies -->
</ul>
<!-- END switch_on_index -->
function comparer(index) {
return function(a, b) {
var valA = getCellValue(a, index), valB = getCellValue(b, index);
return $.isNumeric(valA) && $.isNumeric(valB) ? valA - valB : valA.toString().localeCompare(valB);
}
}
function getCellValue(row, index){ return $(row).children('td').eq(index).text() }
$(function()
{
$(document).ready(function() {
$('.topiclist').each(function(){
$(this).find('.lastpost').each(function(){
var curdate =$(this).nextUntil("br").clone().children().remove().end().text().trim().replace('Guest','');
if(curdate.indexOf("Today") >= 0){
var d = new Date();
var today = (d.getMonth()+1) + "/" + d.getDate() + "/" +d.getFullYear();
var datsplit = curdate.split(' ');
curdate = today + ' ' + datsplit[2] + ' ' + datsplit[3];
}
if(curdate.indexOf("Yesterday") >= 0){
let now = new Date();
var defaultDate = now - 1000 * 60 * 60 * 24 * 1;
var d = new Date(defaultDate);
var today = (d.getMonth()+1) + "/" + d.getDate() + "/" +d.getFullYear();
var datsplit = curdate.split(' ');
curdate = today + ' ' + datsplit[2] + ' ' + datsplit[3];
}
var ee = new Date(curdate).getTime();
if(isNaN(ee))ee='00000000000';
$(this).parent().find('.tdate').text(ee);
});
var table = $(this).eq(0);
var rows = table.find('tr:gt(0)').toArray().sort(comparer(4));
this.desc = !this.desc;
if (!this.desc){rows = rows.reverse();}
for (var i = 0; i < rows.length; i++){table.prepend(rows[i]);}
})
})
});