Smf video modu sadece linki yapıştır

Mavi Gül

ѕση_¢ıqℓıк
Özel üye
Açıklama: Bu mod sayesinde otomatik olarak yani bbcode ihtiyacı olmadan direk linkini yapıştırarak Youtube/Myspace/GoogleVideo/Metacafe/Stage6 ve diğer türleri sitenizde yayınlayabiliyorsunuz, denenmiştir

Sources için de Subs.php dosyasında şunu bul
Kod:
$message = strtr($message, array('  ' => ' &nbsp;', "\r" => '', "\n" => '<br />', '<br /> ' => '<br />&nbsp;', '
' => "\n"));
Hemen altına bunu ekleyin:
Kod:
// AUTO EMBED VIDEO CLIPS MOD
    // Disables if on print page
    if($smileys !== "print") {
    $embed = array();
    
    /* ##################################################
####
    #    COMMENTED VERSION EXPLAINING EACH LINE
    $embed[] = array(
        'name'    => 'YouTube',    //    OPTIONAL, JUST FOR ASTETIC/NAMING/QUICK REFERENCE PURPOSES
        'enabled'    => 1,            //    1 = ENABLED, 0 = DISABLED, ALLOWS YOU TO QUICKLY DISABLE/ENABLE SPECIFIC SITES
        //    THE PATTERN/REGEX FOR THE PREG_MATCH (ALL dots need escaping)
        'pattern' => 'https://(www\.|uk\.|fr\.|ie\.|it\.|jp\.|pl\.|es\.|nl\.|br\.|)youtube\.com/(watch\?v=|v/|jp\.swf\?video_id=)([0-9A-Za-z-_]{11})(.*?)',
        //    EMBED = $1,$2,$3 are replaced by the video id.  eg the video id in the youtube link is the 3rd variable matched (basically the third in b****ets)
        //    IS REQUIRED, EXCEPT BY STAGE6 WHICH USES A PARAM CALLED SRC INSTEAD
        'embedlink'        => 'https://www.youtube.com/v/$3',
        'width'        => '425',    //    WIDTH (WITHOUT PX, THAT IS ADDED LATER)
        'height'        => '350',    //     HEIGHT (AGAIN WITHOUT PX)
        'codebase'        => '',        //    SPECIAL CODECS HAVE CODEBASES, IF NOT LEAVE BLANK
        'type'        => '',        //    UNLESS DIFFERENT TO application/x-shockwave-flash, LEAVE BLANK
        'pluginspage'    => '',         //    A LINK TO OBTAIN THE PLUGIN/CODEC, ELSE LEAVE BLANK
        'classid'        => '',        //    IF HAS A CLASS ID, ELSE LEAVE BLANK
        'extraparams'     => '',        //    IF ANY IMPORTANT EXTRA PARAMS, FOR MOST VIDEO SITES YOU WON'T NEED TO TOUCH THIS
    );
    #############################################
#########*/
    
    $embed[] = array(
        'name' => 'YouTube',
        'enabled' => 1,
        'pattern' => 'https://(www\.|uk\.|fr\.|ie\.|it\.|jp\.|pl\.|es\.|nl\.|br\.|)youtube\.com/(watch\?v=|v/|jp\.swf\?video_id=)([0-9A-Za-z-_]{11})(.*?)',
        'embedlink' => 'https://www.youtube.com/v/$3',
        'width' => '425',
        'height' => '350',
    );
    $embed[] = array(
        'name' => 'YouTube Playlist',
        'enabled' => 1,
        'pattern' => 'https://(www\.|uk\.|fr\.|ie\.|it\.|jp\.|pl\.|es\.|nl\.|br\.|)youtube\.com/(ep\.swf\?id=|view_play_list\?p=|p/)([0-9a-f]{16})(.*?)',
        'embedlink' => 'https://www.youtube.com/p/$3',
        'width' => '530',
        'height' => '370',
    );
    $embed[] = array(
        'name' => 'Google Video',
        'enabled' => 1,
        'pattern' => 'https://video\.google\.(com|com\.au|co\.uk|de|es|fr|it|nl|pl|ca)/(videoplay|url)\?docid=([0-9a-z-_]{1,20})(.*?)',
        'embedlink' => 'https://video.google.$1/googleplayer.swf?docId=$3',
        'width' => '530',
        'height' => '370',
    );    
    $embed[] = array(
        'name' => 'MetaCafe',
        'enabled' => 1,
        'pattern' => 'https://(www\.|)metacafe\.com/(watch|fplayer)/([0-9]{1,10})/(.*?)',
        'embedlink' => 'https://www.metacafe.com/fplayer/$3/metacafe.swf',
        'width' => '530',
        'height' => '370',
    );    
    $embed[] = array(
        'name' => 'MySpaceTv',
        'enabled' => 1,
        'pattern' => 'https://(vids\.myspace|myspacetv)\.com/index\.cfm\?fuseaction=vids\.individual&amp;VideoID=([0-9]{1,10})(.*?)',
        'embedlink' => 'https://lads.myspace.com/videos/myspacetv_vplayer0005.swf?m=$2&amp;type=video',
        'width' => '480',
        'height' => '386',
    );    
    $embed[] = array(
        'name' => 'Stage6',
        'enabled' => 1,
        'pattern' => 'https://stage6\.divx\.com/(.*?)/video/([0-9]{1,11})/(.*?)',
        'embedlink' => '', // STAGE6 DON'T USE THIS TYPE, IT MUST BE A PARAM
        'width' => '640',
        'height' => '480',
        'codebase' => 'https://go.divx.com/plugin/DivXBrowserPlugin.cab',
        'pluginspage' => 'https://go.divx.com/plugin/download/',
        'classid' => 'clsid:67DABFBF-D0AB-41fa-9C46-CC0F21721616',
        'type' => 'video/divx',
        'extraparams' => '<param name="src" value="https://video.stage6.com/$2/.divx" />'
                        .'<param name="custommode" value="Stage6" />'
                        .'<param name="autoplay" value="false" />'
                        .'<param name="showpostplaybackad" value="false" />',
    );
    $embed[] = array(
        'name' => 'Veoh',
        'enabled' => 1,
        'pattern' => 'https://(www\.|)veoh\.com/videos/([0-9a-z]{15})(.*?)',
        'embedlink' => 'https://www.veoh.com/videodetails2.swf?permalinkId=$2&id=anonymous&player=videodetailsembedded&videoAutoPlay=0',
        'width' => '540',
        'height' => '438',
        'extraparams' => '<param name="allow****Screen" value="true">',
    );    
    $embed[] = array(
        'name' => 'Gametrailers',
        'enabled' => 1,
        'pattern' => 'https://(www\.|)gametrailers\.com/player/([0-9]{1,8})\.html(.*?)',
        'embedlink' => 'https://www.gametrailers.com/remote_wrap.php?mid=$2',
        'width' => '480',
        'height' => '392',
        'classid' => 'clsid:d27cdb6e-ae6d-11cf-96b8-444553540000',
        'extraparams' => '<param name="swLiveConnect" value="true"><param name="quality" value="high" />',
    );
    $embed[] = array(
        'name' => 'LiveLeak',
        'enabled' => 1,
        'pattern' => 'https://(www\.|)liveleak\.com/view\?i=([0-9a-z]{3}_|)([a-z0-9]{10})(.*?)',
        'embedlink' => 'https://www.liveleak.com/player.swf?autostart=false&token=$2$3',
        'width' => '450',
        'height' => '370',
        'extraparams' => '<param name="quality" value="high" />',
    );
    $embed[] = array(
        'name' => 'CellFish',
        'enabled' => 1,
        'pattern' => 'https://cellfish\.cellfish\.com/(video|multimedia)/([0-9]{1,8})(.*?)',
        'embedlink' => 'https://cellfish.com/static/swf/player.swf?Id=$2',
        'width' => '420',
 
Geri
Top