Viewing file: install_yt.php (5.38 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
/********************************************************************************
- MemHT Portal -
Copyright (C) 2007-2008 by Miltenovik Manojlo
http://www.memht.com
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your opinion) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License along
with this program; if not, see <http://www.gnu.org/licenses/> (GPLv2)
or write to the Free Software Foundation, Inc., 51 Franklin Street,
Fifth Floor, Boston, MA02110-1301, USA.
********************************************************************************/
//======================================================================
// MemHT YouTube
//======================================================================
//===========================================
//Database: Connect
//===========================================
require_once("inc/inc_config.php");
require_once("inc/inc_database.php");
$dblink = new database();
$dblink->connect();
require_once("inc/inc_functions.php");
require_once("inc/inc_login.php");
if (isAdmin($admin)) {
$dblink->query("CREATE TABLE `memht_youtube_config` (
`key` varchar(255) collate latin1_general_ci NOT NULL,
`value` text collate latin1_general_ci NOT NULL,
UNIQUE KEY `key` (`key`)
) ENGINE=MyISAM");
$dblink->query("CREATE TABLE `memht_youtube_tags` (
`tag` varchar(255) NOT NULL,
`cid` int(10) NOT NULL
) ENGINE=MyISAM");
$dblink->query("CREATE TABLE `memht_youtube_videos` (
`id` int(10) NOT NULL auto_increment,
`title` varchar(255) collate latin1_general_ci NOT NULL,
`description` text collate latin1_general_ci NOT NULL,
`date` datetime NOT NULL,
`videoid` varchar(255) collate latin1_general_ci NOT NULL,
`width` int(3) NOT NULL,
`height` int(3) NOT NULL,
`hits` int(10) NOT NULL,
`author` varchar(255) collate latin1_general_ci NOT NULL,
`enabled` int(1) NOT NULL default '0',
PRIMARY KEY (`id`)
) ENGINE=MyISAM");
$dblink->query("INSERT INTO `memht_youtube_config` (`key`, `value`) VALUES
('thumbnail', 'http://i.ytimg.com/vi/{{VIDEOID}}/default.jpg'),
('width', '425'),
('height', '355'),
('code', '<object width=\"{{W}}\" height=\"{{H}}\"><param name=\"movie\" value=\"http://www.youtube.com/v/{{VIDEOID}}\"></param><param name=\"wmode\" value=\"transparent\"></param><embed src=\"http://www.youtube.com/v/{{VIDEOID}}\" type=\"application/x-shockwave-flash\" wmode=\"transparent\" width=\"{{W}}\" height=\"{{H}}\"></embed></object>')");
$dblink->query("INSERT INTO `memht_youtube_videos` (`id`, `title`, `description`, `date`, `videoid`, `width`, `height`, `hits`, `author`, `enabled`) VALUES
(1, 'the Trons', '<span>The Trons practicing &quot;Sister Robot&quot; before their fringe gigs! </span>', '2008-06-27 19:52:34', 'c2JChnwv2Ws', 0, 0, 0, 'root', 1),
(2, 'Where the Hell is Matt??', '<span>14 months in the making, 42 countries, and a cast of thousands. Thanks to everyone who danced with me.<br />\r\nMake sure to click &quot;watch in high quality&quot; right underneath the video.</span>', '2008-06-27 19:54:29', 'zlfKdbWwruY', 0, 0, 0, 'root', 1),
(3, 'Spain - Russia', '', '2008-06-27 19:55:21', '7ZupJ0NpaF4', 0, 0, 0, 'root', 1),
(4, 'The Shures - Uh Oh!', '<span>Here is an original from us lot! It's currently in a competition on Clipstar.com and we are in 3rd place in the band or group section!!!!</span>', '2008-06-27 19:56:06', '__vwRSQfA6Q', 0, 0, 0, 'root', 1),
(5, 'Sing A Long', '<span>Most testicular cancers are found by men themselves. Also, doctors should examine the testicles during routine physical exams. Between regular checkups, if a man notices anything unusual about his testicles, he should talk with his doctor. </span>', '2008-06-27 19:56:47', 'r_nK1CEo5ho', 0, 0, 0, 'root', 1),
(6, 'Everyman - Rachel Stevens', '<span>Video promotion by a s3x symbol. Is it p0rn? Not exactly but it is equally interesting. Rachel Stevens teaching you t3sticular examination in bed.</span>', '2008-06-27 19:58:02', 'zdQppbPNVKY', 0, 0, 0, 'root', 1),
(7, 'Classic Barney Sing-Along', '<span>I have remade the Classic Barney Sing-Along. I left out some of my favorite classic Barney songs in the last one, so I added a lot more to this one. Enjoy!</span>', '2008-06-27 19:59:22', 'U-tVgfIK_wQ', 0, 0, 0, 'root', 1)");
$dblink->query("INSERT INTO `memht_pagine` (nome,titolo,fullscreen,rank,enabled) VALUES ('youtube','YouTube','1','0','1')");
echo "<b>Finished!</b><br><font color='#990000'>Do not forget to delete the install file!</font>";
} else {
die("<b>Access Denied!</b><br>You must be logged as administrator to execute this file");
}
//===========================================
//Database: Disconnect
//===========================================
$dblink->disconnect();
?>
|