Modification Name: HTML For Staff Only v1.0

Author: GuldantheWarlock (GuldantheWarlock@xmbgarage.com)

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

Supported Version: XMB 1.9.8 SP3/SP4

Notes: This modification is released under the GPL. You should have recieved a copy of it with this software package.

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

=======================================================================================================
=======
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 File: lang/English.lang.php:
=======================
=======================
Add to End of File Above ?>
=======================

// 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 = '';
        settingHTML('sightml', $sightmlon, $sightmloff);
        
===========
Add Below:
===========

        // HTML For Staff Only Mod Begin
        $staffhtmlon = $staffhtmloff = '';
        settingHTML('staffhtml', $staffhtmlon, $staffhtmloff);
        // 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:
======

        $smileyinsertnew = formOnOff('smileyinsertnew');

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

        // HTML For Staff Only Mod Begin
        $staffhtmlnew = formOnOff('staffhtmlnew');
        // HTML For Staff Only Mod End

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

        $db->query("UPDATE ".X_PREFIX."settings SET
        
============
Replace With:
============

        $db->query("UPDATE ".X_PREFIX."settings SET
            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!