diff --git a/modules/poll/poll.model.php b/modules/poll/poll.model.php index b81afc313..a85aa276f 100644 --- a/modules/poll/poll.model.php +++ b/modules/poll/poll.model.php @@ -221,9 +221,10 @@ class pollModel extends poll if(!$output->data) return ''; $poll = new stdClass; - $poll->style = $style; + $poll->style = preg_replace('/[^a-zA-Z0-9_-]/', '', $style); $poll->poll_count = (int)$output->data->poll_count; $poll->stop_date = $output->data->stop_date; + $skin = preg_replace('/[^a-zA-Z0-9_-]/', '', $skin); $columnList = array('poll_index_srl', 'title', 'checkcount', 'poll_count'); $output = executeQuery('poll.getPollTitle', $args, $columnList); @@ -279,7 +280,7 @@ class pollModel extends poll if(!$output->data) return ''; $poll = new stdClass; - $poll->style = $skin; + $poll->style = preg_replace('/[^a-zA-Z0-9_-]/', '', $skin); $poll->poll_count = (int)$output->data->poll_count; $poll->stop_date = $output->data->stop_date;