Hack Name: HTML For Staff Only v1.0

Author: GuldantheWarlock (GuldantheWarlock@xmbgarage.com)

Description:
This hack will add a setting that will allow html to be used only by staff.

Supported Version: XMB 1.9.5 Nexus Final

Notes:

This hack is released under the GPL. You should have recieved a copy of it with this hack.

Please backup your files before installing this mod. Neither XMBGarage nor the author can be held 
responsible if your board stops functioning properly due to you installing this hack.

=======================================================================================================

=======
Step 1:
=======

=============================================
Go to Administration Panel -> Insert Raw SQL:
=============================================

========================================
Paste the following code and hit submit:
========================================

ALTER TABLE $table_settings ADD `staffhtml` VARCHAR(3) NOT NULL default 'on';

=======================================================================================================

=======
Step 2:
=======

===========================
Edit lang/English.lang.php:
===========================

===================
Add to End of File:
===================

// HTML For Staff Only Mod Begin
$lang['staffhtml'] = "Staff only HTML:";
// HTML For Staff Only Mod End

=======================================================================================================

=======
Step 3:
=======

============
Edit cp.php:
============

=====
Find:
=====

        $sightmlon = $sightmloff = '';
        if ($SETTINGS['sightml'] == "on") {
            $sightmlon = $selHTML;
        } else {
            $sightmloff = $selHTML;
        }
        
==========
Add Below:
==========

        // HTML For Staff Only Mod Begin
        $staffhtmlon = $staffhtmloff = '';
        switch ($SETTINGS['staffhtml']) {
            case 'on':
                $staffhtmlon = $selHTML;
                break;
            default:
                $staffhtmloff = $selHTML;
                break;
        }
        // HTML For Staff Only Mod End
        
=====
Find:
=====

        printsetting1($lang['sightml'], 'sightmlnew', $sightmlon, $sightmloff);
        
==========
Add Below:
==========

        // HTML For Staff Only Mod Begin
        printsetting1($lang['staffhtml'], 'staffhtmlnew', $staffhtmlon, $staffhtmloff);
        // HTML For Staff Only Mod End

=====
Find:
=====

        $resetSigNew = ($resetSigNew == 'on') ? 'on' : 'off';

==========
Add Below:
==========

        $staffhtmlnew = ($staffhtmlnew == 'on') ? 'on' : 'off';

=====
Find:
=====

        $db->query("UPDATE $table_settings SET
        
===============================
Add to end of line BEFORE "); :
===============================

, staffhtml='$staffhtmlnew'

=======================================================================================================

=======
Step 4:
=======

====================
Edit viewthread.php:
====================

=====
Find:
=====

        $post['message'] = postify($post['message'], $smileyoff, $bbcodeoff, $forum['allowsmilies'], $forum['allowhtml'], $forum['allowbbcode'], $forum['allowimgcode']);
        
==========
Add Above:
==========

        // HTML For Staff Only Mod Begin
        $forum['allowhtml'] = (($SETTINGS['staffhtml'] == 'on') ? (X_STAFF ? 'yes' : 'no') : $forum['allowhtml']);
        // HTML For Staff Only Mod End

=======================================================================================================

Enjoy!