Relax restriction on image tag src URIs. Others PLEASE TEST (HTML mails with unsafe...
[squirrelmail.git] / themes / darkness.php
index ccd202b0152fbff69521b8f7f86ee423211e8653..b7ca509e5e8a28f73668a8dcaf1fd0775300cd6a 100755 (executable)
  * @subpackage themes
  */
 
-/**
- * Load up the usual suspects.. */
-require_once(SM_PATH . 'functions/strings.php');
-
-   // Note:  The text distance is actually pre-squared
-   // Background range is from 24-64, all three colors are the same
-   // Text range is from 196 to 255
-   $BackgroundTargetDistance = 12;
-   $BackgroundAdjust = 1;
-   $TextTargetDistance = 65536;
-   $TextAdjust = 0.95;
+// Note:  The text distance is actually pre-squared
+// Background range is from 24-64, all three colors are the same
+// Text range is from 196 to 255
+$BackgroundTargetDistance = 12;
+$BackgroundAdjust = 1;
+$TextTargetDistance = 65536;
+$TextAdjust = 0.95;
 
 function IsUnique($Distance, $r, $g, $b, $usedArray)
 {
@@ -42,9 +38,8 @@ function IsUnique($Distance, $r, $g, $b, $usedArray)
 // Always tremble background
 // This might make people go insane.  Yes!  *Victory dance!*
 function Darkness_HeaderPlugin() {
-   global $PHP_SELF;
 
-   if (substr($PHP_SELF, -18) == '/src/left_main.php') {
+   if (defined('PAGE_NAME') && PAGE_NAME=='left_main') {
       echo '<meta http-equiv="Page-Enter" content="' .
          'blendTrans(Duration=2.0)" />' . "\n";
    }
@@ -75,9 +70,6 @@ global $squirrelmail_plugin_hooks;
 $squirrelmail_plugin_hooks['generic_header']['theme_darkness'] =
     'Darkness_HeaderPlugin';
 
-/** seed the random number generator **/
-sq_mt_randomize();
-
 $color[3] = '#000000';
 $color[4] = '#000000';
 $used = array(0);