You are here

function ckeditor_swf_parse_attributes in CKEditor SWF - Enhanced Flash embedding plugin 7

Same name and namespace in other branches
  1. 6.2 ckeditor_swf.module \ckeditor_swf_parse_attributes()
  2. 6 ckeditor_swf.module \ckeditor_swf_parse_attributes()
1 call to ckeditor_swf_parse_attributes()
_ckeditor_swf_filter_process in ./ckeditor_swf.module

File

./ckeditor_swf.module, line 277
Written by Henri MEDOT <henri.medot[AT]absyx[DOT]fr> http://www.absyx.fr

Code

function ckeditor_swf_parse_attributes($tag) {
  $attributes = array();
  unset($matches);
  if (preg_match_all('`\\b([a-z]+)="(.*?)"`is', $tag, $matches, PREG_SET_ORDER)) {
    foreach ($matches as $match) {
      $attributes[strtolower($match[1])] = decode_entities($match[2]);
    }
  }
  return $attributes;
}