From 07bf32b240a999581627aadcc58c044a577dc62a Mon Sep 17 00:00:00 2001 From: Andreas Gohr Date: Fri, 16 Jan 2009 18:41:40 +0100 Subject: new html_flashobject() function for simple and XHTML valid flash embeds darcs-hash:20090116174140-7ad00-4eb1fe3269d10cb21819a5b220484b7114cbb4de.gz --- inc/parser/xhtml.php | 28 +++++++++++----------------- 1 file changed, 11 insertions(+), 17 deletions(-) (limited to 'inc/parser') diff --git a/inc/parser/xhtml.php b/inc/parser/xhtml.php index 565459220..bad1a21de 100644 --- a/inc/parser/xhtml.php +++ b/inc/parser/xhtml.php @@ -966,26 +966,20 @@ class Doku_Renderer_xhtml extends Doku_Renderer { // return the title of the flash if (!$title) { // just show the sourcename - $title = $this->_xmlEntities(basename(noNS($src))); + $title = basename(noNS($src)); } - return $title; + return $this->_xmlEntities($title); } - $ret .= '_xmlEntities($width).'"'; - if ( !is_null($height) ) $ret .= ' height="'.$this->_xmlEntities($height).'"'; - $ret .= '>'.DOKU_LF; - $ret .= ''.DOKU_LF; - $ret .= ''.DOKU_LF; - $ret .= '_xmlEntities($width).'"'; - if ( !is_null($height) ) $ret .= ' height="'.$this->_xmlEntities($height).'"'; - $ret .= ' type="application/x-shockwave-flash"'. - ' pluginspage="http://www.macromedia.com/go/getflashplayer">'.DOKU_LF; - $ret .= ''.DOKU_LF; - + $att = array(); + $att['class'] = "media$align"; + if($align == 'right') $att['align'] = 'right'; + if($align == 'left') $att['align'] = 'left'; + $ret .= html_flashobject($src,$width,$height, + array('quality' => 'high'), + null, + $att, + $this->_xmlEntities($title)); }elseif($title){ // well at least we have a title to display $ret .= $this->_xmlEntities($title); -- cgit v1.2.3