GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   embed-play megaporn/youtube/etc videos with your own ads - HACK tutorial (https://gfy.com/showthread.php?t=883549)

SmokeyTheBear 01-23-2009 05:22 PM

embed-play megaporn/youtube/etc videos with your own ads - HACK tutorial
 
Embed or play flash movies from pretty much every site using your own ads in windows media player. All their ads will be disabled.

Windows media player has the ability to play many different files you usually associate with other programs, such as jpg's gif's png's wav's swf and many many others, it can even play websites.

The downside of playing flash in windows media player is any page loading is disabled ( i.e. ads ) controls in flash will still work properly ( play stop pause etc )

The best way to display multiple types of files at once is to create a playlist, this also allows you to place a clickable banner below your videos. Using php we can create a simple dynamic playlist from a template.

save the following file as player.php

SIMPLE VERSION WITH BANNER
Code:

<?php
$x = $_GET['x'];
header('Content-type: video/x-ms-wvx');
?>
<ASX VERSION="3.0">
<ENTRY>
<Banner href="http://bannerurl.com/banner2.gif">
<MoreInfo href = "http://www.linkurl2.com" />
<Abstract>Click Here To Visit</Abstract>
</Banner>
                        <REF HREF="<?php echo $x; ?>" />
                </ENTRY>
       
</ASX>


now to play any video in your new playlist in media player simply link to

yoursite.com/player.php?x=LINK

where link is the link in the SRC of the embed code from the video you are linking to.

for example the following is a sample embed code from youtube

Code:

<object width="425" height="344"><param name="movie" value="https://youtube.com/v/Hsj2MHgG48s&hl=en&fs=1"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="https://youtube.com/v/Hsj2MHgG48s&hl=en&fs=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"></embed></object>
look for where it says embed src= in any embed code ( stop at any blank space " or & )

so for that video the src link would be https://youtube.com/v/Hsj2MHgG48s

so to play that video in your player you would link to

yoursite.com/player.php?x=https://youtube.com/v/Hsj2MHgG48s


here is an example embed code from megaporn
Code:

<object width="640" height="480"><param name="movie" value="http://www.megaporn.com/e/F81T0S3D77307cc99c8acfaee53bead0d61a92f0"></param><param name="allowFullScreen" value="true"></param><embed src="http://www.megaporn.com/e/F81T0S3D77307cc99c8acfaee53bead0d61a92f0" type="application/x-shockwave-flash" allowfullscreen="true" width="640" height="480"></embed></object>
so the src link is http://www.megaporn.com/e/F81T0S3D77307cc99c8acfaee53bead0d61a92f0

so you would link to

yoursite.com/player.php?x=http://www.megaporn.com/e/F81T0S3D77307cc99c8acfaee53bead0d61a92f0



when you link to a video it will open windows media player automatically
or you can embed your dynamic video using the following code.

example code ( pay close attention to how link is set just as above )
[code]
<object width="640" height="480"><param name="movie" value="http://yoursite.com/player.php?x=http://www.megaporn.com/e/F81T0S3D77307cc99c8acfaee53bead0d61a92f0"></param><param name="allowFullScreen" value="true"></param><embed src="http://yoursite.com/player.php?x=http://www.megaporn.com/e/F81T0S3D77307cc99c8acfaee53bead0d61a92f0" type="video/x-ms-wvx" allowfullscreen="true" width="640" height="480"></embed></object>
[code]



heres 2 links to the script in action


( requires windows media player )

YOUTUBE EXAMPLE

MEGAPORN EXAMPLE

Brujah 01-23-2009 05:25 PM

I'd love to see it in action but I'm on a Mac :(

munki 01-23-2009 05:27 PM

I love your hacks...

spacedog 01-23-2009 05:29 PM

the megarotic one still has their dating ad on it with the clickable link, but wow.. what a fucking awesome hack.. great job as usual.

SmokeyTheBear 01-23-2009 05:29 PM

you can also play a picture in your player , complete with banner in windows media player

example
http://ytmnd.webspacemania.com/megap...eams/Emily.jpg

SmokeyTheBear 01-23-2009 05:31 PM

Quote:

Originally Posted by spacedog (Post 15379800)
the megarotic one still has their dating ad on it with the clickable link, but wow.. what a fucking awesome hack.. great job as usual.

cept aff gets no love :( the link wont work heh :)

SmokeyTheBear 01-23-2009 05:52 PM

you can also link to live cam feeds

http://ytmnd.webspacemania.com/megap...omoplay010.swf

IllTestYourGirls 01-23-2009 05:55 PM

dude looks awesome bookmarked this thanks

SmokeyTheBear 01-23-2009 05:58 PM

now i am not suggesting blatantlly ripping people off but you can use this tool for you and them

the last link i posted was for a live cam feed to needlive ( see sig )

you can use this to drive traffic to the sponsor by allowing a surfer to "save" the video , like if you save the link above to your dekstop it saves as a video , surfer can save to his desktop and see a live cam model everyday without even opening his/her browser, if they want to buy minutes they click your banner

try "save as" the following link
http://ytmnd.webspacemania.com/megap...omoplay010.swf

Megaporn has full length videos from sponsors who dont seem to mind , yet these sponsors dont give me the same full length videos to promote them with , so you can link to a megaporn video from nastydollars and link back to the real sponsor with your banner

fris 01-23-2009 05:59 PM

while you are on the subject of megaporn, heres some code to actually download a video from the site

PHP Code:

<?php

function megaporn_decrypt($str_hex$key1$key2){

  
$str_bin "";

  
// 1. Convert hexadecimal string to binary string

  
for($i 0$i 128$i++){
    
$str_bin .= floor(hexdec($str_hex[floor($i/4)])/pow(2,(3-($i%4))))%2;
  }

  
// 2. Generate switch and XOR keys

  
$key = Array();
  for (
$i 0$i 384$i++){
    
$key1 = ($key1 11 77213) % 81371;
    
$key2 = ($key2 17 92717) % 192811;
    
$key[$i] = ($key1 $key2) % 128;
  }

  
// 3. Switch bits positions

  
for ($i 256$i >= 0$i--){
    
$temp $str_bin[$key[$i]];
    
$str_bin[$key[$i]] = $str_bin[$i%128];
    
$str_bin[$i%128] = $temp;
  }

  
// 4. XOR entire binary string

  
for ($i 0$i 128$i++){
    
$str_bin[$i] = $str_bin[$i] ^ $key[$i+256] & 1;
  }

  
// 5. Convert binary string back to hexadecimal

  
$str_hex "";
  for(
$i 0$i 32$i++){
    
$str_hex .= dechex(bindec(substr($str_bin$i*44)));
  }

  
// 6. Return counted string

  
return $str_hex;
}

// Is set the "v" variable?

if (!isset($_GET['v']) or ($_GET['v']=="")) {die("no id set");}
 
else {

   
$megaurl "http://www.megaporn.com/video/?v=".$_GET['v'];

  
//Obtain Megaporn ID from link

   
$id explode("v=",$megaurl);

  
// Does player send video position?

  
$pos = (isset($_GET["pos"]) ? intval($_GET["pos"]) : "");

  
// Obtain Megaporn XML playlist file

  
if ($content file_get_contents("http://www.megaporn.com/video/xml/videolink.php?v=".$id[1])){

    
// Parameters which I want to obtain from XML;

    
$parameters = Array("un""k1""k2""s""size");

    
$success true;

    
// Obtain parameters from XML one by one

    
for($i=0$i<count($parameters); $i++){
      
$success $success && preg_match('/ ' $parameters[$i] . '="([^"]+)"/'$content$match);
      $
$parameters[$i] = $match[1];
    }
    if(
$success){

      
// count "dkey" from obtained parameters

      
$dkey=megaporn_decrypt($un,$k1,$k2);

      
// set URL address of video file

      
$video_url "http://www".$s.".megaporn.com/video/files/".$dkey."/".$pos;

      
// Send headers to browser

      
header("Content-Type: video/flv");
      
header("Content-Disposition: attachment; filename=$id[1].flv;" );
      
header("Content-Length: ".$size);

      
// Read video file from Megaporn server

      
readfile($video_url);

    }
  }
}

?>


SmokeyTheBear 01-23-2009 06:03 PM

p.s. you can "save as " any of the links, even the youtube ones , it saves as a video on your computer , so you dont have to load youtube and your favourites each time , simply save the video , it takes up no space because its simply a shortcut in video form

SmokeyTheBear 01-23-2009 06:07 PM

Quote:

Originally Posted by fris (Post 15379920)
while you are on the subject of megaporn, heres some code to actually download a video from the site

:thumbsup:2 cents:

jollyperv 01-23-2009 06:30 PM

Cool shit, bookmarking this thread :)

IllTestYourGirls 01-23-2009 06:32 PM

just tried it on one of my sites. worked like a charm. thanks a lot!

retardednewbie 01-23-2009 06:34 PM

nice hack buddy..

SmokeyTheBear 01-23-2009 08:07 PM

Quote:

Originally Posted by IllTestYourGirls (Post 15380014)
just tried it on one of my sites. worked like a charm. thanks a lot!

:thumbsup

SomeCreep 01-23-2009 09:12 PM

SmokeyTheBear for President in 2012!

NaughtyRob 01-23-2009 10:02 PM

GFY thread of 2009 so far.

Spunky 01-23-2009 10:03 PM

Smokey knows his shit.nice trick

tiger 01-24-2009 12:10 AM

Hahaha fucking awesome smokey!

quantum-x 01-24-2009 06:13 AM

I'm sure this shit was posted at least last year ago ...

jimmycastor 01-24-2009 07:00 AM

nice hack but it would be perfect if it could disable all megaporn or youtube inscreen features
, im afraid i would promote more megaporn or youtube then anything else

quantum-x 01-24-2009 07:50 AM

Quote:

Originally Posted by jimmycastor (Post 15381518)
nice hack but it would be perfect if it could disable all megaporn or youtube inscreen features
, im afraid i would promote more megaporn or youtube then anything else

er, you can. hotlink the videos.
Not embed, but hotlink.

Smart people have been doing it for years......

seeandsee 01-24-2009 07:56 AM

nice hack, but i have GOM player for all formats to open and won't load in GOM player anything.

SmokeyTheBear 01-24-2009 11:37 AM

Quote:

Originally Posted by quantum-x (Post 15381437)
I'm sure this shit was posted at least last year ago ...

yes i have posted various forms of this for awhile, just figured i would make it dead simple for those using megaporn videos.:thumbsup

SmokeyTheBear 01-24-2009 11:44 AM

Quote:

Originally Posted by quantum-x (Post 15381626)
er, you can. hotlink the videos.
Not embed, but hotlink.

Smart people have been doing it for years......

you can but its a little harder to do on the fly like that and requires communication between your server and megaporn server ( i.e. they can/will ban your ip ) and the way of obtaining the video may change at some point whereas this shouldnt change unless they change their embed code. And it requires a bit more "know how". This is just kinda a simple way for everyone :)

Oracle Porn 01-24-2009 11:58 AM

opens wmp on all urls for me

SmokeyTheBear 01-24-2009 12:01 PM

Quote:

Originally Posted by Oracle Porn (Post 15382237)
opens wmp on all urls for me

its supposed to do that . Or did you mean you were just confirming it did

Konda 01-24-2009 12:23 PM

Does it only work with WMP 10 or higher?
I have WMP 9 here on a PC and it doesn't work. (Just keeps replaying the big banner with arrows to the small banner, but not the actual video)

quantum-x 01-24-2009 01:17 PM

Quote:

Originally Posted by SmokeyTheBear (Post 15382196)
you can but its a little harder to do on the fly like that and requires communication between your server and megaporn server ( i.e. they can/will ban your ip ) and the way of obtaining the video may change at some point whereas this shouldnt change unless they change their embed code. And it requires a bit more "know how". This is just kinda a simple way for everyone :)

I'd never seen them ban IPs / URLs before, but yeah.
Especially since they started getting serious with encrypting their players.

alias 01-24-2009 01:50 PM

Great thread & hack Smokey!


All times are GMT -7. The time now is 03:20 PM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc