Ignore:
Timestamp:
Feb 9, 2014, 1:26:25 PM (10 years ago)
Author:
nikrou
Message:

Fix issue with tag with an ampersand (need encoding)
Allow to choose width and height in menu (either null)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/pwgCumulus/include/pwgCumulusContent.class.php

    r26115 r27279  
    101101            $template->assign('PWG_CUMULUS_IMGS', PWG_CUMULUS_PLUGIN_IMGS);
    102102     
    103             $template->assign('PWG_CUMULUS_WIDTH', $this->plugin_config->pwg_cumulus_width);
    104             $template->assign('PWG_CUMULUS_HEIGHT', $this->plugin_config->pwg_cumulus_height);
     103            $template->assign('PWG_CUMULUS_WIDTH', htmlspecialchars($this->plugin_config->pwg_cumulus_width,ENT_COMPAT,'UTF-8'));
     104            $template->assign('PWG_CUMULUS_HEIGHT', htmlspecialchars($this->plugin_config->pwg_cumulus_height,ENT_COMPAT,'UTF-8'));
     105            $template->assign('PWG_CUMULUS_WIDTH_IN_MENU', htmlspecialchars($this->plugin_config->pwg_cumulus_width_in_menu,ENT_COMPAT,'UTF-8'));
     106            $template->assign('PWG_CUMULUS_HEIGHT_IN_MENU', htmlspecialchars($this->plugin_config->pwg_cumulus_height_in_menu,ENT_COMPAT,'UTF-8'));
    105107            $template->assign('PWG_CUMULUS_MODE_TRANSPARENT', $this->plugin_config->pwg_cumulus_mode_transparent);
    106             $template->assign('PWG_CUMULUS_BGCOLOR', $this->plugin_config->pwg_cumulus_bgcolor);
    107             $template->assign('PWG_CUMULUS_COLOR1', '0x'.$this->plugin_config->pwg_cumulus_color1);
    108             $template->assign('PWG_CUMULUS_COLOR2', '0x'.$this->plugin_config->pwg_cumulus_color2);
    109             $template->assign('PWG_CUMULUS_HICOLOR', '0x'.$this->plugin_config->pwg_cumulus_hicolor);
     108            $template->assign('PWG_CUMULUS_BGCOLOR', htmlspecialchars($this->plugin_config->pwg_cumulus_bgcolor,ENT_COMPAT,'UTF-8'));
     109            $template->assign('PWG_CUMULUS_COLOR1', '0x'.htmlspecialchars($this->plugin_config->pwg_cumulus_color1,ENT_COMPAT,'UTF-8'));
     110            $template->assign('PWG_CUMULUS_COLOR2', '0x'.htmlspecialchars($this->plugin_config->pwg_cumulus_color2,ENT_COMPAT,'UTF-8'));
     111            $template->assign('PWG_CUMULUS_HICOLOR', '0x'.htmlspecialchars($this->plugin_config->pwg_cumulus_hicolor,ENT_COMPAT,'UTF-8'));
    110112            foreach ($mbCumulus->data as &$tag) {
    111113                $tag['size'] = $this->plugin_config->pwg_cumulus_coeff * $tag['level'];
     
    113115                    $tag['URL'] = $tag['U_ADD'];
    114116                }
     117                $tag['display_name'] = urlencode($tag['name']);
    115118            }
    116119            $template->assign('PWG_CUMULUS_TAGS', $mbCumulus->data);
Note: See TracChangeset for help on using the changeset viewer.