Forum->Flatnux->Video YouTube nelle news
  
Welcome Unknown Register Help383 Users

User Message


luigim

0 Level 0 10

levellevellevellevellevellevellevellevellevellevel
profile  home
Saturday 01 December 2007 - 21:56

Video YouTube nelle news:
Se volete inserire un video YouTube nelle news usando bbcode e l'ID del video, basta lavorare sul file functions.php presente nelle root, in particolare,

nella funzione tag2html aggiungere la riga

$string = preg_replace("/\\[youtube\\](.+?)\\[\\/youtube\\]/s",'<object width="425" height="355"><param name="movie" value="http://www.youtube.com/v/$1&rel=1"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/v/$1&rel=1" type="application/x-shockwave-flash" wmode="transparent" width="425" height="355"></embed></object>',$string);


e nella funzione bbcodes_panel la riga

<img onclick="javascript:insertTags('[youtube]', '[/youtube]', '<?=$area?>')" onmouseover="document.getElementsByName('<?=$area?>')[0].focus()" src="<?=fromtheme("images/emoticon/youtube.png");?>" border="0" alt="YouTube video" title="YouTube video" style="cursor: pointer;" />


nella sezione relativa a

case "formatting" :



----------<br>
Luigi<br>
http://www.luigimicco.altervista.org

 [1]