1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. This forum has been archived. New threads and replies may not be made. All add-ons/resources that are active should be migrated to the Resource Manager. See this thread for more information.

[Add More Video Sites] BB Code Media

Discussion in 'Tips and Guides [Archive]' started by D.O.A., Nov 4, 2010.

  1. EQnoble

    EQnoble Equilux Nobiliterà

    3 left to fix..found a couple small annoyances with 2 of them and am going to fix them...the other one...the site was down for maintenance or something so I will try in a lil bit. Expect an update to the package by the time you wake up unless for some reason these bugs whoop me.
  2. EQnoble

    EQnoble Equilux Nobiliterà

    update

    there is only one left to check/fix:
    http://tv.majorleaguegaming.com/

    ...but the site itself seems to be having troubles...most of the urls are going nowhere so either they are updating their whole url scheme or something bad happened over there....i would lean toward an update to the site though...if I fall asleep and don't post again in this thread it still needs to be checked or fixed.



    All other codes work, have been updated to not interfere with moderation duties, and are safe to use as far as my tests show.
    Rudy and Fuhrmann like this.
  3. Rudy

    Rudy Well-Known Member

    Fantastic work--thanks much! I'll be updating within the hour.
  4. Frankie

    Frankie Member

    BBcode for mma-tube anyone? plz
  5. EQnoble

    EQnoble Equilux Nobiliterà

    Sure...it's on the list a couple pages back...gotta give me a lil time to try it..I have a couple days of catching up to do here.
  6. Cujo

    Cujo Member

  7. EQnoble

    EQnoble Equilux Nobiliterà

    They don't host their own videos and every video has a different possible host...youtube yahoo etc...i looked at two and that's what I saw already...

    For me it makes no sense to do it when they are embedding videos from elsewhere...no sense in cataloging videos from someone who cataloged them from someone else in my opinion. To get the embed code out of each video when each can have a unique setup would take more work than it is worth. You can get to the original video from the embed most of the time (at whatever site you are viewing it at and most of the sites that twitch uses are already defined in this thread.)
  8. Cujo

    Cujo Member

    Yes they do embed video's from other sites, but they also do their own uploads, which is to http://www.indieclicktv.com/. I suppose that is the one I'm really after ;)
  9. EQnoble

    EQnoble Equilux Nobiliterà

    Update for MLG mediasite - from this post






    Media Site ID: mlgtv
    ________________________________________
    Site Title: MLG TV
    ________________________________________
    Site URL: http://tv.majorleaguegaming.com/
    ________________________________________
    Match URLs: #majorleaguegaming\.com/(videos|shows|events)/(?P<id>[a-z0-9-_.]+)#i
    ________________________________________
    Embed HTML:
    HTML:
    <none>
    ________________________________________

    ____advanced options___________________________
    Regular Expression Matching: Use 'Match URLs' as PCRE regular expressions [ Checked ]
    ________________________________________
    Embed HTML Callback: MediaSites_MLG::buildEmbed



    MLG.php (for display only, download the file here).
    PHP:
    <?php
     
    class MediaSites_MLG
    {
        public static function 
    buildEmbed($mediaKey, array $site)
        {
            
    $pageHtml file_get_contents('http://tv.majorleaguegaming.com/oembed.json?url=http://tv.majorleaguegaming.com/videos/' $mediaKey);
     
            
    $pageHtml json_decode($pageHtml,true);
             
            
    $string strval($pageHtml['html']);
     
            
    $wmodeplus '<embed wmode="opaque" ';
     
            
    preg_match('#(?P<mtawmode>\<embed)#si'$string$matches);
     
            
    $finalHtml str_replace($matches['mtawmode'], $wmodeplus$string);
     
            return 
    $finalHtml;
        }
    }

    Attached Files:

    • MLG.zip
      File size:
      462 bytes
      Views:
      2
  10. Frankie

    Frankie Member

  11. EQnoble

    EQnoble Equilux Nobiliterà

    I won't personally use it because it throws popups on whatever page it is embedded on ...but here yah go

    Media Site ID: putlocker
    ________________________________________
    Site Title: Putlocker
    ________________________________________
    Site URL: http://www.putlocker.com/
    ________________________________________
    Match URLs: #putlocker\.com/file/(?P<id>[a-z0-9]+)#si
    ________________________________________
    Embed HTML:
    HTML:
    <iframe src="http://www.putlocker.com/embed/{$id}" width="600" height="360" frameborder="0" scrolling="no"></iframe>
    ________________________________________

    ____advanced options___________________________
    Regular Expression Matching: Use 'Match URLs' as PCRE regular expressions [ Checked ]
    ________________________________________
    Frankie likes this.
  12. Frankie

    Frankie Member

  13. jgas

    jgas Active Member

  14. EQnoble

    EQnoble Equilux Nobiliterà

    I mean..I would need an example link of some sorts to work with ... maybe I will do one for this...hmm

    anyways if you have or want to download King Kovifors BBCM , you can download this custom bbcode and that should work for you.

    I suppose it is very possible to make an auto embedding bbcode media site that will catch any link ending in a valid audio file extension...I dunno ... I will mull it over.
  15. Mutt

    Mutt Well-Known Member

    I was NOT able to get yours to work. I have no idea why but it had the exact same problem mine did. Maybe it's some security measure porn hub enabled. I was however able to get it to work using curl. attached is the new PornHub.php file & settings


    Media Site ID: pornhub

    Site Title: PornHub

    Site URL:
    Code:
    http://www.pornhub.com/
    Match URLs:
    Code:
    http://www.pornhub.com/view_video.php?viewkey={$id}
    Embed HTML:
    Code:
    <!--see callback-->
    Then under Advanced Options:

    Embed HTML Callback: MediaSites_PornHub::buildEmbed

    And you need to create the following directory/file:

    library/MediaSites/PornHub.php

    ----------------------

    while I'm at it, here's Tube8

    Media Site ID: tube8

    Site Title: Tube8

    Site URL:
    Code:
    http://www.tube8.com/
    Match URLs:
    Code:
    #tube8.com/(?P<id>([a-z0-9-_]+/[a-z0-9-_]+/[0-9-_]+))#si
    Embed HTML:
    Code:
    <!--see callback-->
    Then under Advanced Options:

    Under Regular Expression Matching: check the "Use 'Match URLs' as PCRE regular expressions" box

    Embed HTML Callback: MediaSites_Tube8::buildEmbed

    And you need to create the following directory/file:

    library/MediaSites/Tube8.php

    Attached Files:

  16. Jake Bunce

    Jake Bunce Probably knows the answer Staff Member

    When I first made that BB code for some one via PM it didn't work for me either. But it worked for the person I made it for so I assumed it was some problem on my end.
  17. Jake Bunce

    Jake Bunce Probably knows the answer Staff Member

    Freevlog...

    Admin CP -> Home -> BB Code Media Sites -> Add BB Code Media Site

    Media Site ID: freevlog

    Site Title: Freevlog

    Site URL: http://www.freevlog.hu/

    Match URLs: http://www.freevlog.hu/video/{$id}.html

    Embed HTML:

    Code:
    <see html callback>
    
    Then under Advanced Options:

    Embed HTML Callback: MediaSites_Freevlog::buildEmbed

    And you need to create the following directory/file (also attached to this post):

    library/MediaSites/Freevlog.php

    Code:
    <?php
    
    class MediaSites_Freevlog
    {
    	public static function buildEmbed($mediaKey, array $site)
    	{
    		// CAPTURE WEB PAGE
    		$pageHtml = file_get_contents('http://www.freevlog.hu/video/' . $mediaKey . '.html');
    
    		// ISOLATE THE EMBED CODE IN THE SOURCE
    		if(preg_match('/<div><input type="text" style="width: 290px;" onClick="this\.select\(\)" onFocus="this\.select\(\)" readonly="true" value="(?P<embedhtml>[^"]+)" ><\/div>/siU', $pageHtml, $match))
    		{
    			// IT HAS HTML ENTITIES, UNDO THAT
    			$match['embedhtml'] = htmlspecialchars_decode($match['embedhtml']);
    
    			// FROM EMBED CODE, ISOLATE THE ID
    			if(preg_match('#<param name="movie" value="http://www.freevlog.hu/v3/(?P<videoid>[^"]+)" />#si', $match['embedhtml'], $info))
    			{
    				// DEFINE GENERIC EMBED HTML WITH REPLACEMENT VARIABLE __VIDEOID__
    				$embedHtml = '<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=10,0,0,0" width="480" height="305" id="vidixplayer" align="middle"><param name="allowScriptAccess" value="sameDomain" /><param name="allowFullScreen" value="true" /><param name="movie" value="http://www.freevlog.hu/v3/__VIDEOID__" /><param name="wmode" value="window" /><param name="menu" value="false" /><param name="quality" value="high" /><param name="bgcolor" value="#000000" /><embed src="http://www.freevlog.hu/v3/__VIDEOID__" menu="false" quality="high" bgcolor="#000000" width="480" height="305" name="vidixplayer" align="middle" wmode="window" allowFullScreen="true" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" /></object>';
    
    				// MAKE THE REPLACEMENTS
    				$finalHtml = str_replace('__VIDEOID__', $info['videoid'], $embedHtml);
    
    				// RETURN THE FINISHED HTML
    				return $finalHtml;
    			}
    		}
    
    		// RETURN NOTHING IF NO MATCH
    		return '';
    	}
    }
    
    URLs tested:
    http://www.freevlog.hu/video/12437.html
    http://www.freevlog.hu/video/11427.html

    Attached Files:

  18. EQnoble

    EQnoble Equilux Nobiliterà

    Ok so I am just getting the last thing done with this and would like people to test it, (twitter users that want to test the retweet and follow functions)...



    http://xenxero.com/twitter/?tweeter=xenforo
    http://xenxero.com/twitter/?tweeter=twitter

    please test as many users as you can...
    http://xenxero.com/twitter/?tweeter={AnyTwitterUserID}


    For those liking the way normal twitter embeds look I also already have the styling done to exactly copy that look but that wasn't the purpose of my test here though if released I will include that styling as well wrapped up in a separate package.

    I will not be using the twitter widget.js to transform the data into tweets because it does something funny that I am not going to waste any more time trying to fix myself. Since I am converting them into their final output with my own code I also have the ability to make it look exactly the same as the original so don't sweat that.

    Please report anything non functioning, or looking askew as well as your opinions and preferences. I don't really need to release this as a bbcode if no one is going to use it so if you want it, speak up otherwise I will only be adding it in an addon for a single specific reason that has nothing to do with media site bbcodes.

    If you don't want to post your feedback publicly feel free to start a convo, even if it is to say I hate it just be able to tell me why and I will have no problem with your honest opinion.
  19. DRE

    DRE Previously 8thos

    I
    I'll experiment for ya.
    EQnoble likes this.
  20. Coop1979

    Coop1979 Well-Known Member

    Does anyone know how to convert eBay links into the rover.ebay links so that they include affiliate IDs? I have an add-on for vBulletin that does this if it will help anyone figure out how to do it for XF.

Share This Page