1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
| add_shortcode("ckplayer","ipc_ckplayer");
function ipc_ckplayer( $atts, $content=null )
{
return "
<div id="a1"></div>
<script type="text/javascript" src="/ckplayer/ckplayer.js" charset="utf-8"></script>
<script type="text/javascript">
var flashvars={
f:'".$content."',
c:0,
my_url:encodeURIComponent(window.location.href),
my_title:encodeURIComponent(document.title)
};
var params={bgcolor:'#FFF',allowFullScreen:true,allowScriptAccess:'always',wmode:'transparent'};
var video=['".$content."->video/mp4'];
CKobject.embed('/ckplayer/ckplayer.swf','a1','ckplayer_a1','100%','400',false,flashvars,video,params);
</script>
";
} |