Create an admin setting that allows the adminstrator to change the mouse over color. Thanks floridave
This commit is contained in:
parent
2b75fef32f
commit
f6f80b4adc
@ -43,6 +43,7 @@ class Admin_Tag_Cloud_Controller extends Admin_Controller {
|
|||||||
}
|
}
|
||||||
if ($valid) {
|
if ($valid) {
|
||||||
module::set_var("tag_cloud", "tagcolor", $options->tagcolor->value);
|
module::set_var("tag_cloud", "tagcolor", $options->tagcolor->value);
|
||||||
|
module::set_var("tag_cloud", "mouseover", $options->mouseover->value);
|
||||||
module::set_var("tag_cloud", "background_color", $options->background_color->value);
|
module::set_var("tag_cloud", "background_color", $options->background_color->value);
|
||||||
module::set_var("tag_cloud", "transparent", $options->transparent->value);
|
module::set_var("tag_cloud", "transparent", $options->transparent->value);
|
||||||
module::set_var("tag_cloud", "speed", $options->speed->value);
|
module::set_var("tag_cloud", "speed", $options->speed->value);
|
||||||
@ -67,6 +68,10 @@ class Admin_Tag_Cloud_Controller extends Admin_Controller {
|
|||||||
->value(module::get_var("tag_cloud", "tagcolor", "0x333333"))
|
->value(module::get_var("tag_cloud", "tagcolor", "0x333333"))
|
||||||
->error_message("not_valid", t("The color value must be specified as '0xhhhhhh'"))
|
->error_message("not_valid", t("The color value must be specified as '0xhhhhhh'"))
|
||||||
->rules("required|length[8]");
|
->rules("required|length[8]");
|
||||||
|
$group->input("mouseover") ->label(t("Tag mouseover color"))
|
||||||
|
->value(module::get_var("tag_cloud", "mouseover", "0x000000"))
|
||||||
|
->error_message("not_valid", t("The color value must be specified as '0xhhhhhh'"))
|
||||||
|
->rules("required|length[8]");
|
||||||
$group->input("background_color")->label(t("Background color"))
|
$group->input("background_color")->label(t("Background color"))
|
||||||
->value(module::get_var("tag_cloud", "background_color", "0xffffff"))
|
->value(module::get_var("tag_cloud", "background_color", "0xffffff"))
|
||||||
->error_message("not_valid", t("The color value must be specified as '0xhhhhhh'"))
|
->error_message("not_valid", t("The color value must be specified as '0xhhhhhh'"))
|
||||||
|
@ -28,7 +28,7 @@ class tag_cloud_block {
|
|||||||
switch ($block_id) {
|
switch ($block_id) {
|
||||||
case "tag_cloud_site":
|
case "tag_cloud_site":
|
||||||
$options = array();
|
$options = array();
|
||||||
foreach (array("tagcolor", "background_color", "transparent", "speed", "distribution")
|
foreach (array("tagcolor", "background_color", "mouseover", "transparent", "speed", "distribution")
|
||||||
as $option) {
|
as $option) {
|
||||||
$value = module::get_var("tag_cloud", $option, null);
|
$value = module::get_var("tag_cloud", $option, null);
|
||||||
if (!empty($value)) {
|
if (!empty($value)) {
|
||||||
@ -36,6 +36,9 @@ class tag_cloud_block {
|
|||||||
case "tagcolor":
|
case "tagcolor":
|
||||||
$options["tcolor"] = $value;
|
$options["tcolor"] = $value;
|
||||||
break;
|
break;
|
||||||
|
case "mouseover":
|
||||||
|
$options["hicolor"] = $value;
|
||||||
|
break;
|
||||||
case "background_color":
|
case "background_color":
|
||||||
$options["bgColor"] = $value;
|
$options["bgColor"] = $value;
|
||||||
break;
|
break;
|
||||||
|
Reference in New Issue
Block a user