/**************************************************************************************************
|
| VideoWatch Professional - Video Sharing Script
| http://www.videowatchpro.com
| videowatchopro@gmail.com
| Version: 1.3
|
|**************************************************************************************************
|
| By using this software you agree that you have read and acknowledged our End-User License 
| Agreement available at http://www.videowatchpro.com/eula.html and to be bound by it.
|
| Copyright (c) 2008 VideoWatchPro.com. All rights reserved.
|**************************************************************************************************/

Upgrade Instructions - v1.2.8 to v1.3.0

1. Delete the following: 
- images/bookmarks/ (and everything inside)
- css/style2.css


2. Upload these new files:
- include/lang/english.php
- include/lang/spanish.php
- css/style2.php
- images/en.png
- images/es.png
- images/buttons/spanish/ (and all files inside)

Also, create a new folder in buttons named english, and move all files in /images/buttons/ to /images/buttons/english/


3. include/config.php

Find:
STemplate::assign('baseurl',       $config['baseurl']);

Add Above:
if ($_REQUEST['language'] != "")
{
	if ($_REQUEST['language'] == "english")
	{
		SESSION_REGISTER("language");
		$_SESSION[language] = "english";
	}
	elseif ($_REQUEST['language'] == "spanish")
	{
		SESSION_REGISTER("language");
		$_SESSION[language] = "spanish";
	}
}

if ($_SESSION['language'] == "")
{
	SESSION_REGISTER("language");
	$_SESSION[language] = "english";
}

if ($_SESSION['language'] == "english")
{
include("lang/english.php");
}
elseif ($_SESSION['language'] == "spanish")
{
include("lang/spanish.php");
}
else
{
include("lang/english.php");
}

for ($i=0; $i<count($lang); $i++)
{
	STemplate::assign('lang'.$i, $lang[$i]);
}


4. include/captcha.php

Find:
for( $i=0; $i<($width*$height)/3; $i++ ) {

Replace With:
for( $i=0; $i<3; $i++ ) {


5. You will need to replace all the php files in the root directory with the ones provided, and also you will need to replace all the theme files with the ones provided. This is needed for the multilingual support. Also update version.txt so that you can keep a record of which version you are using.


6. ajax/myajaxphp.php

Find:
$sendmailbody .= $tempusername." also included this message for you:<br>";

Add above:
$vsharemessage = str_replace("\\n", "<br>", $vsharemessage);


7. include/functions/main.php
Find:
?>

Add Above:
function insert_get_stripped_phrase($a)
{
	$stripper = $a[details]; 
	$stripper = str_replace("\\n", "<br>", $stripper);
	return $stripper;
}

function channel_seokey_count($tseokey)
{
        global $conn;
        $query="SELECT count(*) as total FROM channels WHERE seokey='".mysql_real_escape_string($tseokey)."'";
        $executequery=$conn->execute($query);
        return $executequery->fields[total];
}


8. Run this query in your database administration tool such as phpmyadmin:
ALTER TABLE `channels` ADD `seokey` VARCHAR( 120 ) NOT NULL ;


9. .htaccess

Find:
RewriteRule ^channels/(.*)/(.*) /channeldetails.php?cid=$1&title=$2

Replace With:
RewriteRule ^([-_~*a-zA-Z0-9]+)(\/)?$ channeldetails.php?key=$1


10. Upload and run this file once, then delete it from your site:
http://www.yourdomain.com/update-channels.php


11. Your Administrator Control Panel must now be accessed via the complete url:
http://www.yourdomain.com/administrator/index.php





Version Changes:
- Multilingual Support
- Cleaner image captcha
- Fixed the bug in displaying multi-line comments and e-mails.
- Made the username on the header when logged in a link to the member's profile
- Fixed IE7 RSS Feeds Bug
- Added "Select All" function when clicking on the video link or video embed link on the play video page.
- New Channel URL's www.yourdomain.com/channel-name
- Remove Videos From Channels Functionality Added
