diff --git a/docroot/AC_OETags.js b/docroot/AC_OETags.js new file mode 100644 index 0000000..d1f066b --- /dev/null +++ b/docroot/AC_OETags.js @@ -0,0 +1,276 @@ +// Flash Player Version Detection - Rev 1.6 +// Detect Client Browser type +// Copyright(c) 2005-2006 Adobe Macromedia Software, LLC. All rights reserved. +var isIE = (navigator.appVersion.indexOf("MSIE") != -1) ? true : false; +var isWin = (navigator.appVersion.toLowerCase().indexOf("win") != -1) ? true : false; +var isOpera = (navigator.userAgent.indexOf("Opera") != -1) ? true : false; + +function ControlVersion() +{ + var version; + var axo; + var e; + + // NOTE : new ActiveXObject(strFoo) throws an exception if strFoo isn't in the registry + + try { + // version will be set for 7.X or greater players + axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7"); + version = axo.GetVariable("$version"); + } catch (e) { + } + + if (!version) + { + try { + // version will be set for 6.X players only + axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6"); + + // installed player is some revision of 6.0 + // GetVariable("$version") crashes for versions 6.0.22 through 6.0.29, + // so we have to be careful. + + // default to the first public version + version = "WIN 6,0,21,0"; + + // throws if AllowScripAccess does not exist (introduced in 6.0r47) + axo.AllowScriptAccess = "always"; + + // safe to call for 6.0r47 or greater + version = axo.GetVariable("$version"); + + } catch (e) { + } + } + + if (!version) + { + try { + // version will be set for 4.X or 5.X player + axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.3"); + version = axo.GetVariable("$version"); + } catch (e) { + } + } + + if (!version) + { + try { + // version will be set for 3.X player + axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.3"); + version = "WIN 3,0,18,0"; + } catch (e) { + } + } + + if (!version) + { + try { + // version will be set for 2.X player + axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash"); + version = "WIN 2,0,0,11"; + } catch (e) { + version = -1; + } + } + + return version; +} + +// JavaScript helper required to detect Flash Player PlugIn version information +function GetSwfVer(){ + // NS/Opera version >= 3 check for Flash plugin in plugin array + var flashVer = -1; + + if (navigator.plugins != null && navigator.plugins.length > 0) { + if (navigator.plugins["Shockwave Flash 2.0"] || navigator.plugins["Shockwave Flash"]) { + var swVer2 = navigator.plugins["Shockwave Flash 2.0"] ? " 2.0" : ""; + var flashDescription = navigator.plugins["Shockwave Flash" + swVer2].description; + var descArray = flashDescription.split(" "); + var tempArrayMajor = descArray[2].split("."); + var versionMajor = tempArrayMajor[0]; + var versionMinor = tempArrayMajor[1]; + var versionRevision = descArray[3]; + if (versionRevision == "") { + versionRevision = descArray[4]; + } + if (versionRevision[0] == "d") { + versionRevision = versionRevision.substring(1); + } else if (versionRevision[0] == "r") { + versionRevision = versionRevision.substring(1); + if (versionRevision.indexOf("d") > 0) { + versionRevision = versionRevision.substring(0, versionRevision.indexOf("d")); + } + } + var flashVer = versionMajor + "." + versionMinor + "." + versionRevision; + } + } + // MSN/WebTV 2.6 supports Flash 4 + else if (navigator.userAgent.toLowerCase().indexOf("webtv/2.6") != -1) flashVer = 4; + // WebTV 2.5 supports Flash 3 + else if (navigator.userAgent.toLowerCase().indexOf("webtv/2.5") != -1) flashVer = 3; + // older WebTV supports Flash 2 + else if (navigator.userAgent.toLowerCase().indexOf("webtv") != -1) flashVer = 2; + else if ( isIE && isWin && !isOpera ) { + flashVer = ControlVersion(); + } + return flashVer; +} + +// When called with reqMajorVer, reqMinorVer, reqRevision returns true if that version or greater is available +function DetectFlashVer(reqMajorVer, reqMinorVer, reqRevision) +{ + versionStr = GetSwfVer(); + if (versionStr == -1 ) { + return false; + } else if (versionStr != 0) { + if(isIE && isWin && !isOpera) { + // Given "WIN 2,0,0,11" + tempArray = versionStr.split(" "); // ["WIN", "2,0,0,11"] + tempString = tempArray[1]; // "2,0,0,11" + versionArray = tempString.split(","); // ['2', '0', '0', '11'] + } else { + versionArray = versionStr.split("."); + } + var versionMajor = versionArray[0]; + var versionMinor = versionArray[1]; + var versionRevision = versionArray[2]; + + // is the major.revision >= requested major.revision AND the minor version >= requested minor + if (versionMajor > parseFloat(reqMajorVer)) { + return true; + } else if (versionMajor == parseFloat(reqMajorVer)) { + if (versionMinor > parseFloat(reqMinorVer)) + return true; + else if (versionMinor == parseFloat(reqMinorVer)) { + if (versionRevision >= parseFloat(reqRevision)) + return true; + } + } + return false; + } +} + +function AC_AddExtension(src, ext) +{ + if (src.indexOf('?') != -1) + return src.replace(/\?/, ext+'?'); + else + return src + ext; +} + +function AC_Generateobj(objAttrs, params, embedAttrs) +{ + var str = ''; + if (isIE && isWin && !isOpera) + { + str += ' '; + str += ''; + } else { + str += 'assign("PAGE_TITLE","About TUvé"); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + $data[tpl]->define(array(body=>"/about.html")); + + //DoSession(); + + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/aboutus.php b/docroot/aboutus.php new file mode 100644 index 0000000..2fb19cc --- /dev/null +++ b/docroot/aboutus.php @@ -0,0 +1,20 @@ +assign("PAGE_TITLE","About Us"); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + $data[tpl]->define(array(body=>"/aboutus.html")); + + //DoSession(); + + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/activate.php b/docroot/activate.php new file mode 100644 index 0000000..5301f7a --- /dev/null +++ b/docroot/activate.php @@ -0,0 +1,55 @@ +assign("PAGE_TITLE","News"); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + + if ($data['aemail'] != "") { + $data[tpl]->define(array(body=>"/activate-reactivate.html")); + $query = "SELECT uid,active,firstname,lastname FROM users WHERE email LIKE '$data[aemail]'"; + $res = mysql_query($query); + if (mysql_num_rows($res) > 0) { + if (mysql_result($res,0,'active') != 1) { + $active = time(); + $uid = mysql_result($res,0,'uid'); + $query = "UPDATE users SET active = $active WHERE uid = $uid"; + mysql_query($query); + + $firstname = mysql_result($res,0,'firstname'); + $lastname = mysql_result($res,0,'lastname'); + send_mail("$firstname $lastname <$data[aemail]>","Thank you for registering with TUve

Please Click or goto the following link to confirm your email address http://www.tuve.tv/activate.php?data[active]=$active&data[email]=$data[aemail]

Thank you,
The TUve Staff
","Please Confirm Your E-Mail Address","support@tuve.tv","TUve Support"); + } + } + } + else { + $query = "SELECT uid,active,firstname,lastname FROM users WHERE (active = $data[active] || active = 1) AND email LIKE '$data[email]'"; + $res = mysql_query($query); + if (mysql_num_rows($res) == 0) + $data[tpl]->define(array(body=>"/activate-failed.html")); + else { + $data[tpl]->define(array(body=>"/activate-success.html")); + if (mysql_result($res,0,'active') != 1) { + $uid = mysql_result($res,0,'uid'); + $rDate = time(); + $query = "UPDATE users SET active = 1,registered = $rDate WHERE uid = $uid"; + mysql_query($query); + + $firstname = mysql_result($res,0,'firstname'); + $lastname = mysql_result($res,0,'lastname'); + send_mail("$firstname $lastname <$data[email]>","Your registration is now complete.
Thank you,
The TUve Staff
","Registation Complete","support@tuve.tv","TUve Support"); + $query = "INSERT INTO artists (artist,bio,photo,oid,sbio) VALUES('None','No Description','http://www.ubixonline.com/images/UbixCube.swf',$uid,'No Description')"; + mysql_query($query); + } + } + } + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/beta/AC_OETags.js b/docroot/beta/AC_OETags.js new file mode 100644 index 0000000..d1f066b --- /dev/null +++ b/docroot/beta/AC_OETags.js @@ -0,0 +1,276 @@ +// Flash Player Version Detection - Rev 1.6 +// Detect Client Browser type +// Copyright(c) 2005-2006 Adobe Macromedia Software, LLC. All rights reserved. +var isIE = (navigator.appVersion.indexOf("MSIE") != -1) ? true : false; +var isWin = (navigator.appVersion.toLowerCase().indexOf("win") != -1) ? true : false; +var isOpera = (navigator.userAgent.indexOf("Opera") != -1) ? true : false; + +function ControlVersion() +{ + var version; + var axo; + var e; + + // NOTE : new ActiveXObject(strFoo) throws an exception if strFoo isn't in the registry + + try { + // version will be set for 7.X or greater players + axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7"); + version = axo.GetVariable("$version"); + } catch (e) { + } + + if (!version) + { + try { + // version will be set for 6.X players only + axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6"); + + // installed player is some revision of 6.0 + // GetVariable("$version") crashes for versions 6.0.22 through 6.0.29, + // so we have to be careful. + + // default to the first public version + version = "WIN 6,0,21,0"; + + // throws if AllowScripAccess does not exist (introduced in 6.0r47) + axo.AllowScriptAccess = "always"; + + // safe to call for 6.0r47 or greater + version = axo.GetVariable("$version"); + + } catch (e) { + } + } + + if (!version) + { + try { + // version will be set for 4.X or 5.X player + axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.3"); + version = axo.GetVariable("$version"); + } catch (e) { + } + } + + if (!version) + { + try { + // version will be set for 3.X player + axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.3"); + version = "WIN 3,0,18,0"; + } catch (e) { + } + } + + if (!version) + { + try { + // version will be set for 2.X player + axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash"); + version = "WIN 2,0,0,11"; + } catch (e) { + version = -1; + } + } + + return version; +} + +// JavaScript helper required to detect Flash Player PlugIn version information +function GetSwfVer(){ + // NS/Opera version >= 3 check for Flash plugin in plugin array + var flashVer = -1; + + if (navigator.plugins != null && navigator.plugins.length > 0) { + if (navigator.plugins["Shockwave Flash 2.0"] || navigator.plugins["Shockwave Flash"]) { + var swVer2 = navigator.plugins["Shockwave Flash 2.0"] ? " 2.0" : ""; + var flashDescription = navigator.plugins["Shockwave Flash" + swVer2].description; + var descArray = flashDescription.split(" "); + var tempArrayMajor = descArray[2].split("."); + var versionMajor = tempArrayMajor[0]; + var versionMinor = tempArrayMajor[1]; + var versionRevision = descArray[3]; + if (versionRevision == "") { + versionRevision = descArray[4]; + } + if (versionRevision[0] == "d") { + versionRevision = versionRevision.substring(1); + } else if (versionRevision[0] == "r") { + versionRevision = versionRevision.substring(1); + if (versionRevision.indexOf("d") > 0) { + versionRevision = versionRevision.substring(0, versionRevision.indexOf("d")); + } + } + var flashVer = versionMajor + "." + versionMinor + "." + versionRevision; + } + } + // MSN/WebTV 2.6 supports Flash 4 + else if (navigator.userAgent.toLowerCase().indexOf("webtv/2.6") != -1) flashVer = 4; + // WebTV 2.5 supports Flash 3 + else if (navigator.userAgent.toLowerCase().indexOf("webtv/2.5") != -1) flashVer = 3; + // older WebTV supports Flash 2 + else if (navigator.userAgent.toLowerCase().indexOf("webtv") != -1) flashVer = 2; + else if ( isIE && isWin && !isOpera ) { + flashVer = ControlVersion(); + } + return flashVer; +} + +// When called with reqMajorVer, reqMinorVer, reqRevision returns true if that version or greater is available +function DetectFlashVer(reqMajorVer, reqMinorVer, reqRevision) +{ + versionStr = GetSwfVer(); + if (versionStr == -1 ) { + return false; + } else if (versionStr != 0) { + if(isIE && isWin && !isOpera) { + // Given "WIN 2,0,0,11" + tempArray = versionStr.split(" "); // ["WIN", "2,0,0,11"] + tempString = tempArray[1]; // "2,0,0,11" + versionArray = tempString.split(","); // ['2', '0', '0', '11'] + } else { + versionArray = versionStr.split("."); + } + var versionMajor = versionArray[0]; + var versionMinor = versionArray[1]; + var versionRevision = versionArray[2]; + + // is the major.revision >= requested major.revision AND the minor version >= requested minor + if (versionMajor > parseFloat(reqMajorVer)) { + return true; + } else if (versionMajor == parseFloat(reqMajorVer)) { + if (versionMinor > parseFloat(reqMinorVer)) + return true; + else if (versionMinor == parseFloat(reqMinorVer)) { + if (versionRevision >= parseFloat(reqRevision)) + return true; + } + } + return false; + } +} + +function AC_AddExtension(src, ext) +{ + if (src.indexOf('?') != -1) + return src.replace(/\?/, ext+'?'); + else + return src + ext; +} + +function AC_Generateobj(objAttrs, params, embedAttrs) +{ + var str = ''; + if (isIE && isWin && !isOpera) + { + str += ' '; + str += ''; + } else { + str += '= 0) ? document.location.href.substr(idx+1) : ''; + } + + /* Get the current location hash excluding the '#' symbol. */ + function setHash(hash) { + // It would be nice if we could use document.location.hash here, + // but it's faulty sometimes. + if (hash == '') hash = '#' + document.location.hash = hash; + } + + function createState(baseUrl, newUrl, flexAppUrl) { + return { 'baseUrl': baseUrl, 'newUrl': newUrl, 'flexAppUrl': flexAppUrl, 'title': null }; + } + + /* Add a history entry to the browser. + * baseUrl: the portion of the location prior to the '#' + * newUrl: the entire new URL, including '#' and following fragment + * flexAppUrl: the portion of the location following the '#' only + */ + function addHistoryEntry(baseUrl, newUrl, flexAppUrl) { + + //delete all the history entries + forwardStack = []; + + if (browser.ie) { + //Check to see if we are being asked to do a navigate for the first + //history entry, and if so ignore, because it's coming from the creation + //of the history iframe + if (flexAppUrl == defaultHash && document.location.href == initialHref && _ie_firstload) { + currentHref = initialHref; + return; + } + if ((!flexAppUrl || flexAppUrl == defaultHash) && _ie_firstload) { + newUrl = baseUrl + '#' + defaultHash; + flexAppUrl = defaultHash; + } else { + // for IE, tell the history frame to go somewhere without a '#' + // in order to get this entry into the browser history. + getHistoryFrame().src = historyFrameSourcePrefix + flexAppUrl; + } + setHash(flexAppUrl); + } else { + + //ADR + if (backStack.length == 0 && initialState.flexAppUrl == flexAppUrl) { + initialState = createState(baseUrl, newUrl, flexAppUrl); + } else if(backStack.length > 0 && backStack[backStack.length - 1].flexAppUrl == flexAppUrl) { + backStack[backStack.length - 1] = createState(baseUrl, newUrl, flexAppUrl); + } + + if (browser.safari) { + // for Safari, submit a form whose action points to the desired URL + if (browser.version <= 419.3) { + var file = window.location.pathname.toString(); + file = file.substring(file.lastIndexOf("/")+1); + getFormElement().innerHTML = '
'; + //get the current elements and add them to the form + var qs = window.location.search.substring(1); + var qs_arr = qs.split("&"); + for (var i = 0; i < qs_arr.length; i++) { + var tmp = qs_arr[i].split("="); + var elem = document.createElement("input"); + elem.type = "hidden"; + elem.name = tmp[0]; + elem.value = tmp[1]; + document.forms.historyForm.appendChild(elem); + } + document.forms.historyForm.submit(); + } else { + top.location.hash = flexAppUrl; + } + // We also have to maintain the history by hand for Safari + historyHash[history.length] = flexAppUrl; + _storeStates(); + } else { + // Otherwise, write an anchor into the page and tell the browser to go there + addAnchor(flexAppUrl); + setHash(flexAppUrl); + } + } + backStack.push(createState(baseUrl, newUrl, flexAppUrl)); + } + + function _storeStates() { + if (browser.safari) { + getRememberElement().value = historyHash.join(","); + } + } + + function handleBackButton() { + //The "current" page is always at the top of the history stack. + var current = backStack.pop(); + if (!current) { return; } + var last = backStack[backStack.length - 1]; + if (!last && backStack.length == 0){ + last = initialState; + } + forwardStack.push(current); + } + + function handleForwardButton() { + //summary: private method. Do not call this directly. + + var last = forwardStack.pop(); + if (!last) { return; } + backStack.push(last); + } + + function handleArbitraryUrl() { + //delete all the history entries + forwardStack = []; + } + + /* Called periodically to poll to see if we need to detect navigation that has occurred */ + function checkForUrlChange() { + + if (browser.ie) { + if (currentHref != document.location.href && currentHref + '#' != document.location.href) { + //This occurs when the user has navigated to a specific URL + //within the app, and didn't use browser back/forward + //IE seems to have a bug where it stops updating the URL it + //shows the end-user at this point, but programatically it + //appears to be correct. Do a full app reload to get around + //this issue. + if (browser.version < 7) { + currentHref = document.location.href; + document.location.reload(); + } else { + //getHistoryFrame().src = historyFrameSourcePrefix + getHash(); + } + } + } + + if (browser.safari) { + // For Safari, we have to check to see if history.length changed. + if (currentHistoryLength >= 0 && history.length != currentHistoryLength) { + //alert("did change: " + history.length + ", " + historyHash.length + "|" + historyHash[history.length] + "|>" + historyHash.join("|")); + // If it did change, then we have to look the old state up + // in our hand-maintained array since document.location.hash + // won't have changed, then call back into BrowserManager. + currentHistoryLength = history.length; + var flexAppUrl = historyHash[currentHistoryLength]; + if (flexAppUrl == '') { + //flexAppUrl = defaultHash; + } + //ADR: to fix multiple + if (typeof BrowserHistory_multiple != "undefined" && BrowserHistory_multiple == true) { + var pl = getPlayers(); + for (var i = 0; i < pl.length; i++) { + pl[i].browserURLChange(flexAppUrl); + } + } else { + getPlayer().browserURLChange(flexAppUrl); + } + _storeStates(); + } + } + if (browser.firefox) { + if (currentHref != document.location.href) { + var bsl = backStack.length; + + var urlActions = { + back: false, + forward: false, + set: false + } + + if ((window.location.hash == initialHash || window.location.href == initialHref) && (bsl == 1)) { + urlActions.back = true; + // FIXME: could this ever be a forward button? + // we can't clear it because we still need to check for forwards. Ugg. + // clearInterval(this.locationTimer); + handleBackButton(); + } + + // first check to see if we could have gone forward. We always halt on + // a no-hash item. + if (forwardStack.length > 0) { + if (forwardStack[forwardStack.length-1].flexAppUrl == getHash()) { + urlActions.forward = true; + handleForwardButton(); + } + } + + // ok, that didn't work, try someplace back in the history stack + if ((bsl >= 2) && (backStack[bsl - 2])) { + if (backStack[bsl - 2].flexAppUrl == getHash()) { + urlActions.back = true; + handleBackButton(); + } + } + + if (!urlActions.back && !urlActions.forward) { + var foundInStacks = { + back: -1, + forward: -1 + } + + for (var i = 0; i < backStack.length; i++) { + if (backStack[i].flexAppUrl == getHash() && i != (bsl - 2)) { + arbitraryUrl = true; + foundInStacks.back = i; + } + } + for (var i = 0; i < forwardStack.length; i++) { + if (forwardStack[i].flexAppUrl == getHash() && i != (bsl - 2)) { + arbitraryUrl = true; + foundInStacks.forward = i; + } + } + handleArbitraryUrl(); + } + + // Firefox changed; do a callback into BrowserManager to tell it. + currentHref = document.location.href; + var flexAppUrl = getHash(); + if (flexAppUrl == '') { + //flexAppUrl = defaultHash; + } + //ADR: to fix multiple + if (typeof BrowserHistory_multiple != "undefined" && BrowserHistory_multiple == true) { + var pl = getPlayers(); + for (var i = 0; i < pl.length; i++) { + pl[i].browserURLChange(flexAppUrl); + } + } else { + getPlayer().browserURLChange(flexAppUrl); + } + } + } + //setTimeout(checkForUrlChange, 50); + } + + /* Write an anchor into the page to legitimize it as a URL for Firefox et al. */ + function addAnchor(flexAppUrl) + { + if (document.getElementsByName(flexAppUrl).length == 0) { + getAnchorElement().innerHTML += "" + flexAppUrl + ""; + } + } + + var _initialize = function () { + if (browser.ie) + { + var scripts = document.getElementsByTagName('script'); + for (var i = 0, s; s = scripts[i]; i++) { + if (s.src.indexOf("history.js") > -1) { + var iframe_location = (new String(s.src)).replace("history.js", "historyFrame.html"); + } + } + historyFrameSourcePrefix = iframe_location + "?"; + var src = historyFrameSourcePrefix; + + var iframe = document.createElement("iframe"); + iframe.id = 'ie_historyFrame'; + iframe.name = 'ie_historyFrame'; + //iframe.src = historyFrameSourcePrefix; + setTimeout(function() { + document.body.appendChild(iframe); + }, 0); + } + + if (browser.safari) + { + var rememberDiv = document.createElement("div"); + rememberDiv.id = 'safari_rememberDiv'; + document.body.appendChild(rememberDiv); + rememberDiv.innerHTML = ''; + + var formDiv = document.createElement("div"); + formDiv.id = 'safari_formDiv'; + document.body.appendChild(formDiv); + + var reloader_content = document.createElement('div'); + reloader_content.id = 'safarireloader'; + var scripts = document.getElementsByTagName('script'); + for (var i = 0, s; s = scripts[i]; i++) { + if (s.src.indexOf("history.js") > -1) { + html = (new String(s.src)).replace(".js", ".html"); + } + } + reloader_content.innerHTML = ''; + document.body.appendChild(reloader_content); + reloader_content.style.position = 'absolute'; + reloader_content.style.left = reloader_content.style.top = '-9999px'; + iframe = reloader_content.getElementsByTagName('iframe')[0]; + + if (document.getElementById("safari_remember_field").value != "" ) { + historyHash = document.getElementById("safari_remember_field").value.split(","); + } + + } + + if (browser.firefox) + { + var anchorDiv = document.createElement("div"); + anchorDiv.id = 'firefox_anchorDiv'; + document.body.appendChild(anchorDiv); + } + + //setTimeout(checkForUrlChange, 50); + } + + return { + historyHash: historyHash, + backStack: function() { return backStack; }, + forwardStack: function() { return forwardStack }, + getPlayer: getPlayer, + initialize: function(src) { + _initialize(src); + }, + setURL: function(url) { + document.location.href = url; + }, + getURL: function() { + return document.location.href; + }, + getTitle: function() { + return document.title; + }, + setTitle: function(title) { + try { + backStack[backStack.length - 1].title = title; + } catch(e) { } + //if on safari, set the title to be the empty string. + if (browser.safari) { + if (title == "") { + try { + var tmp = window.location.href.toString(); + title = tmp.substring((tmp.lastIndexOf("/")+1), tmp.lastIndexOf("#")); + } catch(e) { + title = ""; + } + } + } + document.title = title; + }, + setDefaultURL: function(def) + { + defaultHash = def; + def = getHash(); + //trailing ? is important else an extra frame gets added to the history + //when navigating back to the first page. Alternatively could check + //in history frame navigation to compare # and ?. + if (browser.ie) + { + _ie_firstload = true; + getHistoryFrame().src = historyFrameSourcePrefix + def; + window.location.replace("#" + def); + setInterval(checkForUrlChange, 50); + } + + if (browser.safari) + { + currentHistoryLength = history.length; + if (historyHash.length == 0) { + historyHash[currentHistoryLength] = def; + var newloc = "#" + def; + window.location.replace(newloc); + } else { + //alert(historyHash[historyHash.length-1]); + } + //setHash(def); + setInterval(checkForUrlChange, 50); + } + + + if (browser.firefox || browser.opera) + { + var reg = new RegExp("#" + def + "$"); + if (window.location.toString().match(reg)) { + } else { + var newloc ="#" + def; + window.location.replace(newloc); + } + setInterval(checkForUrlChange, 50); + //setHash(def); + } + + }, + + /* Set the current browser URL; called from inside BrowserManager to propagate + * the application state out to the container. + */ + setBrowserURL: function(flexAppUrl, objectId) { + if (browser.ie && typeof objectId != "undefined") { + currentObjectId = objectId; + } + //fromIframe = fromIframe || false; + //fromFlex = fromFlex || false; + //alert("setBrowserURL: " + flexAppUrl); + //flexAppUrl = (flexAppUrl == "") ? defaultHash : flexAppUrl ; + + var pos = document.location.href.indexOf('#'); + var baseUrl = pos != -1 ? document.location.href.substr(0, pos) : document.location.href; + var newUrl = baseUrl + '#' + flexAppUrl; + + if (document.location.href != newUrl && document.location.href + '#' != newUrl) { + currentHref = newUrl; + addHistoryEntry(baseUrl, newUrl, flexAppUrl); + currentHistoryLength = history.length; + } + + return false; + }, + + browserURLChange: function(flexAppUrl) { + var objectId = null; + if (browser.ie && currentObjectId != null) { + objectId = currentObjectId; + } + pendingURL = ''; + + if (typeof BrowserHistory_multiple != "undefined" && BrowserHistory_multiple == true) { + var pl = getPlayers(); + for (var i = 0; i < pl.length; i++) { + try { + pl[i].browserURLChange(flexAppUrl); + } catch(e) { } + } + } else { + try { + getPlayer(objectId).browserURLChange(flexAppUrl); + } catch(e) { } + } + + currentObjectId = null; + } + + } + +})(); + +// Initialization + +// Automated unit testing and other diagnostics + +function setURL(url) +{ + document.location.href = url; +} + +function backButton() +{ + history.back(); +} + +function forwardButton() +{ + history.forward(); +} + +function goForwardOrBackInHistory(step) +{ + history.go(step); +} + +BrowserHistoryUtils.addEvent(window, "load", function() { BrowserHistory.initialize(); }); diff --git a/docroot/beta/history/historyFrame.html b/docroot/beta/history/historyFrame.html new file mode 100644 index 0000000..e83255f --- /dev/null +++ b/docroot/beta/history/historyFrame.html @@ -0,0 +1,29 @@ + + + + + + + + Hidden frame for Browser History support. + + diff --git a/docroot/beta/playerProductInstall.swf b/docroot/beta/playerProductInstall.swf new file mode 100644 index 0000000..bdc3437 --- /dev/null +++ b/docroot/beta/playerProductInstall.swf Binary files differ diff --git a/docroot/beta/ubChattin.html b/docroot/beta/ubChattin.html new file mode 100644 index 0000000..132af71 --- /dev/null +++ b/docroot/beta/ubChattin.html @@ -0,0 +1,121 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/docroot/beta/ubChattin.swf b/docroot/beta/ubChattin.swf new file mode 100644 index 0000000..2253f74 --- /dev/null +++ b/docroot/beta/ubChattin.swf Binary files differ diff --git a/docroot/channels.php b/docroot/channels.php new file mode 100644 index 0000000..90e6c88 --- /dev/null +++ b/docroot/channels.php @@ -0,0 +1,39 @@ +assign("PAGE_TITLE","Channel List"); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + $data[tpl]->define(array(body=>"/channels.html")); + + //DoSession(); + + $query = "SELECT * FROM channels LEFT JOIN videos ON channels.nowplaying = videos.vid ORDER BY channel"; + $result = mysql_query($query); + + for ($i=0;$i Channel:
Topic:
Now Playing: $channel
$topic
$artist - $title\n"; + $rw .= "
\n"; + } + + $data['tpl']->assign("ROWS",$rw); + + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/contact.php b/docroot/contact.php new file mode 100644 index 0000000..41523d7 --- /dev/null +++ b/docroot/contact.php @@ -0,0 +1,20 @@ +assign("PAGE_TITLE","Contact Us"); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + $data[tpl]->define(array(body=>"/contact.html")); + + //DoSession(); + + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/css/master_styles.css b/docroot/css/master_styles.css new file mode 100644 index 0000000..ee5488f --- /dev/null +++ b/docroot/css/master_styles.css @@ -0,0 +1,105 @@ +@charset "UTF-8"; +body { +font-family:"Myriad Pro"; +font-size:10pt; +margin:0px; +} +p { + font-size:10pt; +} +h1 { + color:#558793; + font-size:14pt; +} +h2 { + color:#829397; + font-size:13pt; +} +h3 { + color:#829397; + font-size:11pt; + margin-bottom:1px; +} +#master_container { + margin:auto; + width: 825px; + background-image:url(../images/global/master_container_bg_tile.jpg); + min-height:500px; +} +#nav_container { + width:801px; + height:116px; + background-image:url(../images/global/tuve_banner_802.gif); +} +#membertext { + text-align:right; + padding-right:15px; + padding-top:5px; +} +#membertext a:link, #membertext a:visited { + color:#ff8d07; +} +#membertext a:hover, #membertext a:active { + color:#b66505; +} +#main_container { + width:801px; + background-image:url(../images/global/content_container_bg_vert.jpg); + background-repeat:repeat-x; + min-height:700px; + margin-left:12px; + margin-right:13px; +} +#navtext { + text-align:right; + padding-right:15px; + padding-top:43px; +} +#navtext a:link, #navtext a:visited { + color:#ff8d07; +} +#navtext a:hover, #navtext a:active { + color:#b66505; +} +#content_container { + width:724px; + margin-left:39px; + margin-right:38px; +} +#content_area_top_bar { + height:24px; + background-image:url(../images/global/content_area_top_bar.gif); +} +#content_area { + min-height:350px; + background-image:url(../images/global/content_area_bg.gif); +} +#content_area a:link, #content_area a:visited, #content_area a:active, #content_area a:hover { + color:#003333; +} +#subnav { + width:130px; + min-height:190px; + float:left; + margin:10px; + padding-top:25px; + padding-left:25px; + background-image:url(../images/global/content_area_side_nav_bg.gif); + background-repeat:no-repeat; +} +#subnav a:link, #subnav a:visited { + font-size:9pt; + color:#ff8d07; +} +#subnavt a:hover, #subnav a:active { + font-size:9pt; + color:#b66505; +} +#content { + width:530px; + float:left; +} +#content_area_bot_bar { + height:24px; + background-image:url(../images/global/content_area_bot_bar.gif); +} diff --git a/docroot/faq.php b/docroot/faq.php new file mode 100644 index 0000000..41d5bcd --- /dev/null +++ b/docroot/faq.php @@ -0,0 +1,20 @@ +assign("PAGE_TITLE","FAQ"); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + $data[tpl]->define(array(body=>"/faq.html")); + + //DoSession(); + + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/images/LaunchTUve.png b/docroot/images/LaunchTUve.png new file mode 100644 index 0000000..decb66e --- /dev/null +++ b/docroot/images/LaunchTUve.png Binary files differ diff --git a/docroot/images/TUve.png b/docroot/images/TUve.png new file mode 100644 index 0000000..1bcf52e --- /dev/null +++ b/docroot/images/TUve.png Binary files differ diff --git a/docroot/images/global/content_area_bg.gif b/docroot/images/global/content_area_bg.gif new file mode 100644 index 0000000..3f2ec81 --- /dev/null +++ b/docroot/images/global/content_area_bg.gif Binary files differ diff --git a/docroot/images/global/content_area_bot_bar.gif b/docroot/images/global/content_area_bot_bar.gif new file mode 100644 index 0000000..0629719 --- /dev/null +++ b/docroot/images/global/content_area_bot_bar.gif Binary files differ diff --git a/docroot/images/global/content_area_side_nav_bg.gif b/docroot/images/global/content_area_side_nav_bg.gif new file mode 100644 index 0000000..1c683e0 --- /dev/null +++ b/docroot/images/global/content_area_side_nav_bg.gif Binary files differ diff --git a/docroot/images/global/content_area_top_bar.gif b/docroot/images/global/content_area_top_bar.gif new file mode 100644 index 0000000..022fbd5 --- /dev/null +++ b/docroot/images/global/content_area_top_bar.gif Binary files differ diff --git a/docroot/images/global/content_container_bg_vert.jpg b/docroot/images/global/content_container_bg_vert.jpg new file mode 100644 index 0000000..de1c69f --- /dev/null +++ b/docroot/images/global/content_container_bg_vert.jpg Binary files differ diff --git a/docroot/images/global/launch_button.gif b/docroot/images/global/launch_button.gif new file mode 100644 index 0000000..39c1770 --- /dev/null +++ b/docroot/images/global/launch_button.gif Binary files differ diff --git a/docroot/images/global/master_container_bg_tile.jpg b/docroot/images/global/master_container_bg_tile.jpg new file mode 100644 index 0000000..97b34d3 --- /dev/null +++ b/docroot/images/global/master_container_bg_tile.jpg Binary files differ diff --git a/docroot/images/global/tuve_banner_793.gif b/docroot/images/global/tuve_banner_793.gif new file mode 100644 index 0000000..7aa829e --- /dev/null +++ b/docroot/images/global/tuve_banner_793.gif Binary files differ diff --git a/docroot/images/global/tuve_banner_802.gif b/docroot/images/global/tuve_banner_802.gif new file mode 100644 index 0000000..d62331e --- /dev/null +++ b/docroot/images/global/tuve_banner_802.gif Binary files differ diff --git a/docroot/index.php b/docroot/index.php new file mode 100644 index 0000000..7b0a4b1 --- /dev/null +++ b/docroot/index.php @@ -0,0 +1,20 @@ +assign("PAGE_TITLE",""); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + $data[tpl]->define(array(body=>"/main.html")); + + //DoSession(); + + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/indexold.php b/docroot/indexold.php new file mode 100644 index 0000000..775cd02 --- /dev/null +++ b/docroot/indexold.php @@ -0,0 +1,46 @@ + + + TUv� - It's like TV, only better + + + + + + + + + + + + + + + + + +
+ + + + +
Register   Login
 
+ + +
Home Channel Lineup About Us Contact
+
 
 
+ diff --git a/docroot/lostact.php b/docroot/lostact.php new file mode 100644 index 0000000..16e2525 --- /dev/null +++ b/docroot/lostact.php @@ -0,0 +1,44 @@ +assign("PAGE_TITLE",""); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + + + if ($data['email']) { + $query = "SELECT password,active,firstname,lastname,email FROM users WHERE email LIKE '%$data[email]'"; + $res = mysql_query($query); + if (mysql_num_rows($res) == 0) { + $data['tpl']->define(array(body=>"/lostact.html")); + $error = "Invalid E-Mail Address"; + } + else { + $fName = mysql_result($res,0,'firstname'); + $lName = mysql_result($res,0,'lastname'); + $email = mysql_result($res,0,'email'); + $data['tpl']->define(array(body=>"/lostact-sent.html")); + $data['tpl']->assign("EMAIL",$email); + if ($active == 1) + $message = "Please Activate"; + else + $message = "$fName,
Your Password Is: $pass

Sincerely,
TUVe Support"; + + send_mail("$fName $lName <$email>",$message,"TUve Password Recovery / Account Activation","support@tuve.tv","TUve Support",false); + } + } + else + $data['tpl']->define(array(body=>"/lostact.html")); + + $data['tpl']->assign("ERROR",$error); + + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/news.php b/docroot/news.php new file mode 100644 index 0000000..1652f59 --- /dev/null +++ b/docroot/news.php @@ -0,0 +1,20 @@ +assign("PAGE_TITLE","News"); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + $data[tpl]->define(array(body=>"/news.html")); + + //DoSession(); + + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/playerProductInstall.swf b/docroot/playerProductInstall.swf new file mode 100644 index 0000000..bdc3437 --- /dev/null +++ b/docroot/playerProductInstall.swf Binary files differ diff --git a/docroot/profile.php b/docroot/profile.php new file mode 100644 index 0000000..2c8bca4 --- /dev/null +++ b/docroot/profile.php @@ -0,0 +1,162 @@ +assign("PAGE_TITLE","Profile"); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + $data[tpl]->define(array(body=>"/profile.html")); + + //DoSession(); + + $query = "SELECT uid,username,caption,gender,bmonth,byear,city,state_prov,country,profile_image,registered,about_me FROM users WHERE username LIKE '$data[user]'"; + $res = mysql_query($query); + + if (mysql_numrows($res) == 0) { + $data['tpl']->assign("USER","Unknown"); + } + else { + /* Set up age */ + $byear = mysql_result($res,0,'byear'); + $bmonth = mysql_result($res,0,'bmonth'); + + $age = date("Y") - $byear; + + if ($bmonth > date("m")) + $age--; + $data['tpl']->assign("AGE",$age); + + /* Set up location */ + $location = mysql_result($res,0,'city') . ", "; + $location .= mysql_result($res,0,'state_prov') . "
" . mysql_result($res,0,'country'); + $data['tpl']->assign("LOCATION",$location); + + /* Set up username */ + $user = mysql_result($res,0,'username'); + $data['tpl']->assign("USER",$user); + + /* Set Caption */ + $data['tpl']->assign("CAPTION",mysql_result($res,0,'caption')); + + /* Set Gender */ + if (mysql_result($res,0,'gender') == 1) + $data['tpl']->assign("GENDER","Male"); + else + $data['tpl']->assign("GENDER","Female"); + + /* Set Profile Image */ + $data['tpl']->assign("PROFILE_IMAGE",mysql_result($res,0,'profile_image')); + + /* Set Registered */ + $data['tpl']->assign("REGISTERED",date("M Y",mysql_result($res,0,'registered'))); + + /* Set About Me */ + $data['tpl']->assign("ABOUT_ME",mysql_result($res,0,'about_me')); + + /* Channels */ + $uid = mysql_result($res,0,'uid'); + + $query = "SELECT * FROM channels LEFT JOIN videos ON channels.nowplaying = videos.vid WHERE channels.oid = $uid ORDER BY channel"; + $result = mysql_query($query); + + for ($i=0;$i 65) + $ebr = "
"; + else + $ebr = ""; + + $rw .= " Channel:
Topic:$ebr
Now Playing: $channel
$topic
$artist - $title\n"; + $rw .= "
\n"; + } + $data['tpl']->assign("CHANNELS",$rw); + + if (mysql_numrows(mysql_query("SELECT userid FROM active WHERE uid = $uid")) == 1) + $data['tpl']->assign("ONLINE","Currently Online"); + else + $data['tpl']->assign("ONLINE","Currently Offline"); + + $query = "SELECT vid,artist,title,thumb FROM videos WHERE oid = $uid"; + $result = mysql_query($query); + + $rows = mysql_numrows($result); + + if ($rows > 16) { + $rows = 16; + $m = 1; + } + else + $m = 0; + + for ($i = 0;$i < $rows;$i++) { + $artist = mysql_result($result,$i,'artist'); + $title = mysql_result($result,$i,'title'); + $thumb = mysql_result($result,$i,'thumb'); + $vid = mysql_result($result,$i,'vid'); + if ($media == "") + $media = ""; + else if (($i % 4) == 0) + $media .= ""; + + $media .= "
$artist - $title
"; + } + if ($m == 0) + $media .= ""; + else + $media .= "See All"; + + $data['tpl']->assign("MEDIA",$media); + + $query = "SELECT bid,fid,profile_image,username FROM friends f INNER JOIN users u ON f.fid = u.uid WHERE f.oid = $uid"; + $result = mysql_query($query); + + $rows = mysql_numrows($result); + + if ($rows > 16) { + $rows = 16; + $m = 1; + } + else + $m = 0; + + for ($i = 0;$i < $rows;$i++) { + $thumb = mysql_result($result,$i,'profile_image'); + $username = mysql_result($result,$i,'username'); + if ($buddies == "") + $buddies = ""; + else if (($i % 4) == 0) + $buddies .= ""; + $buddies .= "
$username
\n"; + } + if ($m == 0) + $buddies .= ""; + else + $buddies .= "See All"; + + $data['tpl']->assign("BUDDIES",$buddies); + + + } + + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/register.php b/docroot/register.php new file mode 100644 index 0000000..83bcbc1 --- /dev/null +++ b/docroot/register.php @@ -0,0 +1,114 @@ + assign("PAGE_TITLE","Register for a TUve account"); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + + //DoSession(); + + if ($data['register'] != "") { + if (strlen($data['firstname']) < 3) + $message .= "Invalid First Name "; + if (strlen($data['lastname']) < 3) + $message .= "Invalid Last Name "; + if ($data['postal_code'] == "") + $message .= "Please Enter Your Postal Code"; + if ($data['country'] == "ZZ") + $message .= "Please Select A Country "; + if ($data['bmonth'] == 0) + $message .= "Invalid Birth Month "; + if ($data['bday'] == 0) + $message .= "Invalid Birth Day "; + if ($data['byear'] == 0) + $message .= "Invalid Birth Year "; + if ($data['username'] == "") + $message .= "Invalid Username "; + $query = "SELECT uid FROM users WHERE username = \"$data[username]\""; + $res = mysql_query($query); + if (mysql_num_rows($res) > 0) + $message .= "Username is not available "; + if ($data['password1'] != $data['password2']) + $message .= "Password Mismatch
"; + $query = "SELECT uid FROM users WHERE email like \"$data[email1]\""; + if (mysql_num_rows(mysql_query($query)) > 0) + $message .= "This E-Mail Address Is Already Registered "; + if ($data['email1'] != $data['email2']) + $message .= "E-Mail Mismatch "; + } + + if (($message == "") && ($data['register'] != "")) { + $data['tpl']->define(array(body=>"/register-success.html")); + + $active = time(); + + $query = "INSERT INTO users (firstname,lastname,postal_code,country,bmonth,bday,byear,email,username,password,gid,active) VALUES(\"$data[firstname]\",\"$data[lastname]\",\"$data[postal_code]\",\"$data[country]\",$data[bmonth],$data[bday],$data[byear],\"$data[email1]\",\"$data[username]\",\"$data[password1]\",3,$active)"; + mysql_query($query); + + send_mail("$data[firstname] $data[lastname] <$data[email1]>","Thank you for registering with TUve

Please Click or goto the following link to confirm your email address http://www.tuve.tv/activate.php?data[active]=$active&data[email]=$data[email1]

Thank you,
The TUve Staff
","Please Confirm Your E-Mail Address","support@tuve.tv","TUve Support"); + send_mail("Christopher Olsen ","New registering with TUve

Please Click or goto the following link to confirm your email address http://www.tuve.tv/activate.php?data[active]=$active&data[email]=$data[email1]

Thank you,
The TUve Staff
","New Registration","support@tuve.tv","TUve Support"); + } + else { + $data['tpl']->define(array(body=>"/register.html")); + $data['tpl']->assign("FIRSTNAME",$data['firstname']); + $data['tpl']->assign("LASTNAME",$data['lastname']); + $data['tpl']->assign("POSTAL_CODE",$data['postal_code']); + $data['tpl']->assign("USERNAME",$data['username']); + $data['tpl']->assign("EMAIL1",$data['email1']); + $data['tpl']->assign("EMAIL2",$data['email2']); + $data['tpl']->assign("PASSWORD1",$data['password1']); + $data['tpl']->assign("PASSWORD2",$data['password2']); + + $months = array('Month','January','February','March','April','May','June','July','August','September','October','November','December'); + $countries = array("US"=>"United States","AF"=>"Afghanistan","AL"=>"Albania","DZ"=>"Algeria","AS"=>"American Samoa","AD"=>"Andorra","AO"=>"Angola","AI"=>"Anguilla","AQ"=>"Antarctica","AG"=>"Antigua and Barbuda","AR"=>"Argentina","AM"=>"Armenia","AW"=>"Aruba","AU"=>"Australia","AT"=>"Austria","AZ"=>"Azerbaijan","BS"=>"Bahamas","BH"=>"Bahrain","BD"=>"Bangladesh","BB"=>"Barbados","BY"=>"Belarus","BE"=>"Belgium","BZ"=>"Belize","BJ"=>"Benin","BM"=>"Bermuda","BT"=>"Bhutan","BO"=>"Bolivia","BA"=>"Bosnia and Herzegowina","BW"=>"Botswana","BV"=>"Bouvet Island","br"=>"Brazili","IO"=>"British Indian Ocean Territory","BN"=>"Brunei Darussalam","BG"=>Bulgaria,"BF"=>"Burkina Faso","BI"=>"Burundi","KH"=>"Cambodia","CM"=>"Cameroon","CA"=>"Canada","CV"=>"Cape Verde","KY"=>"Cayman Islands","CF"=>"Central African Republic","TD"=>"Chad","CL"=>"Chile","CN"=>"China","CX"=>"Christmas Island","CC"=>"Cocoa (Keeling) Islands","CO"=>"Colombia","KM"=>"Comoros","CG"=>"Congo","CK"=>"Cook Islands","CR"=>"Costa Rica","CI"=>"Cote Divoire","CT"=>"Croatia (Hrvatska)","CU"=>"Cuba","CY"=>"Cyprus","CZ"=>"Czech Republic","DK"=>"Denmark","DJ"=>"Djibouti","DS"=>"DoDDs Schools","DM"=>"Dominica","DO"=>"Dominican Republic","TP"=>"East Timor","EC"=>"Ecuador","EG"=>"Egypt","SV"=>"El Salvador","GQ"=>"Equatorial Guinea","ER"=>"Eritrea","EE"=>"Estonia","ET"=>"Ethiopia","FK"=>"Falkland Islands (Malvinas)","FO"=>"Faroe Islands","FJ"=>"Fiji","FI"=>"Finland","FR"=>"France","GA"=>"Gabon","GM"=>"Gambia","GE"=>"Georgia","DE"=>"Germany","GH"=>"Ghana","GI"=>"Gibraltar","GR"=>"Greece","GL"=>"Greenland","GD"=>"Grenada","GU"=>"Guam","GT"=>"Guatemala","GN"=>"Guinea","GW"=>"Guinea-Bissau","GY"=>"Guyana","HT"=>"Haiti","HM"=>"Heard and Mc Donald Islands","HN"=>"Honduras","HK"=>"Hong Kong","HU"=>"Hungary","IS"=>"Iceland","IN"=>"India","ID"=>"Indonesia","IR"=>"Iran (Islamic Republic of)","IQ"=>"Iraq","IE"=>"Ireland","IL"=>"Israel","IT"=>"Italy","JM"=>"Jamaica","JP"=>"Japan","JO"=>"Jordan","KZ"=>"Kazakhstan","KE"=>"Kenya","KI"=>"Kiribati","KP"=>"Korea, Democratic Peoples Republic of","KR"=>"Korea, Republic of","KW"=>"Kuwait","KG"=>"Kyrgyzstan","LA"=>"Lao Peoples Democratic Republic","LV"=>"Latvia","LB"=>"Lebanon","LS"=>"Lesotho","LR"=>"Liberia","LY"=>"Libyan Arab Jamahiriya","LI"=>"Liechtenstein","LT"=>"Lithuania","LU"=>"Luxembourg","MO"=>"Macau","MK"=>"Macedonia, The Former Yugoslav Republic of","MG"=>"Madagascar","MW"=>"Malawi","MY"=>"Malaysia","MV"=>"Maldives","ML"=>"Mali","MT"=>"Malta","MH"=>"Marshall Islands","MR"=>"Mauritania","MU"=>"Mauritius","MX"=>"Mexico","FM"=>"Micronesia, Federated States of","MD"=>"Moldova, Republic of","MC"=>"Monaco","MN"=>"Mongolia","MS"=>"Montserrat","MA"=>"Morocco","MZ"=>"Mozambique","MM"=>"Myanmar","NA"=>"Namibia","NR"=>"Nauru","NP"=>"Nepal","NL"=>"Netherlands","AN"=>"Netherlands Antilles","NZ"=>"New Zealand","NI"=>"Nicaragua","NE"=>"Niger","NG"=>"Nigeria","NU"=>"Niue","NF"=>"Norfolk Island","MP"=>"Northern Mariana Islands","NO"=>"Norway","OM"=>"Oman","PK"=>"Pakistan","PW"=>"Palau","PA"=>"Panama","PG"=>"Papua New Guinea","PY"=>"Paraguay","PE"=>"Peru","PH"=>"Philippines","PN"=>"Pitcairn","PL"=>"Poland","PT"=>"Portugal","PR"=>"Puerto Rico","QA"=>"Qatar","RO"=>"Romania","RU"=>"Russian Federation","RW"=>"Rwanda","KN"=>"Saint Kitts and Nevis","LC"=>"Saint Lucia","VC"=>"Saint Vincent and the Grenadines","WS"=>"Samoa","SM"=>"San Marino","ST"=>"Sao Tome and Principe","SA"=>"Saudi Arabia","SN"=>"Senegal","SC"=>"Seychelles","SL"=>"Sierra Leone","SG"=>"Singapore","SK"=>"Slovakia (Slovak Republic)","SI"=>"Slovenia","Sb"=>"Solomon Islands","SO"=>"Somalia","ZA"=>"South Africa","GS"=>"South Georgia and the South Sandwich Islands","ES"=>"Spain","LK"=>"Sri Lanka","SH"=>"St. Helena","SD"=>"Sudan","SR"=>"Suriname","SJ"=>"Svalbard and Jan Mayen Islands","SZ"=>"Swaziland","SE"=>"Sweden","CH"=>"Switzerland","SY"=>"Syrian ArabRepublic","TW"=>"Taiwan","TJ"=>"Tajikistan","TZ"=>"Tanzania, United Republic of","TH"=>"Thailand","TG"=>"Togo","TK"=>"Tokelau","TO"=>"Tonga","TT"=>"Trinidad and Tobago","TN"=>"Tunisia","TR"=>"Turkey","TM"=>"Turkmenistan","TC"=>"Turks and Caicos Islands","TV"=>"Tuvalu","UG"=>"Uganda","UA"=>"Ukraine","AE"=>"United ArabEmirates","UK"=>"United Kingdom","UM"=>"United States Minor Outlying Islands","UY"=>"Uruguay","UZ"=>"Uzbekistan","VU"=>"Vanuatu","VA"=>"Vatican City State(Holy See)","VE"=>"Venezuela","VN"=>"Viet Nam","VG"=>"Virgin Islands (British)","VI"=>"Virgin Islands (U.S.)","EH"=>"Western Sahara","YE"=>"Yeman","YU"=>"Yugoslavia","ZR"=>"Zaire","ZM"=>"Zambia","ZW"=>"Zimbabwe"); + + for ($i = 0;$i < 13;$i++) { + if ($i == $data['bmonth']) + $bmonth .= "\n"; + else + $bmonth .= "\n"; + } + $data['tpl']->assign("BMONTH",$bmonth); + + $bday = "\n"; + for ($i = 1;$i <= 31;$i++) { + if ($i == $data['bday']) + $bday .= "\n"; + else + $bday .= "\n"; + } + $data['tpl']->assign("BDAY",$bday); + + $byear = "\n"; + for ($i = 2008;$i >= 1908;$i--) { + if ($i == $data['byear']) + $byear .= "\n"; + else + $byear .= "\n"; + } + $data['tpl']->assign("BYEAR",$byear); + + $country = "\n"; + + foreach ($countries as $key => $val) { + if ($key == $data['country']) + $country .= "\n"; + else + $country .= "\n"; + } + $data['tpl']->assign("COUNTRY",$country); + } + + + + $data['tpl']->assign("MESSAGE",$message); + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/remind.php b/docroot/remind.php new file mode 100644 index 0000000..9bb7d2c --- /dev/null +++ b/docroot/remind.php @@ -0,0 +1,20 @@ +","Thank you for registering with TUve

Please Click or goto the following link to confirm your email address http://www.tuve.tv/activate.php?data[active]=$active&data[email]=$email

Thank you,
The TUve Staff
","Reminder To Please Confirm Your E-Mail Address","support@tuve.tv","TUve Support"); + send_mail("Christopher Olsen ","Thank you for registering with TUve

Please Click or goto the following link to confirm your email address http://www.tuve.tv/activate.php?data[active]=$active&data[email]=$email

Thank you,
The TUve Staff
","Reminder To Please Confirm Your E-Mail Address","support@tuve.tv","TUve Support"); + } + +?> diff --git a/docroot/search.php b/docroot/search.php new file mode 100644 index 0000000..7649153 --- /dev/null +++ b/docroot/search.php @@ -0,0 +1,72 @@ +assign("PAGE_TITLE",""); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + $data[tpl]->define(array(body=>"/search.html")); + $data['tpl']->define(array("vs-rows"=>"vs-rows.html")); + + $skey = $data['search']; + + $data['tpl']->assign("SEARCH",$skey); + $gTypes = array('NA','Male','Female'); + + if ($data['stype'] == "people") { + $query = "SELECT uid,username,profile_image,caption,gender,byear,state_prov,country,laston FROM users WHERE username LIKE '%$skey%' OR firstname LIKE '%$skey%' OR lastname LIKE '%$skey%'"; + $res = mysql_query($query); + + for ($i = 0;$i < mysql_numrows($res);$i++) { + $username = mysql_result($res,$i,'username'); + $thumb = mysql_result($res,$i,'profile_image'); + $caption = mysql_result($res,$i,'caption'); + $gender = mysql_result($res,$i,'gender'); + $age = date("Y") - mysql_result($res,$i,'byear'); + $location = mysql_result($res,$i,'state_prov') . ", " . mysql_result($res,$i,'country'); + $laston = date("m/d/Y",mysql_result($res,$i,'laston')); + + $srows .= "
$username
Caption: $caption
Gender: $gTypes[$gender]
Age: $age
Location: $location
Last on: $laston\n"; + $srows .= "
"; + } + $data['tpl']->assign("SROWS",$srows); + } + else if ($data['stype'] == "video") { + if ($data['rating']) + $query = "SELECT vid,thumb,artist,title,length,count,username FROM videos v INNER JOIN users u ON v.oid = u.uid WHERE artist LIKE '%$skey%' OR title LIKE '%$skey%' AND rating <= $data[rating] ORDER BY artist,title"; + else + $query = "SELECT vid,thumb,artist,title,length,count,username FROM videos v INNER JOIN users u ON v.oid = u.uid WHERE artist LIKE '%$skey%' OR title LIKE '%$skey%' AND rating < 4 ORDER BY artist,title"; + $res = mysql_Query($query); + + for ($i = 0;$i < mysql_numrows($res);$i++) { + + $len = mysql_result($res,$i,'length'); + $fLen = "0"; + if ($len > 3600) { + $fLen = $len / 3600; + $len = $len % $fLen; + } + if ($len > 60) { + $fLen .= ":" . floor($len / 60); + } + $fLen .= ":" . $len % 60; + + $data['tpl']->assign("LENGTH",$fLen); + $data['tpl']->assign("VIEWS",mysql_result($res,$i,'count')); + $data['tpl']->assign("USERNAME",mysql_result($res,$i,'username')); + $data['tpl']->assign("VID",mysql_result($res,$i,'vid')); + $data['tpl']->assign("THUMB",mysql_result($res,$i,'thumb')); + $data['tpl']->assign("ARTIST",mysql_result($res,$i,'artist')); + $data['tpl']->assign("TITLE",mysql_result($res,$i,'title')); + $data['tpl']->parse("SROWS",".vs-rows"); + } + } + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/ss/SS200803-01.png b/docroot/ss/SS200803-01.png new file mode 100644 index 0000000..9f01b56 --- /dev/null +++ b/docroot/ss/SS200803-01.png Binary files differ diff --git a/docroot/stuff/HPIM2789.JPG b/docroot/stuff/HPIM2789.JPG new file mode 100644 index 0000000..a4ab5a4 --- /dev/null +++ b/docroot/stuff/HPIM2789.JPG Binary files differ diff --git a/docroot/stuff/Picture 1.jpg b/docroot/stuff/Picture 1.jpg new file mode 100644 index 0000000..beaf8e7 --- /dev/null +++ b/docroot/stuff/Picture 1.jpg Binary files differ diff --git a/docroot/stuff/Picture 2.jpg b/docroot/stuff/Picture 2.jpg new file mode 100644 index 0000000..442108d --- /dev/null +++ b/docroot/stuff/Picture 2.jpg Binary files differ diff --git a/docroot/stuff/Picture 3.jpg b/docroot/stuff/Picture 3.jpg new file mode 100644 index 0000000..8508198 --- /dev/null +++ b/docroot/stuff/Picture 3.jpg Binary files differ diff --git a/docroot/stuff/Picture 4.jpg b/docroot/stuff/Picture 4.jpg new file mode 100644 index 0000000..7080a00 --- /dev/null +++ b/docroot/stuff/Picture 4.jpg Binary files differ diff --git a/docroot/test.txt b/docroot/test.txt new file mode 100644 index 0000000..2488cbf --- /dev/null +++ b/docroot/test.txt @@ -0,0 +1,5 @@ +IP: 72.36.169.162 - FTP out 3947248 bytes sent in 00:08 (475.72 KB/s) +IP: 72.36.169.163 - FTP out 3947248 bytes sent in 00:07 (487.97 KB/s) +IP: 72.36.169.164 - FTP out 3947248 bytes sent in 01:01 (62.71 KB/s) +IP: 73.36.169.165 - FTP out 3947248 bytes sent in 00:46 (83.59 KB/s) +IP: 73.36.169.166 - FTP out 3947248 bytes sent in 00:07 (488.53 KB/s) diff --git a/docroot/tmp.html b/docroot/tmp.html new file mode 100644 index 0000000..68c6ab0 --- /dev/null +++ b/docroot/tmp.html @@ -0,0 +1,4 @@ +
+ + +
diff --git a/docroot/topvideos.php b/docroot/topvideos.php new file mode 100644 index 0000000..0113db1 --- /dev/null +++ b/docroot/topvideos.php @@ -0,0 +1,44 @@ +assign("PAGE_TITLE","News"); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + $data[tpl]->define(array(body=>"/topvideos.html")); + + //DoSession(); + + if ($data['max'] == "") + $maxLim = 10; + else + $maxLim = $data['max']; + + $query = "SELECT vid,thumb,artist,title,genre,classification,rating,count FROM videos WHERE classification != 7 ORDER BY count DESC LIMIT 0,$maxLim"; + $result = mysql_query($query); + + $classes = array('None','Music Video','TV','Anime/Toons','Movie','Documentary','Original'); + $ratings = array('None','G','PG','13+','MA','AD'); + + for ($i=0;$i < $maxLim;$i++) { + $thumb = mysql_result($result,$i,'thumb'); + $artist = mysql_result($result,$i,'artist'); + $title = mysql_result($result,$i,'title'); + $genre = mysql_result($result,$i,'genre'); + $count = mysql_result($result,$i,'count'); + $vclass = mysql_result($result,$i,'classification'); + $rating = mysql_result($result,$i,'rating'); + $rows .= "Artist: $artist
Title: $title
Genre: $genre
Classification: $classes[$vclass]
Rating: $ratings[$rating]
Played: $count Times\n"; + $rows .= "
\n"; + } + + $data['tpl']->assign("ROWS",$rows); + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/tuvestyles.css b/docroot/tuvestyles.css new file mode 100644 index 0000000..43ffc6f --- /dev/null +++ b/docroot/tuvestyles.css @@ -0,0 +1,56 @@ +.copyright_text { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; font-style: normal; line-height: 13px; font-weight: bold; font-variant: normal; text-transform: none; color: #333333; text-decoration: none} + +.main { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 14px; font-style: normal; line-height: 14px; font-weight: 100; font-variant: normal; text-transform: none; color: #333333; text-decoration: none} + +.mainBold { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 14px; font-style: normal; line-height: 14px; font-weight: bold; font-variant: normal; text-transform: none; color: #333333; text-decoration: none} + +.channels { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 12px; font-style: normal; line-height: 14px; font-weight: 100; font-variant: normal; text-transform: none; color: #333333; text-decoration: none} + +.linksmain { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 16px; font-style: normal; line-height: 13px; font-weight: bold; font-variant: normal; text-transform: none; color: #333333; text-decoration: none} + +.linksreg { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 12px; font-style: normal; line-height: 14px; font-weight: bold; font-variant: normal; text-transform: none; color: #333333; text-decoration: underline} + +.linksmenu { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; font-style: normal; line-height: 12px; font-weight: bold; font-variant: normal; text-transform: none; color: #333333; text-decoration: underline} + +.schedule { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; font-style: normal; line-height: 11px; font-weight: 100; font-variant: normal; text-transform: none; color: #000000; text-decoration: none} + +.linksschedule { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; font-style: normal; line-height: 12px; font-weight: bold; font-variant: normal; text-transform: none; color: #333333; text-decoration: underline} + +.selectschedule { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 14px; color : #000000; font-weight: normal; background: #FFFFFF; scrollbar-base-color: #acacac; scrollbar-face-color:#577C9E; scrollbar-shadow-color:#E5DFBF; scrollbar-highlight-color:#E5DFBF; scrollbar-3dlight-color:#336699; scrollbar-darkshadow-color: #333333; scrollbar-track-color:#E5DFBF; scrollbar-arrow-color:#E5DFBF; } + +.inventory { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; font-style: normal; line-height: 11px; font-weight: 100; font-variant: normal; text-transform: none; color: #000000; text-decoration: none} + +.admin_users { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; font-style: normal; line-height: 11px; font-weight: 100; font-variant: normal; text-transform: none; color: #000000; text-decoration: none} + +.linksinventory { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; font-style: normal; line-height: 12px; font-weight: bold; font-variant: normal; text-transform: none; color: #333333; text-decoration: underline} + +.checkboxinventory { padding: 0px; margin: 0px; float:left; width: 14px; height: 14px; } + +.selectinventory { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; color : #000000; font-weight: normal; background: #FFFFFF; scrollbar-base-color: #acacac; scrollbar-face-color:#577C9E; scrollbar-shadow-color:#E5DFBF; scrollbar-highlight-color:#E5DFBF; scrollbar-3dlight-color:#336699; scrollbar-darkshadow-color: #333333; scrollbar-track-color:#E5DFBF; scrollbar-arrow-color:#E5DFBF; } + +.textboxinventory { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px;} + +.textboxinventory_row { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; height: 15px; padding: 0px;} + +.settings-textbox { + font-family : 'Sans Serif'; + font-size : 16px; + font-style : normal; + font-weight : 300; + height: 20px; + padding: 0px; + border-bottom-style: inset; + border-left-style: inset; + border-right-style: inset; + border-top-style: inset; + } + +.settings { + font-family: 'Sans Serif'; + font-size: 16px; + font-style: normal; + font-weight: 300; + text-transform: none; + color: #000000; + text-decoration: none; + } diff --git a/docroot/ubChattin.php b/docroot/ubChattin.php new file mode 100644 index 0000000..f8d1d70 --- /dev/null +++ b/docroot/ubChattin.php @@ -0,0 +1,17 @@ + +We have come up with a widget to get people into the tuve network the code to do this is bellow as well as the widget sample
+
+<object width="570" height="595">
+<param name="movie" value="http://www.ubixonline.com/beta/ubChattin.swf">
+<embed src="http://www.ubixonline.com/beta/ubChattin.swf" width="570" height="595">
+</embed>
+</object>
+

+ + + + + + + + \ No newline at end of file diff --git a/docroot/upload.php b/docroot/upload.php new file mode 100644 index 0000000..01fe533 --- /dev/null +++ b/docroot/upload.php @@ -0,0 +1,33 @@ +' . "\r\n"; + + $message = "User: " . $_GET['userName'] . "\nArtist: " . $_GET['artist'] . "\nTitle: " . $_GET['title'] . "\nGenre: " . $_GET['genre'] . "\nClassification: " . $_GET['classification'] . "\nRating: " . $_GET['rating'] . "\nFile: $uploadfile [$file2]\n\n"; + +if (move_uploaded_file($_FILES['Filedata']['tmp_name'],$uploaddir . $file2)) { + $oid = $_GET['oid']; + $cid = $_GET['cid']; + $rid = $_GET['rid']; + $artist = $_GET['artist']; + $title = $_GET['title']; + $genre = $_GET['genre']; + + $query = "INSERT INTO videos_pending (oid,classification,rating,artist,title,genre,file,encoded) VALUES($oid,$cid,$rid,'$artist','$title','$genre',\"$uploadfile\",0)"; + mysql_query($query); + mail("Christopher Olsen ","New Media",$message,$headers); +} +else { + mail("Christopher Olsen ","ERROR: Media","Error W/ Media",$headers); + return(false); + } +?> diff --git a/docroot/view.php b/docroot/view.php new file mode 100644 index 0000000..387c962 --- /dev/null +++ b/docroot/view.php @@ -0,0 +1,69 @@ +assign("PAGE_TITLE",""); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + $data[tpl]->define(array(body=>"view.html")); + $data['tpl']->define(array(view_row=>"view-row.html")); + + //DoSession(); + + + $query = "SELECT artist,title,oid,username FROM videos v INNER JOIN users u ON v.oid = u.uid WHERE vid = $data[vid]"; + $res = mysql_query($query); + + if ($res) { + $OID = mysql_result($res,0,'oid'); + $vTitle = "Artist: " . mysql_result($res,0,'artist') . "
Title: " . mysql_result($res,0,'title'); + $data['tpl']->assign("CVID",$data['vid']); + $data['tpl']->assign("VID_TITLE",$vTitle); + $data['tpl']->assign("USER",mysql_result($res,0,'username')); + } + + + if ($data['rating']) + $query = "SELECT vid,artist,title,thumb,count,length FROM videos WHERE oid = $OID AND rating <= $data[rating] AND mType = 1 ORDER BY arist,title"; + else + $query = "SELECT vid,artist,title,thumb,count,length FROM videos WHERE oid = $OID AND rating < 4 AND mType = 1 ORDER BY artist,title"; + $res = mysql_query($query); + + //$rows = mysq_num_rows($res); + + for ($i = 0;$i < mysql_num_rows($res) && $i < 20;$i++) { + $len = mysql_result($res,$i,'length'); + + $fLen = "0"; + + if ($len > 3600) { + $fLen = $len / 3600; + $len = $len % $fLen; + } + + if ($len > 60) { + $fLen .= ":" . floor($len / 60); + } + + $fLen .= ":" . $len % 60; + + $data['tpl']->assign("LENGTH",$fLen); + $data['tpl']->assign("ARTIST",mysql_result($res,$i,'artist')); + $data['tpl']->assign("TITLE",mysql_result($res,$i,'title')); + $data['tpl']->assign("VID",mysql_result($res,$i,'vid')); + $data['tpl']->assign("THUMB",mysql_result($res,$i,'thumb')); + $data['tpl']->assign("VIEWS",mysql_result($res,$i,'count')); + $data['tpl']->parse("NEW_VIDS",".view_row"); + } + + + + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/docroot/widget.php b/docroot/widget.php new file mode 100644 index 0000000..570ceda --- /dev/null +++ b/docroot/widget.php @@ -0,0 +1,21 @@ +assign("PAGE_TITLE","ubChattin - Widget"); + + /* Main defines */ + $data[tpl]->define(array(index=>"index/index.html")); + $data[tpl]->define(array(body=>"/widget.html")); + + //DoSession(); + + $data['tpl']->assign("TIME",time()); + + /* Parse and print */ + $data[tpl]->parse(BODY, array("body")); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); +?> diff --git a/include/fasttemp.inc b/include/fasttemp.inc new file mode 100755 index 0000000..15715a4 --- /dev/null +++ b/include/fasttemp.inc @@ -0,0 +1,753 @@ +set_root($pathToTemplates); + } + + } // end (new) FastTemplate () + + +// ************************************************************ +// All templates will be loaded from this "root" directory +// Can be changed in mid-process by re-calling with a new +// value. + + function set_root ($root) + { + $trailer = substr($root,-1); + + if(!$this->WIN32) + { + if( (ord($trailer)) != 47 ) + { + $root = "$root". chr(47); + } + + if(is_dir($root)) + { + $this->ROOT = $root; + } + else + { + $this->ROOT = ""; + $this->error("Specified ROOT dir [$root] is not a directory"); + } + } + else + { + // WIN32 box - no testing + if( (ord($trailer)) != 92 ) + { + $root = "$root" . chr(92); + } + $this->ROOT = $root; + } + + } // End set_root() + + +// ************************************************************** +// Calculates current microtime +// I throw this into all my classes for benchmarking purposes +// It's not used by anything in this class and can be removed +// if you don't need it. + + + function utime () + { + $time = explode( " ", microtime()); + $usec = (double)$time[0]; + $sec = (double)$time[1]; + return $sec + $usec; + } + +// ************************************************************** +// Strict template checking, if true sends warnings to STDOUT when +// parsing a template with undefined variable references +// Used for tracking down bugs-n-such. Use no_strict() to disable. + + function strict () + { + $this->STRICT = true; + } + +// ************************************************************ +// Silently discards (removes) undefined variable references +// found in templates + + function no_strict () + { + $this->STRICT = false; + } + +// ************************************************************ +// A quick check of the template file before reading it. +// This is -not- a reliable check, mostly due to inconsistencies +// in the way PHP determines if a file is readable. + + function is_safe ($filename) + { + if(!file_exists($filename)) + { + $this->error("[$filename] does not exist",0); + return false; + } + return true; + } + +// ************************************************************ +// Grabs a template from the root dir and +// reads it into a (potentially REALLY) big string + + function get_template ($template) + { + if(empty($this->ROOT)) + { + $this->error("Cannot open template. Root not valid.",1); + return false; + } + + $filename = "$this->ROOT"."$template"; + $contents = implode("",(@file($filename))); + if( (!$contents) or (empty($contents)) ) + { + $this->error("get_template() failure: [$filename] $php_errormsg",1); + } + + return $contents; + + } // end get_template + +// ************************************************************ +// Prints the warnings for unresolved variable references +// in template files. Used if STRICT is true + + function show_unknowns ($Line) + { + $unknown = array(); + if (ereg("({[A-Z0-9_]+})",$Line,$unknown)) + { + $UnkVar = $unknown[1]; + if(!(empty($UnkVar))) + { + @error_log("[FastTemplate] Warning: no value found for variable: $UnkVar ",0); + } + } + } // end show_unknowns() + +// ************************************************************ +// This routine get's called by parse() and does the actual +// {VAR} to VALUE conversion within the template. + + function parse_template ($template, $tpl_array) + { + while ( list ($key,$val) = each ($tpl_array) ) + { + if (!(empty($key))) + { + if(gettype($val) != "string") + { + settype($val,"string"); + } + + // php4 doesn't like '{$' combinations. + $key = '{'."$key".'}'; + $template = ereg_replace("$key","$val","$template"); + //$template = str_replace("$key","$val","$template"); + } + } + + if(!$this->STRICT) + { + // Silently remove anything not already found + + $template = ereg_replace("{([A-Z0-9_]+)}","",$template); + } + else + { + // Warn about unresolved template variables + if (ereg("({[A-Z0-9_]+})",$template)) + { + $unknown = split("\n",$template); + while (list ($Element,$Line) = each($unknown) ) + { + $UnkVar = $Line; + if(!(empty($UnkVar))) + { + $this->show_unknowns($UnkVar); + } + } + } + } + return $template; + + } // end parse_template(); + +// ************************************************************ +// The meat of the whole class. The magic happens here. + + function parse ( $ReturnVar, $FileTags ) + { + $append = false; + $this->LAST = $ReturnVar; + $this->HANDLE[$ReturnVar] = 1; + + if (gettype($FileTags) == "array") + { + unset($this->$ReturnVar); // Clear any previous data + + while ( list ( $key , $val ) = each ( $FileTags ) ) + { + if ( (!isset($this->$val)) || (empty($this->$val)) ) + { + $this->LOADED["$val"] = 1; + if(isset($this->DYNAMIC["$val"])) + { + $this->parse_dynamic($val,$ReturnVar); + } + else + { + $fileName = $this->FILELIST[$val]; + $this->$val = $this->get_template($fileName); + } + } + + // Array context implies overwrite + + $this->$ReturnVar = $this->parse_template($this->$val,$this->PARSEVARS); + + // For recursive calls. + + $this->assign( array( $ReturnVar => $this->$ReturnVar ) ); + + } + } // end if FileTags is array() + else + { + // FileTags is not an array + + $val = $FileTags; + + if( (substr($val,0,1)) == '.' ) + { + // Append this template to a previous ReturnVar + + $append = true; + $val = substr($val,1); + } + + if ( (!isset($this->$val)) || (empty($this->$val)) ) + { + $this->LOADED["$val"] = 1; + if(isset($this->DYNAMIC["$val"])) + { + $this->parse_dynamic($val,$ReturnVar); + } + else + { + $fileName = $this->FILELIST[$val]; + $this->$val = $this->get_template($fileName); + } + } + + if($append) + { + $this->$ReturnVar .= $this->parse_template($this->$val,$this->PARSEVARS); + } + else + { + $this->$ReturnVar = $this->parse_template($this->$val,$this->PARSEVARS); + } + + // For recursive calls. + + $this->assign(array( $ReturnVar => $this->$ReturnVar) ); + + } + return; + } // End parse() + + +// ************************************************************ + + function FastPrint ( $template = "" ) + { + if(empty($template)) + { + $template = $this->LAST; + } + + if( (!(isset($this->$template))) || (empty($this->$template)) ) + { + $this->error("Nothing parsed, nothing printed",0); + return; + } + else + { + print $this->$template; + } + return; + } + +// ************************************************************ + + function fetch ( $template = "" ) + { + if(empty($template)) + { + $template = $this->LAST; + } + if( (!(isset($this->$template))) || (empty($this->$template)) ) + { + $this->error("Nothing parsed, nothing printed",0); + return ""; + } + + return($this->$template); + } + + +// ************************************************************ + + function define_dynamic ($Macro, $ParentName) + { + // A dynamic block lives inside another template file. + // It will be stripped from the template when parsed + // and replaced with the {$Tag}. + + $this->DYNAMIC["$Macro"] = $ParentName; + return true; + } + +// ************************************************************ + + function parse_dynamic ($Macro,$MacroName) + { + // The file must already be in memory. + + $ParentTag = $this->DYNAMIC["$Macro"]; + if( (!$this->$ParentTag) or (empty($this->$ParentTag)) ) + { + $fileName = $this->FILELIST[$ParentTag]; + $this->$ParentTag = $this->get_template($fileName); + $this->LOADED[$ParentTag] = 1; + } + if($this->$ParentTag) + { + $template = $this->$ParentTag; + $DataArray = split("\n",$template); + $newMacro = ""; + $newParent = ""; + $outside = true; + $start = false; + $end = false; + while ( list ($lineNum,$lineData) = each ($DataArray) ) + { + $lineTest = trim($lineData); + if("" == "$lineTest" ) + { + $start = true; + $end = false; + $outside = false; + } + if("" == "$lineTest" ) + { + $start = false; + $end = true; + $outside = true; + } + if( (!$outside) and (!$start) and (!$end) ) + { + $newMacro .= "$lineData\n"; // Restore linebreaks + } + if( ($outside) and (!$start) and (!$end) ) + { + $newParent .= "$lineData\n"; // Restore linebreaks + } + if($end) + { + $newParent .= '{'."$MacroName}\n"; + } + // Next line please + if($end) { $end = false; } + if($start) { $start = false; } + } // end While + + $this->$Macro = $newMacro; + $this->$ParentTag = $newParent; + return true; + + } // $ParentTag NOT loaded - MAJOR oopsie + else + { + @error_log("ParentTag: [$ParentTag] not loaded!",0); + $this->error("ParentTag: [$ParentTag] not loaded!",0); + } + return false; + } + +// ************************************************************ +// Strips a DYNAMIC BLOCK from a template. + + function clear_dynamic ($Macro="") + { + if(empty($Macro)) { return false; } + + // The file must already be in memory. + + $ParentTag = $this->DYNAMIC["$Macro"]; + + if( (!$this->$ParentTag) or (empty($this->$ParentTag)) ) + { + $fileName = $this->FILELIST[$ParentTag]; + $this->$ParentTag = $this->get_template($fileName); + $this->LOADED[$ParentTag] = 1; + } + + if($this->$ParentTag) + { + $template = $this->$ParentTag; + $DataArray = split("\n",$template); + $newParent = ""; + $outside = true; + $start = false; + $end = false; + while ( list ($lineNum,$lineData) = each ($DataArray) ) + { + $lineTest = trim($lineData); + if("" == "$lineTest" ) + { + $start = true; + $end = false; + $outside = false; + } + if("" == "$lineTest" ) + { + $start = false; + $end = true; + $outside = true; + } + if( ($outside) and (!$start) and (!$end) ) + { + $newParent .= "$lineData\n"; // Restore linebreaks + } + // Next line please + if($end) { $end = false; } + if($start) { $start = false; } + } // end While + + $this->$ParentTag = $newParent; + return true; + + } // $ParentTag NOT loaded - MAJOR oopsie + else + { + @error_log("ParentTag: [$ParentTag] not loaded!",0); + $this->error("ParentTag: [$ParentTag] not loaded!",0); + } + return false; + } + + +// ************************************************************ + + function define ($fileList) + { + while ( list ($FileTag,$FileName) = each ($fileList) ) + { + $this->FILELIST[$FileTag] = $FileName; + } + return true; + } + +// ************************************************************ + + function clear_parse ( $ReturnVar = "") + { + $this->clear($ReturnVar); + } + +// ************************************************************ + + function clear ( $ReturnVar = "" ) + { + // Clears out hash created by call to parse() + + if(!empty($ReturnVar)) + { + if( (gettype($ReturnVar)) != "array") + { + unset($this->$ReturnVar); + return; + } + else + { + while ( list ($key,$val) = each ($ReturnVar) ) + { + unset($this->$val); + } + return; + } + } + + // Empty - clear all of them + + while ( list ( $key,$val) = each ($this->HANDLE) ) + { + $KEY = $key; + unset($this->$KEY); + } + return; + + } // end clear() + +// ************************************************************ + + function clear_all () + { + $this->clear(); + $this->clear_assign(); + $this->clear_define(); + $this->clear_tpl(); + + return; + + } // end clear_all + +// ************************************************************ + + function clear_tpl ($fileHandle = "") + { + if(empty($this->LOADED)) + { + // Nothing loaded, nothing to clear + + return true; + } + if(empty($fileHandle)) + { + // Clear ALL fileHandles + + while ( list ($key, $val) = each ($this->LOADED) ) + { + unset($this->$key); + } + unset($this->LOADED); + + return true; + } + else + { + if( (gettype($fileHandle)) != "array") + { + if( (isset($this->$fileHandle)) || (!empty($this->$fileHandle)) ) + { + unset($this->LOADED[$fileHandle]); + unset($this->$fileHandle); + return true; + } + } + else + { + while ( list ($Key, $Val) = each ($fileHandle) ) + { + unset($this->LOADED[$Key]); + unset($this->$Key); + } + return true; + } + } + + return false; + + } // end clear_tpl + +// ************************************************************ + + function clear_define ( $FileTag = "" ) + { + if(empty($FileTag)) + { + unset($this->FILELIST); + return; + } + + if( (gettype($Files)) != "array") + { + unset($this->FILELIST[$FileTag]); + return; + } + else + { + while ( list ( $Tag, $Val) = each ($FileTag) ) + { + unset($this->FILELIST[$Tag]); + } + return; + } + } + +// ************************************************************ +// Aliased function - used for compatibility with CGI::FastTemplate + //function clear_parse () + //{ + // $this->clear_assign(); + //} + +// ************************************************************ +// Clears all variables set by assign() + + function clear_assign () + { + if(!(empty($this->PARSEVARS))) + { + while(list($Ref,$Val) = each ($this->PARSEVARS) ) + { + unset($this->PARSEVARS["$Ref"]); + } + } + } + +// ************************************************************ + + function clear_href ($href) + { + if(!empty($href)) + { + if( (gettype($href)) != "array") + { + unset($this->PARSEVARS[$href]); + return; + } + else + { + while (list ($Ref,$val) = each ($href) ) + { + unset($this->PARSEVARS[$Ref]); + } + return; + } + } + else + { + // Empty - clear them all + + $this->clear_assign(); + } + return; + } + +// ************************************************************ + + function assign ($tpl_array, $trailer="") + { + if(gettype($tpl_array) == "array") + { + while ( list ($key,$val) = each ($tpl_array) ) + { + if (!(empty($key))) + { + // Empty values are allowed + // Empty Keys are NOT + + $this->PARSEVARS["$key"] = $val; + } + } + } + else + { + // Empty values are allowed in non-array context now. + if (!empty($tpl_array)) + { + $this->PARSEVARS["$tpl_array"] = $trailer; + } + } + } + +// ************************************************************ +// Return the value of an assigned variable. +// Christian Brandel cbrandel@gmx.de + + function get_assigned($tpl_name = "") + { + if(empty($tpl_name)) { return false; } + if(isset($this->PARSEVARS["$tpl_name"])) + { + return ($this->PARSEVARS["$tpl_name"]); + } + else + { + return false; + } + } + +// ************************************************************ + + function error ($errorMsg, $die = 0) + { + $this->ERROR = $errorMsg; + echo "ERROR: $this->ERROR
\n"; + if ($die == 1) + { + exit; + } + + return; + + } // end error() + + +// ************************************************************ + + + +// ************************************************************ + +} // End class.FastTemplate.php3 + +?> diff --git a/include/funcs.inc b/include/funcs.inc new file mode 100755 index 0000000..02e89b6 --- /dev/null +++ b/include/funcs.inc @@ -0,0 +1,157 @@ +".$eol; + $headers .= "Reply-To: ".$fromname."<".$fromaddress.">".$eol; + $headers .= "Return-Path: ".$fromname."<".$fromaddress.">".$eol; // these two to set reply address + $headers .= "Message-ID: <".time()."-".$fromaddress.">".$eol; + $headers .= "X-Mailer: PHP v".phpversion().$eol; // These two to help avoid spam-filters + + # Boundry for marking the split & Multitype Headers + $headers .= 'MIME-Version: 1.0'.$eol; + $headers .= "Content-Type: multipart/alternative; $eol boundary=\"".$mime_boundary."\"".$eol; + + $msg = "This is a multi-part message in MIME format.$eol"; + # Open the first part of the mail + $msg .= "--".$mime_boundary.$eol; + + # Text Version + $msg .= "--".$mime_boundary.$eol; + $msg .= "Content-Type: text/plain; charset=iso-8859-1".$eol; + $msg .= "Content-Transfer-Encoding: 8bit".$eol.$eol; + $msg .= strip_tags(str_replace("
", "\r\n", substr($body, (strpos($body, "")+6)))).$eol.$eol; + + # HTML Version + $msg .= "--".$mime_boundary.$eol; + $msg .= "Content-Type: text/html; charset=iso-8859-1".$eol; + $msg .= "Content-Transfer-Encoding: 8bit".$eol.$eol; + $msg .= $body.$eol.$eol; + + if ($attachments !== false) + { + for($i=0; $i < count($attachments); $i++) + { + if (is_file($attachments[$i]["file"])) + { + # File for Attachment + $file_name = substr($attachments[$i]["file"], (strrpos($attachments[$i]["file"], "/")+1)); + + $handle=fopen($attachments[$i]["file"], 'rb'); + $f_contents=fread($handle, filesize($attachments[$i]["file"])); + $f_contents=chunk_split(base64_encode($f_contents)); //Encode The Data For Transition using base64_encode(); + $f_type=filetype($attachments[$i]["file"]); + fclose($handle); + + # Attachment + $msg .= "--".$mime_boundary.$eol; + $msg .= "Content-Type: ".$attachments[$i]["content_type"]."; name=\"".$file_name."\"".$eol; // sometimes i have to send MS Word, use 'msword' instead of 'pdf' + $msg .= "Content-Transfer-Encoding: base64".$eol; + $msg .= "Content-Description: ".$file_name.$eol; + $msg .= "Content-Disposition: attachment; filename=\"".$file_name."\"".$eol.$eol; // !! This line needs TWO end of lines !! IMPORTANT !! + $msg .= $f_contents.$eol.$eol; + } + } + } + + # Finished + $msg .= "--".$mime_boundary."--".$eol.$eol; // finish with two eol's for better security. see Injection. + + # SEND THE EMAIL + ini_set(sendmail_from,$fromaddress); // the INI lines are to force the From Address to be used ! + $mail_sent = mail($to, $subject, $msg, $headers); + + ini_restore(sendmail_from); + + return $mail_sent; +} + + +function makeRating($rating) { + $ret = "\n"; + return($ret); + } + + + + +function getCompany($data,$cid) { + if ($cid == -1) + return("Everyone"); + else { + $query = "SELECT company FROM users WHERE UID='$cid'"; + $result = mysql_query($query); + return(mysql_result($result,0,'company')); + } + } + +function getGroup($data,$gid) { + $query = "SELECT * FROM groups WHERE id='$gid'"; + $result = mysql_query($query); + return(mysql_result($result,0,'group')); + } + +function mkGroupList($data) { + $group = "\n"; + if ($data[lg] != "") { + $query = "SELECT * FROM groups WHERE id > 1"; + $gid = $data[lg]; + } + else { + $query = "SELECT * FROM groups"; + $gid = $data[gid]; + } + $result = mysql_query($query); + $rows = mysql_numrows($result); + for ($i=0;$i<$rows;$i++) { + $id = mysql_result($result,$i,'id'); + if ($gid == $id) + $sel = "SELECTED"; + else + $sel = ""; + $group .= "\n"; + } + return($group); + } + +function mkCompanyList($data) { + $company = "\n"; + if ($data[gid] == 1) + $query = "SELECT company,uid FROM users WHERE GID = 2 AND active = 1 ORDER BY company"; + else + $query = "SELECT company,uid FROM users WHERE UID='$data[uid]' ORDER BY company"; + $result = mysql_query($query); + $num = mysql_numrows($result); + if ($data[company] == -1) + $sel = "SELECTED"; + $company .= "\n"; + for ($i=0;$i<$num;$i++) { + $uid = mysql_result($result,$i,'uid'); + if ($data[company] == $uid) + $sel = "SELECTED"; + else + $sel = ""; + $company .= "\n"; + } + return($company); + } + +?> diff --git a/include/session.inc b/include/session.inc new file mode 100755 index 0000000..7143bab --- /dev/null +++ b/include/session.inc @@ -0,0 +1,162 @@ +"; + $exp = time(); + $query = "DELETE FROM sessions WHERE EXPIRE < $exp"; + mysql_query($query); + if (($data['STV'] != '') && ($data['login'] != 'yes') && ($data['logout'] == '')) { + ContinueSession($data); + } + else { + SetNewSession($data); + } + $data['uid'] = GetUid($data); + $data['user_type'] = GetGid($data); + } + +function AccessAllowed($user_id, $section_name) { + $query = "SELECT IF (EXISTS(SELECT aarum.user_id FROM admin_area_role_user_map aarum + INNER JOIN users u ON aarum.user_id = u.id + INNER JOIN admin_areas aa ON aa.admin_area_id = aarum.admin_area_id + INNER JOIN admin_roles ar ON ar.admin_role_id = aarum.admin_role_id + WHERE ar.admin_role = 'admin' AND u.id = $user_id AND aa.admin_area = '$section_name' + GROUP BY u.id), 1, 0);"; + $result = mysql_query($query); + + if (mysql_result($result, 0, 0) == 1) { + return true; + } + return false; +} + +function CheckAccess(&$data, $section) { + if (!AccessAllowed($data[uid], $section)) { + $data[tpl]->define(array(index=>"index/index.html")); + $data[bdy] .= "

Sorry, you do not have access to this area.

"; + $data[tpl]->assign(BODY,$data[bdy]); + $data[tpl]->parse(INDEX, array("index")); + $data[tpl]->FastPrint("INDEX"); + exit(); + } +} + +function AccessDenied(&$data) { + $data[idletime] = "600"; + $data[bdy] = ">
"; + $exp = time(); + $query = "DELETE FROM sessions WHERE EXPIRE < $exp"; + mysql_query($query); + $data[bdy] .= "

Access Denied

"; + $data[login] = ''; + SetNewSession($data); + $data[uid] = GetUid($data); + $data[user_type] = GetGid($data); + } + + +function ContinueSession(&$data) { + $exp2 = time()+27200; + $query = "SELECT * FROM sessions WHERE SESSIONID='$data[STV]'"; + $result = mysql_query($query); + if (mysql_numrows($result) > 0) { + $data[uid] = mysql_result($result,0,'uid'); + $data[gid] = mysql_result($result,0,'gid'); + $exp = time()+$data[idletime]; + $expire = date("D, d-M-Y H:i:s",$exp2); + $query = "UPDATE sessions SET EXPIRE='$exp' WHERE SESSIONID='$data[STV]'"; + mysql_query($query); + //Header("Set-Cookie: data[STV]=$data[STV]; expires=$expire GMT; path=/;"); + Header("Set-Cookie: data[STV]=$data[STV]; path=/;"); + } + else { + header("Set-Cookie: data[STV]=; path=/;"); + $data[bdy] .= "

Sorry your login has expired.

"; + SetNewSession($data); + exit; + } + } + + +function GetUid($data) { + $query = "SELECT UID FROM sessions WHERE SESSIONID='$data[STV]'"; + $result = mysql_query($query); + if (mysql_numrows($result) > 0) { + return mysql_result($result,0,'UID'); + } + else { + return 0; + } + } +function GetGid($data) { + $query = "SELECT GID FROM sessions WHERE SESSIONID='$data[STV]'"; + $result = mysql_query($query); + if (mysql_numrows($result) > 0) { + return mysql_result($result,0,'GID'); + } + else { + return 0; + } + } + +function SetNewSession(&$data) { + if ($data['login'] == '') { + $data['login'] = "yes"; + $data['tpl']->define(array('index'=>"index/index.html")); + $data['bdy'] .= "
\n"; + $data['bdy'] .= "\n"; + while (list($key,$val) = each($data)) { + if ($key == "login") { $val = "yes"; } + if (($key != "bdy") && ($key != "tpl")) { + $data['bdy'] .= "\n"; + } + } + $data['bdy'] .= ""; + $data['bdy'] .= "\n"; + $data['bdy'] .= "\n"; + $data['bdy'] .= "\n"; + $data['bdy'] .= "

Press Tab to Continue to Next Field

Username:

Password:

 
\n
\n"; + $data['bdy'] .= "
\n"; + $data['tpl']->assign('BODY',$data['bdy']); + $data['tpl']->parse('MENU', array("menu")); + $data['tpl']->parse('INDEX', array("index")); + $data['tpl']->FastPrint("INDEX"); + exit; + } + else { + $query = "SELECT * FROM users WHERE username='$data[user]'"; + $result = mysql_query($query); + if (mysql_numrows($result) > 0) { + if (urlencode($data[pass]) != mysql_result($result,0,'pass')) { + $data[bdy] .= "

Sorry Incorrect Password.

"; + $data[login]=''; + SetNewSession($data); + } + else { + $uid = mysql_result($result,0,'uid'); + $gid = mysql_result($result,0,'gid'); + $exp = time()+$data[idletime]; + $exp2 = time()+27200; + $expires = date("D, d-M-Y H:i:s",$exp2); + srand((double)microtime()*1000000); + $session = md5(rand(0,9999999)); + $query = "INSERT INTO sessions (SESSIONID,UID,GID,EXPIRE) VALUES('$session','$uid','$gid','$exp')"; + mysql_query($query); + $time = time(); + $query = "UPDATE users SET lastlogon = $time WHERE uid = $uid"; + mysql_query($query); + //header("Set-Cookie: data[STV]=$session; expires=$expires GMT; path=/;"); + Header("Set-Cookie: data[STV]=$session; path=/;"); + $data[STV] = $session; + $data[uid] = $uid; + $data[gid] = $gid; + } + } + else { + $data[bdy] .= "

Sorry This User Does Not Exist

"; + $data[login]=''; + SetNewSession($data); + } + } + } +?> diff --git a/include/site.inc b/include/site.inc new file mode 100755 index 0000000..584961e --- /dev/null +++ b/include/site.inc @@ -0,0 +1,41 @@ +assign("SELF","$data[url]"); + $data['REMOTE_ADDR'] = $REMOTE_ADDR; + if ($data['stype'] == "video") { + $data['tpl']->assign("V_OP","SELECTED"); + $data['tpl']->assign("P_OP",""); + } + else { + $data['tpl']->assign("P_OP","SELECTED"); + $data['tpl']->assign("V_OP",""); + } +?> diff --git a/templates/about.html b/templates/about.html new file mode 100644 index 0000000..48b7b44 --- /dev/null +++ b/templates/about.html @@ -0,0 +1,21 @@ +
+ +
+

How TUvé Works

+

What is TUvé?

+TUvé (pronounced too-vey) is like TV, only better. It is an online shared video experience where we combine the usefulness of chat with the power of syncronized video. Now you can do two things you love at once!
+

Why TUvé?

+When was the last time you sent a video link to one of your friends? Then another? 18 links later you ask them what they think about the one you're watching and they still haven't seen the first one. Thus, TUvé was born. Now you can show all your friends videos and know they're watching the same thing you are.
+

How does it work?

+TUvé works by allowing users together as a whole to express their taste in *videos* by inserting channel permitted videos into their queue. A round-robin system ensures everybody gets to queue a video for other people in the channel to see.
+

The Power Of TUvé?

+TUvé gives you control. Channels can have limits based on time, ratings, genre (Live shows, music videos, anime, documentaries, etc), user enabled queues, and/or exclusive content.
+

What does TUvé stand for?

+Truth, Justice, and the American Way. Seriously, though, it stands for TCA and Ubu's Video Experience. The "e" eventually became "é" because "too-vee" doesn't sound nearly as pretentious as "too-vey".
+

Who are we?

+Some call us Ubix Corp. Others call us the magical liopleurodon on the way to Candy Mountain. We develop Ubixquitous Technology: that which allows all things to work together better. We also steal kidneys from unsuspecting Unicorns.
+
+
+
diff --git a/templates/aboutus.html b/templates/aboutus.html new file mode 100644 index 0000000..7c43766 --- /dev/null +++ b/templates/aboutus.html @@ -0,0 +1,19 @@ +
+ +
+

About Us

+

What is TUvé?

+TUvé (pronounced too-vey) is like TV, only better. It is an online shared video experience where we combine the usefulness of chat with the power of syncronized video. Now you can do two things you love at once!
+

Why TUvé?

+When was the last time you sent a video link to one of your friends? Then another? 18 links later you ask them what they think about the one you're watching and they still haven't seen the first one. Thus, TUvé was born. Now you can show all your friends videos and know they're watching the same thing you are.
+

How does it work?

+TUvé works by allowing users together as a whole to express their taste in *videos* by inserting channel permitted videos into their queue. A round-robin system ensures everybody gets to queue a video for other people in the channel to see.
+

The Power Of TUvé?

+TUvé gives you control. Channels can have limits based on time, ratings, genre (Live shows, music videos, anime, documentaries, etc), user enabled queues, and/or exclusive content.
+

What does TUvé stand for?

+Truth, Justice, and the American Way. Seriously, though, it stands for TCA and Ubu's Video Experience. The "e" eventually became "é" because "too-vee" doesn't sound nearly as pretentious as "too-vey".
+

Who are we?

+Some call us Ubix Corp. Others call us the magical liopleurodon on the way to Candy Mountain. We develop Ubixquitous Technology: that which allows all things to work together better. We also steal kidneys from unsuspecting Unicorns.
+
+
+
diff --git a/templates/activate-failed.html b/templates/activate-failed.html new file mode 100644 index 0000000..13a74a9 --- /dev/null +++ b/templates/activate-failed.html @@ -0,0 +1,15 @@ +
+ +
+

Activation

+

Activation Failed -

+Sorry we're unable to activate your account. Please enter your email below to try and activate your account again. +
+ + +
+
+
+
diff --git a/templates/activate-reactivate.html b/templates/activate-reactivate.html new file mode 100644 index 0000000..47338a3 --- /dev/null +++ b/templates/activate-reactivate.html @@ -0,0 +1,12 @@ +
+ +
+

Activation

+

Activate

+A new actionation request has been sent to your e-mail. Please follow the instuctions to activate your account if you are still experiencing dificulties please contact us at tuve@tuve.tv +
+
+
+
diff --git a/templates/activate-success.html b/templates/activate-success.html new file mode 100644 index 0000000..85ce36a --- /dev/null +++ b/templates/activate-success.html @@ -0,0 +1,12 @@ +
+ +
+

Activation

+

Activation Successful

+Your account is now activated. Please feel free to login to the TUve network. The TUve network can be accessed through the "Launch TUve" button to the left. +
+
+
+
diff --git a/templates/channels.html b/templates/channels.html new file mode 100644 index 0000000..7682ae8 --- /dev/null +++ b/templates/channels.html @@ -0,0 +1,12 @@ +
+ +
+

Channel Line-Up

+ +{ROWS} +
+
+
+
diff --git a/templates/contact.html b/templates/contact.html new file mode 100644 index 0000000..2e0a4ec --- /dev/null +++ b/templates/contact.html @@ -0,0 +1,14 @@ +
+ +
+

Contact Us

+ + + + +
Tel:516-903-2889
Email:cwolsen@domainatlantic.com
Mail:88B Toledo Street
Farmingdale, NY 11735
+
+
+
diff --git a/templates/faq.html b/templates/faq.html new file mode 100644 index 0000000..634f6ae --- /dev/null +++ b/templates/faq.html @@ -0,0 +1,38 @@ +
+ +
+

FAQ

+What browsers and operating systems are supported?
+Can I have my own TUvé channel?
+Is there a service charge to use TUvé?
+Is there a standalone application for TUvé?
+What type of content do you have on TUvé?
+Are there any live shows on TUvé?
+ +

What browsers and operating systems are supported?

+Windows 98/2000/XP/Vista with IE/Firefox/Opera
+OSX with Firefox/Safari
+ +

Can I have my own TUvé channel?

+If you are an original content provider you may have your own channel. Feel free to contact us about that. + +

Is there a service charge to use TUvé?

+No. TUvé is absolutely FREE! + +

Is there a standalone application for TUvé?

+Yes there is but, it's still under development. So keep checking in or contact us about our beta program.
+
+

What type of content do you have on TUvé?


+
+We have all sorts of content from music videos to documentaries, as well as tv shows. +The content is also assigned to specific viewer levels just like your television. +These parameters are defined by the channel which you are in. + +

Are there any live shows on TUvé?

+Yes. From time to time orignal content providers might broadcast a live showing. +
+
+
+
diff --git a/templates/index/index.html b/templates/index/index.html new file mode 100644 index 0000000..91f16b4 --- /dev/null +++ b/templates/index/index.html @@ -0,0 +1,44 @@ + + + + + +TUvé - It's like TV, only better -- {PAGE_TITLE} + + + + + + +
+
+ +
+
+
+{BODY} +
+
+
+
+ + diff --git a/templates/lostact-sent.html b/templates/lostact-sent.html new file mode 100644 index 0000000..d9aedf9 --- /dev/null +++ b/templates/lostact-sent.html @@ -0,0 +1,11 @@ +
+ +
+

TUvé Password Recovery / Account Activation

+Your password or activation information has been sent to your e-mail address {EMAIL}.
+If you're still having trouble please feel free to contact us support@tuve.tv +
+
+
diff --git a/templates/lostact.html b/templates/lostact.html new file mode 100644 index 0000000..ee6abc6 --- /dev/null +++ b/templates/lostact.html @@ -0,0 +1,15 @@ +
+ +
+

TUvé Password Recovery / Account Activation

+Please enter your e-mail address and click submit so we can recover your password or activate your account.

+{ERROR} +
+Email:  + +
+
+
+
diff --git a/templates/main.html b/templates/main.html new file mode 100644 index 0000000..0b40c0d --- /dev/null +++ b/templates/main.html @@ -0,0 +1,17 @@ +
+ +
+

TUvé News

+New Chat Widget. We've created a small chat widget which you integrate into your web site for people to join the tuve network. Click Here To see this widget in action.

+We'd like to welcome on board our newest exclusive content provider, Sean O'Donnell. Sean has been doing his own show for about a year now. You can check out his episodes at http://seanodonnell.tuve.tv (following this link will launch TUvé in a new window). +

For new users

+

We Support:

+Windows 98/2000/XP/Vista with IE/Firefox/Opera
+OSX with Firefox/Safari
+
+ +
+
+
diff --git a/templates/news.html b/templates/news.html new file mode 100644 index 0000000..16381c9 --- /dev/null +++ b/templates/news.html @@ -0,0 +1,21 @@ +
+ +
+

News

+

2008-06-02 - New Chat Widget, ubChattin

+New Chat Widget. We've created a small chat widget which you integrate into your web site for people to join the tuve network. Click Here To see this widget in action.
+

2008-23-01 - New Features

+Playlists are now supported. Users can create multiple playlists to store their favourite videos.
+Donations are now available. You're now more than welcome to make a donation to keep TUvé up and running.
+ +

2008-13-01 - The Sean O'Donnell Show

+We'd like to welcome on board our newest exclusive content provider, Sean O'Donnell. Sean has been doing his own show for about a year now. You can check out his episodes at http://seanodonnell.tuve.tv (following this link will launch TUvé in a new window).
+ +

2008-01-08 - Public Beta

+After one year in the making, TUvé goes live with it's public beta. +
+
+
+
diff --git a/templates/profile.html b/templates/profile.html new file mode 100644 index 0000000..8241741 --- /dev/null +++ b/templates/profile.html @@ -0,0 +1,46 @@ +
+ +
+ + +

{USER}

+ + + + + +
{CAPTION}

{GENDER}
{AGE} Years Old
{LOCATION}
Member Since: {REGISTERED}
{ONLINE}
+ + + +

About Me:

+{ABOUT_ME} + + + +

{USER}'s Channels:

+ +{CHANNELS} +
+ + + +

{USER}'s Media:

+ +{MEDIA} +
+ + + +

{USER}'s Buddies:

+ +{BUDDIES} +
+ + + +
+
+
diff --git a/templates/register-success.html b/templates/register-success.html new file mode 100644 index 0000000..0e0ea91 --- /dev/null +++ b/templates/register-success.html @@ -0,0 +1,12 @@ +
+ +
+

How TUvé Works

+

TUvé Registration Successful

+

+Congratulations your account is now registered. Please confirm your email address than log into your account. +
+
+
diff --git a/templates/register.html b/templates/register.html new file mode 100644 index 0000000..348fea5 --- /dev/null +++ b/templates/register.html @@ -0,0 +1,26 @@ +
+ +
+

How TUvé Works

+

TUvé Registration

+
+ + + + + + + + + + + + + + +
{MESSAGE}
* - Required Field
*First Name:
*Last Name:
*Postal Code:
*Country:
*Birthday:
*Username:
*Password:
*Confirm Password:
*E-mail:
*Confirm E-mail:
+
+
+
diff --git a/templates/search.html b/templates/search.html new file mode 100644 index 0000000..468601f --- /dev/null +++ b/templates/search.html @@ -0,0 +1,12 @@ +
+ +
+

TUvé Search Results For {SEARCH}:

+ +{SROWS} +
+
+
+
diff --git a/templates/topvideos.html b/templates/topvideos.html new file mode 100644 index 0000000..2e93f4e --- /dev/null +++ b/templates/topvideos.html @@ -0,0 +1,12 @@ +
+ +
+

Top 10 Videos

+ +{ROWS} +
+
+
+
diff --git a/templates/view-row.html b/templates/view-row.html new file mode 100644 index 0000000..a48f215 --- /dev/null +++ b/templates/view-row.html @@ -0,0 +1,17 @@ +
+
+
+ +
+
+
+
+ +
+ {LENGTH} + From: {USER} + +
+
Views:{VIEWS}
+
+
diff --git a/templates/view.html b/templates/view.html new file mode 100644 index 0000000..df3e550 --- /dev/null +++ b/templates/view.html @@ -0,0 +1,118 @@ +
+
+ + + + + + + +
  + +

{VID_TITLE}

+ + + + + + + + + +
+ +

More From {USER}

+
+ {NEW_VIDS} +
+ +
+ + + +
+
+
diff --git a/templates/vs-rows.html b/templates/vs-rows.html new file mode 100644 index 0000000..f967519 --- /dev/null +++ b/templates/vs-rows.html @@ -0,0 +1,5 @@ + + + {ARTIST} - {TITLE}
Length: {LENGTH}
From: {USERNAME}
Views: {VIEWS} + +
diff --git a/templates/widget.html b/templates/widget.html new file mode 100644 index 0000000..3c3a060 --- /dev/null +++ b/templates/widget.html @@ -0,0 +1,26 @@ +
+ +
+

ubChattin - Widget

+We've developed a new widget which will allow you to bring the TUve network onto your web site.
+All you need to do is paste the code below into your site and you're good to go...
+Check out our MySpace

+
+<object width="500" height="500">
+<param name="movie" value="http://www.ubixonline.com/beta/ubChattin.swf">
+<embed src="http://www.ubixonline.com/beta/ubChattin.swf" width="500" height="500">
+</embed>
+</object>
+

+ + + + + + + +
+
+