1
0
mirror of https://github.com/vichan-devel/vichan.git synced 2025-02-20 12:41:17 +01:00

Merge ../http

Conflicts:
	inc/instance-config.php
This commit is contained in:
8chan 2014-11-01 16:01:59 -07:00
commit c695839cb5
4 changed files with 8 additions and 2 deletions

View File

@ -258,6 +258,9 @@
if (!in_array($b, $mod['boards']) and $mod['boards'][0] != '*')
error($config['error']['noaccess']);
if (!hasPermission($config['mod']['edit_settings'], $b))
error($config['error']['noaccess']);
if (!openBoard($b))
error("Could not open board!");
@ -279,6 +282,7 @@
$image_reject_repost = isset($_POST['image_reject_repost']) ? 'true' : 'false';
$allow_delete = isset($_POST['allow_delete']) ? 'true' : 'false';
$allow_flash = isset($_POST['allow_flash']) ? '$config[\'allowed_ext_files\'][] = \'swf\';' : '';
$allow_pdf = isset($_POST['allow_pdf']) ? '$config[\'allowed_ext_files\'][] = \'pdf\';' : '';
$code_tags = isset($_POST['code_tags']) ? '$config[\'additional_javascript\'][] = \'js/code_tags/run_prettify.js\';$config[\'markup\'][] = array("/\[code\](.+?)\[\/code\]/ms", "<code><pre class=\'prettyprint\' style=\'display:inline-block\'>\$1</pre></code>");' : '';
$katex = isset($_POST['katex']) ? '$config[\'katex\'] = true;$config[\'additional_javascript\'][] = \'js/katex/katex.min.js\'; $config[\'markup\'][] = array("/\[tex\](.+?)\[\/tex\]/ms", "<span class=\'tex\'>\$1</span>"); $config[\'additional_javascript\'][] = \'js/katex-enable.js\';' : '';
$oekaki_js = <<<OEKAKI
@ -355,7 +359,7 @@ OEKAKI;
\$config['blotter'] = base64_decode('$blotter');
\$config['stylesheets']['Custom'] = 'board/$b.css';
\$config['default_stylesheet'] = array('Custom', \$config['stylesheets']['Custom']);
$code_tags $katex $oekaki $replace $multiimage $allow_flash
$code_tags $katex $oekaki $replace $multiimage $allow_flash $allow_pdf
if (\$config['disable_images'])
\$config['max_pages'] = 10000;

View File

@ -133,6 +133,7 @@
$config['additional_javascript'][] = 'js/ajax.js';
$config['additional_javascript'][] = 'js/show-own-posts.js';
$config['additional_javascript'][] = 'js/youtube.js';
$config['additional_javascript'][] = 'js/comment-toolbar.js';
//$config['font_awesome_css'] = '/netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css';

View File

@ -158,7 +158,7 @@ $(document).ready(function(){
first_new_post = this;
makeIcon();
}
$('div.thread').append($('<br class="clear">')).after(this);
$(this).insertAfter($('div.post:last').next()).after('<br class="clear">');
new_posts++;
loaded_posts++;
$(document).trigger('new_post', this);

View File

@ -39,6 +39,7 @@
<tr><th>{% trans %}Oekaki{% endtrans %}</th><td><input type="checkbox" name="oekaki" {% if 'js/wpaint.js' in config.additional_javascript %}checked{% endif %}></td></tr>
<tr><th>{% trans %}Format math between [tex]{% endtrans %}</th><td><input type="checkbox" name="katex" {% if config.katex %}checked{% endif %}></td></tr>
<tr><th>{% trans %}Allow SWF uploading{% endtrans %}</th><td><input type="checkbox" name="allow_flash" {% if 'swf' in config.allowed_ext_files %}checked{% endif %}></td></tr>
<tr><th>{% trans %}Allow PDF uploading{% endtrans %}</th><td><input type="checkbox" name="allow_pdf" {% if 'pdf' in config.allowed_ext_files %}checked{% endif %}></td></tr>
<tr><th>{% trans %}Enable dice rolling{% endtrans %}</th><td><input type="checkbox" name="allow_roll" {% if config.allow_roll %}checked{% endif %}></td></tr>
<tr><th>{% trans %}Don't allow users to repost images{% endtrans %}</th><td><input type="checkbox" name="image_reject_repost" {% if config.image_reject_repost %}checked{% endif %}></td></tr>
<tr><th>{% trans %}Allow a poster to delete his own posts{% endtrans %}</th><td><input type="checkbox" name="allow_delete" {% if config.allow_delete %}checked{% endif %}></td></tr>