Welcome, Guest
Please Login or Register.    Lost Password?

Move CLASS attribute from DIV tag to OBJECT tag
(1 viewing) (1) Guest
Here you can ask all your questions about SWFContent Pro.
Go to bottomPage: 1
TOPIC: Move CLASS attribute from DIV tag to OBJECT tag
#20
Move CLASS attribute from DIV tag to OBJECT tag 7 Months, 2 Weeks ago Karma: 0
Can you move CLASS attribute from DIV tag to OBJECT tag for reason to modify style of swf object by css style (for example add margin to object)?
I've already patched your swfcontent.php for myself (see attachment).

function onPrepareContent( & $article, & $params, $limitstart)
{
...
if ($useSwfobject == 0)
{
//Standard embedding
// protopopov 27.01.2010
// Исходный код заключал тэг object в тэг div.
// Убран тэг div
// Аттрибут class был перенесён в тег object
// Аттрибут id был перенесён в тег object
$divStart = '';
$divEnd = '';

$html = $divStart.'
<object'.$htmlid.' '.$htmlclass.' classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="download.macromedia.com/pub/shockwave/ca....cab#version='.$cabversion.'" width="'.$width.'" height="'.$height.'" align="'.$align.'">
'.$paramTags.'
<param name="movie" value="'.$src.'" />
<embed src="'.$src.'" '.$paramAttributes.' width="'.$width.'" height="'.$height.'" name="'.$name.$objectidadd.'" align="'.$align.'" type="application/x-shockwave-flash" pluginspage="www.adobe.com/go/getflashplayer" />
</object>'.$divEnd;
} else
{
//SWFObject static embedding

if ($doneJSAdd == false)
{
$document = & JFactory::getDocument();
$document->addScript('plugins/content/swfcontent/swfobject.js');
$doneJSAdd = true;
}
if ($uei == 'true')
{
$expressInstallStr = ' , "plugins/content/swfcontent/expressInstall.swf"';
} else
{
$expressInstallStr = '';
}
$js = 'swfobject.registerObject("'.$objectid.$objectidadd.'", "'.$dfv.'"'.$expressInstallStr.');';
$document->addScriptDeclaration($js);
// protopopov 27.01.2010
// Исходный код заключал тэг object в тэг div.
// Убран тэг div
// Аттрибут class был перенесён в тег object
$divStart = '';
$divEnd = '';
$html = $divStart.'<object '.$htmlclass.' classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="'.$width.'" height="'.$height.'" name="'.$name.$objectidadd.'" id="'.$objectid.$objectidadd.'">
'.$paramTags.'
<param name="movie" value="'.$src.'" />
<!--[if !IE]>-->
<object type="application/x-shockwave-flash" data="'.$src.'" width="'.$width.'" height="'.$height.'">
'.$paramTags.'
<!--<![endif]-->
'.$flashAltHTML.'
<!--[if !IE]>-->
</object>
<!--<![endif]-->
</object>'.$divEnd;
}
$content = $this->_str_replaceFirst($swfPlaceHolders[$i], $html, $content);
}
$article->text = $content;
}
protopopov
Fresh Boarder
Posts: 1
graphgraph
User Offline Click here to see the profile of this user
Last Edit: 2010/01/27 22:01 By protopopov.Reason: attachment
The administrator has disabled public write access.
 
#26
Re:Move CLASS attribute from DIV tag to OBJECT tag 6 Months ago Karma: 0
Thanks for your suggestion. I will change this in Version 3.1.0.
webconstructor
Admin
Posts: 86
graph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
Go to topPage: 1
[ Back ] up