print ("Website Hex Color Scheme Previewer \n");
/* sets the color to maroon for the first time the users hits the page */
if ($bgColor == "")
{
$bgColor = "#890F01";
}
if ($textColor == "")
{
$textColor = "#FFFFCC";
}
if ($linkColor == "")
{
$linkColor = "#FF9966";
}
if ($alinkColor == "")
{
$alinkColor = "#CC6633";
}
if ($vlinkColor == "")
{
$vlinkColor = "#5AAF74";
}
/* opens body using the specified background color and image unless none is given,
which sets it to maroon with not background image */
if ($bgImage=="")
{
print ("\"$linkColor\" VLINK=\"$vlinkColor\" ALINK=\"$alinkColor\">\n");
}
else
{
print ("\"$textColor\" LINK=\"$linkColor\" VLINK=\"$vlinkColor\" ALINK=\"$alinkColor\">\n");
}
/*
**prints out the formatting table
*/
print ("\n");
print ("\"563\">\n");
print ("\n");
/*
**prints out the introductory text
*/
print ("Plan your Web Site's Colors
\n");
print ("Website Color Scheme Previewier
\n");
print (" \n");
print ("Simply enter in the hexidecimal or text name for the colors you wish to
preview together, and then press the button below. The colors on this
page will then change to the colors you have chosen, and the HTML tag will be generated
below. Simply copy and paste this code into the webpage and
the color scheme will be set for you.");
print ("\n");
print ("
Link Color\n");
print ("
Active Link
Color\n");
print ("
Visited Link
Color\n");
print (" \n");
print ("
The HTML for this color scheme is:
");
/*
** If the user has not specified a backgound image, print the HTML body code
without a background attribute
*/
if ($bgImage=="")
{
print ("$textColor" LINK="$linkColor" VLINK="$vlinkColor" ALINK="
$alinkColor">
");
}
else
{
print ("BACKGROUND="$bgImage" TEXT="$textColor" LINK="
$linkColor" VLINK="$vlinkColor" ALINK="
$alinkColor">
");
}
/*
**starts form
*/
print ("\n");
print ("\n");
print ("
\n");
/*
**closes the formatting table
*/
print (" \n");
print ("
\n");
/*
**closes the html page
*/
print ("\n");
print ("\n");
?>