mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-07-06 10:28:29 +02:00
added toggle in config to switch on and off the motd
This commit is contained in:
@@ -56,7 +56,10 @@ var config = {
|
||||
"privilege_thresholds": {
|
||||
"manage_thread": 1000,
|
||||
"manage_content": 2000
|
||||
}
|
||||
},
|
||||
|
||||
"show_motd": true,
|
||||
"motd": undefined
|
||||
}
|
||||
|
||||
config.url = config.base_url + (config.use_port ? ':' + config.port : '') + '/';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<div class="hero-unit">
|
||||
<div class="hero-unit {motd_class}">
|
||||
{motd}
|
||||
</div>
|
||||
|
||||
|
||||
@@ -114,6 +114,7 @@ var express = require('express'),
|
||||
break;
|
||||
case 'home' :
|
||||
categories.getAllCategories(function(data) {
|
||||
data.motd_class = config.show_motd ? '' : 'none';
|
||||
data.motd = marked(config.motd || "# NodeBB v0.1\nWelcome to NodeBB, the discussion platform of the future.\n\n<a target=\"_blank\" href=\"http://www.nodebb.org\" class=\"btn btn-large\"><i class=\"icon-comment\"></i> Get NodeBB</a> <a target=\"_blank\" href=\"https://github.com/psychobunny/NodeBB\" class=\"btn btn-large\"><i class=\"icon-github-alt\"></i> Fork us on Github</a> <a target=\"_blank\" href=\"https://twitter.com/dcplabs\" class=\"btn btn-large\"><i class=\"icon-twitter\"></i> @dcplabs</a>");
|
||||
res.send(JSON.stringify(data));
|
||||
}, (req.user) ? req.user.uid : 0);
|
||||
|
||||
Reference in New Issue
Block a user