Bravo List
Register
Go Back   > Bravo List > Source Code > Archived Trackers > TBDev
Reply
  #1  
Old 20th August 2013, 14:28
firefly007's Avatar
firefly007 firefly007 is offline
SUPPORT GURU
 
Join Date: Jun 2010
P2P
Posts: 721
Default Youtube mod - firefly007
This will work on IE

1) Run Sql

PHP Code:

CREATE TABLE 
IF NOT EXISTS `youtube` (
  `
idint(11NOT NULL AUTO_INCREMENT,
  `
uidint(10NOT NULL,
  `
unamevarchar(255CHARACTER SET latin1 COLLATE latin1_general_ci NOT NULL,
  `
namevarchar(255CHARACTER SET latin1 COLLATE latin1_general_ci NOT NULL,
  `
linkvarchar(255CHARACTER SET latin1 COLLATE latin1_general_ci NOT NULL,
  `
dtdatetime NOT NULL,
  
PRIMARY KEY (`id`)
ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=
2) If you don't have this function then save this to your bittorrent.php


PHP Code:

function sanitize($data) {
 
    
$data trim($data);
    if(
get_magic_quotes_gpc())
        
$data stripslashes($data);
    if(
is_numeric($data) && preg_match('/\./'$data))
        
$data floatval($data);
    elseif(
is_numeric($data))
        
$data intval($data);
    else
        
$data mysql_real_escape_string($data);
 
    return 
$data;

3) Create a file called browse_you.php and save the below code.

PHP Code:

<?
include "include/bittorrent.php";
dbconn();
loggedinorreturn();
stdhead();

//Created by firefly//

$res mysql_query("SELECT id, uid, name, link FROM youtube ORDER BY id") or sqlerr(__FILE____LINE__);

echo 
"<table bgcolor='#0E0E0C' width='800' border='0'>
<tr>
<th bgcolor='#03233d'><div class='col'>Name&nbsp;<a href='/youtube_add.php'><strong>[Add]</strong></a></div></th>
<th  class='col' bgcolor='#03233d'>Del</th>
<th  class='col' bgcolor='#03233d'>Edit</th>
</tr>"
;

while (
$row mysql_fetch_array($res)) {

    
$place "Viewing <strong><a href='/browse_tv.php'>Youtube listings</a></strong>";

    echo 
"<tr>";
    echo 
"<td width='700'>&nbsp;&nbsp;&nbsp;<a href='/details_you.php?id=" $row['id'] . "'class='btv'>" $row['name'] . "</a></td>";
    if (
$row["uid"] == $CURUSER["id"] || get_user_class() >= UC_OWNER) {
        echo 
"<td width='10px'><center><a href='del_you.php?id=" $row["id"] . "'><img src='pic/drop.png' alt='Download'></a></center></td>";
    } else {
        echo 
"<td></td>";
    }
    if (
$rowl["uid"] == $CURUSER["id"] || get_user_class() >= UC_OWNER) {
        echo 
"<td width='10px'><center><a href='edit_you.php?id=" $row["id"] . "'><img src='http://icons.iconarchive.com/icons/custom-icon-design/pretty-office-10/16/Pencil-icon.png' alt='Download'></a></center></td>";

    } else {
        echo 
"<td></td>";
    }
    echo 
"</tr>";
}
echo 
"</table>";

stdfoot();
4) Create a file called details_you.php and save this.

PHP Code:

<?
include "include/bittorrent.php";
dbconn(true);
loggedinorreturn();

//Created by firefly//

$ids sanitize($_GET['id']);
if (empty(
$_GET['id']))
    die(
'No ID');
$res mysql_query("SELECT id, name, link FROM youtube WHERE id='$ids'") or sqlerr(__FILE____LINE__);



function 
get_youtube_embed($youtube_video_id$autoplay false) {
    
$embed_code "";

    if (
$autoplay)
        
$embed_code '
        <embed src="http://www.youtube.com/v/' 
$youtube_video_id '&rel=1&autoplay=1" pluginspage="http://adobe.com/go/getflashplayer" type="application/x-shockwave-flash" quality="high" width="640" height="480" bgcolor="#ffffff" loop="false"></embed>
        '
;
    else
        
$embed_code '
        <embed src="http://www.youtube.com/v/' 
$youtube_video_id '&rel=1" pluginspage="http://adobe.com/go/getflashplayer" type="application/x-shockwave-flash" quality="high" width="640" height="480" bgcolor="#ffffff" loop="false"></embed>
        '
;
    return 
$embed_code;
}

while (
$row mysql_fetch_assoc($res))

$you get_youtube_embed($row["link"], true);

stdhead();

$d '<table width="600" cellpadding="4" cellspacing="4" bgcolor="#121212">
<tr><td>' 
$you '</td></tr><tr></table>';

print(
"&nbsp;||&nbsp;<a href='/browse_you.php'><strong>Browse Youtube</strong></a>&nbsp;||&nbsp;");
print(
"&nbsp;||&nbsp;<a href='/youtube_add.php'><strong>Add Clip</strong></a>&nbsp;||&nbsp;");

print(
$d);
$resl mysql_query("SELECT * FROM youtube ORDER BY dt") or sqlerr(__FILE____LINE__);

echo 
"<table width='640'>";
echo 
"<tr>";
echo 
"<th bgcolor='#011327'>Name</th>";
echo 
"<th bgcolor='#011327'>added</th>";
echo 
"<th bgcolor='#011327'>User</th>";
echo 
"<th bgcolor='#011327'>Del</th>";
echo 
"<th bgcolor='#011327'>Edit</th>";
echo 
"<th bgcolor='#011327'>Play</th>";

echo 
"</tr>";

while (
$rowl mysql_fetch_array($resl)) {
    
    
$todaydate date('Y-m-d H:i:s');
$ago strtotime($todaydate) - strtotime(($rowl["dt"]));
if (
$ago >= 86400) {$diff floor($ago/86400).'<font color="#0f87cc"> days ago</font>';
}elseif(
$ago >= 3600) {
$diff floor($ago/3600).'<font color="#d4470f"> hours ago</font>';
}elseif (
$ago >= 60) {
$diff floor($ago/60).'<font color="#0fd455"> mins ago</font>';
}else {
$diff =  $ago.'<font color="#4e063e"> secs ago</font>';}

    
    echo 
"<tr>";
    echo 
"<td width='540px'>" $rowl['name'] . "</td>";
    echo 
"<td width='90px'>" $diff "</td>";
    echo 
"<td width='40px'>" $rowl['uname'] . "</td>";
    if (
$rowl["uid"] == $CURUSER["id"] || get_user_class() >= UC_OWNER) {
        echo 
"<td width='10px'><center><a href='del_you.php?id=" $rowl["id"] . "'><img src='pic/drop.png' alt='Download'></a></center></td>";
    } else {
        echo 
"<td></td>";
    }
    if (
$rowl["uid"] == $CURUSER["id"] || get_user_class() >= UC_OWNER) {
        echo 
"<td width='10px'><center><a href='edit_you.php?id=" $rowl["id"] . "'><img src='http://icons.iconarchive.com/icons/custom-icon-design/pretty-office-10/16/Pencil-icon.png' alt='Download'></a></center></td>";

    } else {
       echo 
"<td></td>";
    }
    echo 
"<td width='10px'><center><a href='details_you.php?id=" $rowl["id"] . "'><img src='http://icons.iconarchive.com/icons/double-j-design/ravenna-3d/16/Play-icon.png' alt='Download'></a></center></td>";
    echo 
"</tr>";
}
echo 
"</table>";

stdfoot();
5) Create a file called youtube_add and paste this..


PHP Code:

<?php
include "include/bittorrent.php";
dbconn();
loggedinorreturn();

//Created by firefly//

stdhead();


$form '<lable><h1><center>Add Youtube to DB.</center></h1></lable>
<form action="take_you.php" method="post">
<table width="801" cellpadding="4" cellspacing="4">
<tr>
<td width="50"><strong>Name:</strong></td>
<td width="600"><input name="name" type="text" size="50">&nbsp;&nbsp;<strong>Add the name </strong></td>
</tr>
<tr>
<td width="50"><strong>Link:</strong></td>
<td><input type="text" name="link" size="20">&nbsp;&nbsp;<strong>Add only code</strong> (xRXIwvHzIbk)</td>
</tr>
</table>
<input name="Submit" type="submit" value="Enter!">
</body>
</html>'
;

print (
$form);

stdfoot();
6) Create a file called take_you.php and paste this.

PHP Code:

<?
include "include/bittorrent.php";
dbconn();
loggedinorreturn();

//Created by firefly//

if (empty($_POST['name']))die('Empty name!');
if (empty(
$_POST['link']))die('Empty link!');

$res "SELECT name FROM youtube WHERE name = '" sanitize($_POST['name']) . "'";
$duplicate mysql_query($res);
if (
mysql_num_rows($duplicate) > 0) {
    
$count_duplicate++;
} else {
    
$uid $CURUSER['id']; $unam $CURUSER['username']; $en sanitize($_POST['name']);$link sanitize($_POST['link']); $todaydate date('Y-m-d H:i:s');
    
mysql_query("INSERT INTO youtube (uid, uname, name, link, dt)VALUES ('$uid', '$unam', '$en', '$link', '$todaydate')") or sqlerr(__FILE____LINE__);
}

$url "browse_you.php";
$time_out 1;
header("refresh: $time_out; url=$url");

stdfoot();
7) Create a file called edit_you.php and save this..

PHP Code:

<?
require_once("include/bittorrent.php");
dbconn();

//Created by firefly//

?>
<style type="text/css">

.txte {height: 350px;width: 600px;}
.tv {width: 300px;}

</style>
<?

if (empty($_GET['id']))die('No ID');
$idsp sanitize($_GET['id']);
$res mysql_query ("SELECT id, uid, name, link FROM youtube WHERE id='$idsp'")or die(mysql_error());;

$row mysql_fetch_assoc($res);
if (
$row["uid"] == $CURUSER["id"] || get_user_class() >= UC_OWNER){  

$name $row["name"];
$link =  $row["link"];

stdhead();


$outtab ="<form action='takeyouedit.php?id=$idsp' method='post'>
<table width='950' cellpadding='4' cellspacing='4'>
  <tr>
    <td width='50'>Name:</td>
    <td width='950'><input name='name' type='text' class='tv' value='
$name'>&nbsp;&nbsp;<strong>Add the name</td>
  </tr>
  <tr>
    <td>Poster:</td>
    <td><input type='text' name='link' class='tv' value='
$link'>&nbsp;&nbsp;<strong>Add code only.</strong></td>
    </tr>

</table>
<input type='submit'>
</form>"
;

print 
$outtab;
}else {
?><META HTTP-EQUIV=REFRESH CONTENT="1; URL=/browse_you.php">
<? exit('You do not own this clip.');    

}
8) Created a file called takeyouedit.php and paste.


PHP Code:

<?
include "include/bittorrent.php";
dbconn();
loggedinorreturn();

//Created by firefly//

if (empty($_GET['id']))die('No ID');
if (empty(
$_POST['name']))die('Empty Name!');
if (empty(
$_POST['link']))die('Empty link!');
$en sanitize($_POST['name']);$link sanitize($_POST['link']);$idsp sanitize($_GET["id"]);
mysql_query("UPDATE youtube SET name =  '$en' WHERE id= '" $idsp "'") OR sqlerr__FILE____LINE__ );
mysql_query("UPDATE youtube SET link =  '$link' WHERE id= '" $idsp "'") OR sqlerr__FILE____LINE__ );
    

header("location: browse_you.php");
stdfoot();
?>
9) Create a file called del_you.php and copy

PHP Code:


<?
require_once("include/bittorrent.php"); 
dbconn(false); 

//Created by firefly//

if (empty($_GET['id']))die('No ID');
$id sanitize($_GET['id']);
$resl mysql_query("SELECT id, uid, name, link FROM youtube") or sqlerr(__FILE____LINE__);
while (
$rowl mysql_fetch_array($resl)) 

if (
$rowl["uid"] == $CURUSER["id"] || get_user_class() >= UC_OWNER){  

 
mysql_query("DELETE FROM youtube WHERE id='$id'");
?><META HTTP-EQUIV=REFRESH CONTENT="0; URL=/browse_you.php"><?
}else {    
?><META HTTP-EQUIV=REFRESH CONTENT="1; URL=/browse_you.php">
<? exit('You do not own this clip');    
}
Attached Thumbnails
Untitled-1.jpg  
__________________




Please Support Majority Report


You can contact me on Skype live:phesadent.elect but please let me know first.


If you are ever need me desperately then please email me at dan.oak44@gmail.com and I will contact u within a week.


Due to free time I'm able to help interested member's with their tracker.

Please Note!
Depending on your requests I will charge you for my assistance for Tracker installs and mods.
All my mods are custom and prices will very depending on the request.
I'm able to install any tracker and mods including themes.

Please PM me


Last edited by firefly007; 20th August 2013 at 16:17.
Reply With Quote
The Following 4 Users Say Thank You to firefly007 For This Useful Post:
Bobert (17th September 2013), Chez (20th August 2013), Fynnon (20th August 2013), nicukent (26th May 2023)
  #2  
Old 20th August 2013, 16:11
SYLEHD SYLEHD is offline
Member
 
Join Date: Jun 2012
P2P
Posts: 8
Default blank
video not start to play.is page white [table show]

but why?

i folow the steps
Reply With Quote
  #3  
Old 20th August 2013, 16:26
firefly007's Avatar
firefly007 firefly007 is offline
SUPPORT GURU
 
Join Date: Jun 2010
P2P
Posts: 721
Default
Quote:
Originally Posted by SYLEHD View Post
video not start to play.is page white [table show]

but why?

i folow the steps
You need to add only the end code

eg.

Code:
youtube.com/watch?v=xRXIwvHzIbk
So you add xRXIwvHzIbk

Also browse.you.php must be browse_you.php its a little type 0
__________________




Please Support Majority Report


You can contact me on Skype live:phesadent.elect but please let me know first.


If you are ever need me desperately then please email me at dan.oak44@gmail.com and I will contact u within a week.


Due to free time I'm able to help interested member's with their tracker.

Please Note!
Depending on your requests I will charge you for my assistance for Tracker installs and mods.
All my mods are custom and prices will very depending on the request.
I'm able to install any tracker and mods including themes.

Please PM me

Reply With Quote
  #4  
Old 20th August 2013, 19:45
SYLEHD SYLEHD is offline
Member
 
Join Date: Jun 2012
P2P
Posts: 8
Default
Quote:
Originally Posted by firefly007 View Post
You need to add only the end code

eg.

Code:
youtube.com/watch?v=xRXIwvHzIbk
So you add xRXIwvHzIbk

Also browse.you.php must be browse_you.php its a little type 0
yes you right /my bad sorry
Reply With Quote
  #5  
Old 29th August 2013, 11:29
j4v1 j4v1 is offline
Member
 
Join Date: Jul 2012
P2P
Posts: 6
Default
niceeeee, good work

only works on IE?
Reply With Quote
  #6  
Old 29th August 2013, 15:28
firefly007's Avatar
firefly007 firefly007 is offline
SUPPORT GURU
 
Join Date: Jun 2010
P2P
Posts: 721
Default
No it will work with IE, Chrome and FF and properly work with others too.
__________________




Please Support Majority Report


You can contact me on Skype live:phesadent.elect but please let me know first.


If you are ever need me desperately then please email me at dan.oak44@gmail.com and I will contact u within a week.


Due to free time I'm able to help interested member's with their tracker.

Please Note!
Depending on your requests I will charge you for my assistance for Tracker installs and mods.
All my mods are custom and prices will very depending on the request.
I'm able to install any tracker and mods including themes.

Please PM me

Reply With Quote
  #7  
Old 10th October 2013, 12:15
Marco Marco is offline
Senior Member
 
Join Date: Jun 2009
Seychelles
Posts: 327
Default
you can add autoplay too :D
Reply With Quote
Reply

Tags
firefly007 , mod , youtube

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT +2. The time now is 00:04. vBulletin skin by ForumMonkeys. Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2024, vBulletin Solutions Inc.