WebsiteBaker 2.13.8 is now available!
R.I.P Dietmar (luisehahne) and thank you for all your valuable work for WBhttps://forum.websitebaker.org/index.php/topic,32355.0.html
if (function_exists('display_news_items')) { display_news_items(9, 5, 50, 1, 'Best Practice Beispiele', 'Weiterlesen', 'Momentan in Bearbeitung...', false, '<a><img>', true, ' (d.m.Y)');}
display_news_items(2, 5, 150, 1, 'Latest News','Details', 'uups, no news available', true, '<a><img>', true,'(h:i, d.m.Y)');
Do you mean here?:http://www.websitebakers.com/
NEWS INFO: {TITLE}, {POSTED_WHEN}, {CONTENT_SHORT}, {LINK}FUNCTION ARGUMENTS: {ARG_HEADER_TEXT}, {ARG_READMORE_TEXT}, {ARG_NO_NEWS_TEXT}
<?phpif (function_exists('display_news_items')) { display_news_items(0, 2, 10, 1, 'News', 'Read more...', 'No news'); } ?>
Would it make sense to add a third "sort_by" parameter (e.g. 3) which sorts by the field PUBLISHED_WHEN? In this case the field PUBLISHED_WHEN could be taken as a creation date which is visible/modifyable via the backend and automatically sorted by this date.
$sql_sort_by = ($sort_by == 1) ? 'position' : ($sort_by == 3 && $add_sql != '') ? 'published_when' : 'posted_when';
$sql_sort_by = ($sort_by == 1) ? 'position' : (($sort_by == 3 && $add_sql != '') ? 'published_when' : 'posted_when');