Example #1
0
 public function getHtmlProperty()
 {
     $info = $this->jsHelper()->parseClientSideBlockInfo($this);
     $out = parent::getHtmlProperty();
     foreach (array('class', 'style') as $attribute) {
         $value = '';
         if (preg_match('/' . $attribute . '="(.*?)"/i', $out, $matches)) {
             $value = $matches[1];
             $out = preg_replace('/' . $attribute . '=".*?"/i', '', $out);
         }
         if ($value && $info[$attribute]) {
             $value .= ' ';
         }
         $value .= $info[$attribute];
         if ($value) {
             $out .= "{$attribute}=\"{$value}\"";
         }
     }
     $out .= $info['attribute_html'];
     return $out;
 }