Latest topics - AwesomeBB
Page 1 of 1 • Share •
Latest topics - AwesomeBB
Latest topics - AwesomeBB
We know that the AwesomeBB version is in beta and do not have widgets yet, so I made a simple code so we have a widget - Latest topics.Author: pedxz
Working forum versions: Only AwesomeBB
Installation
The installation is unique, and can only be done by creating a new javascript. CSS can be modified, and is embedded in Javascript. Please follow the steps below to install the effect on your community.ACP > Modules > HTML and Javascript > Javascript codes management > Create a new javascript
Placement: In the home page
The code:
- Code:
/**
* Latest topics - AwesomeBB by Pedxz
* Created August 26, 2018 <1.0>
* See more: http://ajuda.forumeiros.com
*/
$(function() {
var title = 'Latest Topics', empty = 'At the moment we are without messages or you are not allowed to see them!', last = $('<div>', {
id: 'block-latest',
class: 'block-subtle'
}).append(
' <i class="material-icons">chat_bubble_outline</i>' +
' <div>' +
' <span class="headline">' + title + '</span>' +
' <div class="block-last-load"></div>' +
' </div>'
);
if (_board.tpl_version !== 'awesomebb') return;
$(last).insertBefore('#block-online');
$('#block-latest .block-last-load').load('/latest .block-topics-details');
$('head').append(
'<style type="text/css">' +
'.block-last-load:empty::before {' +
' content: "'+ empty +'";' +
'}'+
'#block-latest i {' +
' color: #BF263C;' +
'}' +
'.block-last-load {' +
' margin-left: -.37em;' +
' margin-right: -.37em;' +
' height: 300px;' +
' overflow-y: auto;' +
'}' +
'.block-last-load a {' +
' text-decoration: none;' +
' border: 0!important;' +
' display: inline;' +
'}' +
'.block-last-load .block-topics-details {' +
' padding: 1em;' +
'}' +
'.block-last-load .block-topics-details:not(:nth-child(2n+1)) {' +
' background-color: #F5F7FA;' +
'}' +
'#block-latest h2 {' +
' font-size: 16px;' +
' text-overflow: ellipsis;' +
' overflow: hidden;' +
' white-space: nowrap;' +
' width: 100%;' +
'}' +
'#block-latest .block-topics-author,' +
'#block-latest .block-topics-lastpost img {' +
' display: none;' +
'}' +
'#block-latest .block-topics-lastpost,' +
'#block-latest .block-topics-author a {' +
' display: inline;' +
'}' +
'@media only screen and (max-width: 768px) {' +
' #block-latest {' +
' margin-top: 20px;' +
' }' +
'}' +
'</style>'
);
});
Details
If the widget is appearing blank for the guests, go to ACP > Users & Groups > Special Rights and make sure the search option is authorized for the guests.
Re: Latest topics - AwesomeBB
Thank you so much for sharing @pedxz. This will be indeed very useful


![]() |
Rules of the forum - Frequently Asked Questions - Have you lost your password?
Please mark the "solved" button if your problem/doubt has been solved.
Re: Latest topics - AwesomeBB
Hi,
Thank you for this script however the list of the last subjects is fixed, is it possible to modify the script to have a scrolling of the last subjects?
Thank you for this script however the list of the last subjects is fixed, is it possible to modify the script to have a scrolling of the last subjects?
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum