Essayez ceci :
Ouvrez THEME.PHP et ajoutez le code suivant à la suite de la fonction theme_html_picture()
Si cette fonction n'est pas présente dans votre fichier THEME.PHP, copiez-la depuis SAMPLE/THEME.PHP et collez-la dans votre THEME.PHP
$players['UNK'] = array('id' => 'DefaultPlayer',
'clsid' => '',
'codebase' => '',
'mime' => ''
);
$players['DM'] = array('id' => 'DefaultPlayer',
'clsid' => '',
'codebase' => '',
'mime' => 'dailymotion'
);
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 ($player['mime']=="dailymotion") {
$code_cle=explode("|", file_get_contents($picture_url));
$pic_html = "<div style=\"margin-bottom:25px;margin-top:25px;\"><div style=\"width:320px;text-align:center;\"><style type=\"text/css\"><!-- #z".$code_cle[1]."{width:320px;height:256px;border:none;margin:0px;} --></style><iframe src=\"http://www.dailymotion.com/blog/video/".$code_cle[0]."?key=".$code_cle[1]."\" style=\"width:320px;height:256px;border:none;margin:0px;\" width=\"320\" height=\"256\" frameborder=\"0\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\" id=\"".$code_cle[1]."\">Dailymotion blogged video</iframe><br /><span style=\"margin-top:0px;\"><a href=\"http://www.dailymotion.com/video/".$code_cle[0]."\">Aller sur Dailymotion</a></span></div></div>";
}
else {
$pic_html = '<object id="'.$player['id'].'" '.$player['clsid'].$player['codebase'].$player['mime'].$image_size['whole'].'>';
$pic_html .= "<param name=\"autostart\" value=\"$autostart\" /><param name=\"src\" value=\"". $picture_url . "\" />";
$pic_html .= '<embed '.$image_size['whole'].' src="'. $picture_url . '" autostart="'.$autostart.'" '.$player['mime'].'></embed>';
$pic_html .= "</object><br />\n";
}
}
$CURRENT_PIC_DATA['html'] = $pic_html;
$CURRENT_PIC_DATA['header'] = '';
$CURRENT_PIC_DATA['footer'] = '';
$CURRENT_PIC_DATA = CPGPluginAPI::filter('file_data',$CURRENT_PIC_DATA);
$params = array('{CELL_HEIGHT}' => '100',
'{IMAGE}' => $CURRENT_PIC_DATA['header'].$CURRENT_PIC_DATA['html'].$CURRENT_PIC_DATA['footer'],
'{ADMIN_MENU}' => $CURRENT_PIC_DATA['menu'],
'{TITLE}' => bb_decode($CURRENT_PIC_DATA['title']),
'{CAPTION}' => bb_decode($CURRENT_PIC_DATA['caption']),
);
return template_eval($template_display_media, $params);
}
} //{THEMES}
Ouvrez votre Base de Données avec votre PhpMyAdmin.
Allez à la Table "filetypes" et ajoutez :
extension mime content player
[extention] dailymotion movie DM
Autre portion de code qu'il est possible de remplacer dans le code ci-dessus :
$pic_html = "<object width=\"400\" height=\"316\">
<param name=\"movie\" value=\"http://www.dailymotion.com/swf/".$code_cle[0]."\"></param>
<param name=\"allowfullscreen\" value=\"true\"></param>
<embed src=\"http://www.dailymotion.com/swf/".$code_cle[0]."\" type=\"application/x-shockwave-flash\" width=\"400\" height=\"316\" allowfullscreen=\"true\">
</embed>
</object>";
Il vous faut les
Code|Clef des vidéos. Et en principe ça marche.
Je n'ai jamais installer ce truc, et je n'ai pas l'intention de le faire
PYAP