<?xml version="1.0" encoding = "utf-8"?>

<snippet xmlns:MMString="http://www.macromedia.com/schemes/dat/string/" MMString:name = "Snippets/JavaScript/randomizers/randomBgColor_csn/snippet/name/Random" MMString:description = "Snippets/JavaScript/randomizers/randomBgColor_csn/snippet/description/Changes" preview="code" type="block">


<insertText location="beforeSelection">

<![CDATA[// * Dependencies * 
// this function requires the following snippets:
// JavaScript/Randomizers/randomNumber
// JavaScript/conversions/base_conversion/decToHex
function randomBgColor()
{
  var r,g,b;
  r = decToHex(randomNumber(256)-1);
  g = decToHex(randomNumber(256)-1);
  b = decToHex(randomNumber(256)-1);
  document.bgColor = "#" + r + g + b;
}
]]>

</insertText>

<insertText location="afterSelection"><![CDATA[]]>

</insertText>

</snippet>
