Fix invalid CSS when title color starts with #

칼라피커를 어떤 것을 사용하는지에 따라 색상 앞에 #가 붙어 들어올 때가 있음
이런 경우 문법에 맞지 않는 ##xxxxxx 결과가 나오지 않도록 패치
This commit is contained in:
Kijin Sung 2017-12-07 14:41:52 +09:00
parent 89e4936fb1
commit 78a8bd362d

View file

@ -482,7 +482,7 @@ class documentItem extends BaseObject
$attrs = array();
$this->add('title_color', trim($this->get('title_color')));
if($this->get('title_bold')=='Y') $attrs[] = "font-weight:bold;";
if($this->get('title_color') && $this->get('title_color') != 'N') $attrs[] = "color:#".$this->get('title_color');
if($this->get('title_color') && $this->get('title_color') != 'N') $attrs[] = "color:#".ltrim($this->get('title_color'), '#');
if(count($attrs))
{