Hello,
Im pretty sure this goes unsupported and i might have posted it in the wrong section (please move accordingly).
I'm trying to use JW WMV Player (
http://www.jeroenwijering.com/?item=jw_wmv_player) to display wmv video content on my gallery.
This is as far as i've gotten:
In theme.php in "function theme_html_picture()"
$autostart = ($CONFIG['media_autostart']) ? ('true'):('false');
$players['DIVX'] = array('id' => 'DivX',
'clsid' => 'classid="clsid:67DABFBF-D0AB-41fa-9C46-CC0F21721616"',
'codebase' => 'codebase="http://download.divx.com/player/stage6/DivXWebPlayerInstaller.exe"',
'mime' => 'type="video/divx"'
);
$players['RMP'] = array('id' => 'RealPlayer',
'clsid' => 'classid="clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA" ',
'codebase' => '',
'mime' => 'type="audio/x-pn-realaudio-plugin" '
);
$players['QT'] = array('id' => 'QuickTime',
'clsid' => 'classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" ',
'codebase' => 'codebase="http://www.apple.com/qtactivex/qtplugin.cab" ',
'mime' => 'type="video/x-quicktime" '
);
$players['SWF'] = array('id' => 'SWFlash',
'clsid' => ' classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" ',
'codebase' => 'codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" ',
'mime' => 'type="application/x-shockwave-flash" '
);
$players['UNK'] = array('id' => 'DefaultPlayer',
'clsid' => '',
'codebase' => '',
'mime' => ''
);
if (isset($_COOKIE[$CONFIG['cookie_name'].'_'.$mime_content['extension'].'player'])) {
$user_player = $_COOKIE[$CONFIG['cookie_name'].'_'.$mime_content['extension'].'player'];
} else {
$user_player = $mime_content['player'];
}
// There isn't a player selected or user wants client-side control
if (!$user_player) {
$user_player = 'UNK';
}
$player = $players[$user_player];
if ($mime_content['content']=='movie' && $mime_content['extension']=='flv') {
$descript = $CURRENT_PIC_DATA['title'];
$flv = $CONFIG['fullpath'] . $CURRENT_PIC_DATA['filepath'] . $CURRENT_PIC_DATA['filename'];
$pic_html = "<embed src='flvplayer.swf' width='500' height='375' allowfullscreen='true' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' flashvars='file=$flv&autostart=true' />";
} elseif ($mime_content['content']=='audio' && $mime_content['extension']=='mp3') {
$flv = $CONFIG['fullpath'] . $CURRENT_PIC_DATA['filepath'] . $CURRENT_PIC_DATA['filename'];
$pic_html = "<embed src='flvplayer.swf' width='500' height='20' allowfullscreen='true' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' flashvars='file=$flv&autostart=true' />";
} elseif ($mime_content['content']=='movie' && $mime_content['extension']=='wmv') {
$flv = $CONFIG['fullpath'] . $CURRENT_PIC_DATA['filepath'] . $CURRENT_PIC_DATA['filename'];
$pic_html = "<embed src='wmvplayer.xaml' width='500' height='500' type='application/x-mplayer2' pluginspage='http://silverlight.dlservice.microsoft.com'/>";
} else {
$pic_html = '<object id="'.$player['id'].'" '.$player['clsid'].$player['codebase'].$player['mime'].$image_size['whole'].'>';
$pic_html .= "<param name=\"src\" value=\"". $picture_url . "\" /><param name=\"ShowControls\" value=\"1\" /><param name=\"wmode\" value=\"transparent\" /><param name=\"ShowStatusBar\" value=\"1\" /><param name=\"ShowDisplay\" value=\"0\" /><param name=\"DisplaySize\" value=\"0\" /><param name=\"autostart\" value=\"$autostart\" />";
$pic_html .= '<embed '.$image_size['whole'].' src="'. $picture_url . '" AllowChangeDisplaySize="1" " allowContextMenu="false" " mode="mini" " bannerEnabled="false" " movieTitle="dke_video" '.' autostart="'.$autostart.'" '.$player['mime'].'></embed>';
$pic_html .= "</object><br />\n";
}
}
You can see that i've already installed JW Flash player (which works perfectly) to both play flv videos and MP3 audio. And i use divx webplayer for "the rest" which only leaves out avi video.
The code
} elseif ($mime_content['content']=='movie' && $mime_content['extension']=='wmv') {
$flv = $CONFIG['fullpath'] . $CURRENT_PIC_DATA['filepath'] . $CURRENT_PIC_DATA['filename'];
$pic_html = "<embed src='wmvplayer.xaml' width='500' height='500' type='application/x-mplayer2' pluginspage='http://silverlight.dlservice.microsoft.com'/>";
Is the supposed JW WMV Player which does not work.
For some reason i still get the windows media player for WMV files.
I've also added the scripts to template.html
<script type="text/javascript" src="silverlight.js"></script>
<script type="text/javascript" src="player.js"></script
If anyone could take a look at this i would be very happy, im pretty sure im close to the actual solution, but im no sql/php coder so i have a hard time figuring this one out.
Thank you!
PS. Sorry for my bad english!