Example #1
0
function wp_embed_handler_volrac($matches, $attr, $url, $rawattr)
{
    $options = get_option('volrac_tube_embedder_options');
    $default_width = isset($options['default_width']) ? $options['default_width'] : 720;
    $default_height = isset($options['default_height']) ? $options['default_height'] : 480;
    $url = $matches[0];
    $width = isset($rawattr['width']) ? $rawattr['width'] : $default_width;
    $height = isset($rawattr['height']) ? $rawattr['height'] : $default_height;
    $embedder = new Embedder();
    $embed_code = $embedder->getCode($url, $width, $height);
    if ($embed_code == false) {
        return $url;
    }
    return apply_filters('embed_volrac', $embed_code, $matches, $attr, $url, $rawattr);
}
Example #2
0
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe scrolling="no" width="960" height="540" src="http://www.p**n.com/videos/embed/1747565" frameborder="0"></iframe>');
 }
Example #3
0
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe src="http://embed.h2porn.com/greatest-25-celebrity-blowjobs/" width="960" height="540"></iframe>');
 }
Example #4
0
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe src="http://www.tube8.com/embed/amateur/girlfriend-f****d-in-school-skirts/26411221/" frameborder="0" height="540" width="960" scrolling="no" name="t8_embed_video"></iframe>');
 }
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe width="960" height="540" src="http://www.porntube.com/embed/7125350" frameborder="0" allowfullscreen></iframe>');
 }
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe src="http://www.keezmovies.com/embed/french-booty-pornstar-liza-del-sierra-masturbates-1114436" frameborder="0" height="540" width="960" scrolling="no" name="keezmovies_embed_video"></iframe>');
 }
Example #7
0
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe src="http://embeds.sunporno.com/embed/918375" frameborder="0" width="960" height="540" scrolling="no"></iframe>');
 }
Example #8
0
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe src="http://www.spankwire.com/EmbedPlayer.aspx?ArticleId=1942021" frameborder="0" height="540" width="960" scrolling="no" name="spankwire_embed_video"></iframe>');
 }
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe frameborder="0" width="960" height="540" src="//www.dailymotion.com/embed/video/x1bexc8" allowfullscreen></iframe>');
 }
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe width="960" height="540" src="http://xhamster.com/xembed.php?video=5064394" frameborder="0" scrolling="no" allowfullscreen></iframe>');
 }
Example #11
0
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe src="http://embed.redtube.com/?id=996128" frameborder="0" width="960" height="540" scrolling="no" allowfullscreen></iframe>');
 }
Example #12
0
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe src="http://www.youporn.com/embed/10114077/b*****b-petite-brunette-sucks-c**k-of-a-stranger-for-cash/" frameborder=0 height="540" width="960" scrolling=no name="yp_embed_video"></iframe>');
 }
Example #13
0
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe width="960" height="540" src="http://www.wetplace.com/embed/51832" frameborder="0" allowfullscreen webkitallowfullscreen mozallowfullscreen oallowfullscreen msallowfullscreen></iframe>');
 }
Example #14
0
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe src="http://www.yobt.com/embed/888423.html" width="960" height="540" scrolling="no" frameborder="0" allowtransparency="true" marginheight="0" marginwidth="0"></iframe>');
 }
Example #15
0
 public function testIfCorrectEmedCodeIsReturned()
 {
     $embed = new Embedder();
     $code = $embed->getCode($this->url, 960, 540);
     $this->assertEquals($code, '<iframe src="http://flashservice.xvideos.com/embedframe/7828239" frameborder=0 width=960 height=540 scrolling=no></iframe>');
 }