diff --git a/docroot/activate.php b/docroot/activate.php index 5301f7a..11f4e53 100644 --- a/docroot/activate.php +++ b/docroot/activate.php @@ -22,12 +22,12 @@ $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"); + 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]'"; + $query = "SELECT uid,active,firstname,lastname,username 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")); @@ -41,8 +41,9 @@ $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')"; + $username = mysql_result($res,0,'username'); + 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('$username','No Description','http://www.ubixonline.com/images/UbixCube.swf',$uid,'No Description')"; mysql_query($query); } } diff --git a/docroot/channels.php b/docroot/channels.php index 90e6c88..685c2be 100644 --- a/docroot/channels.php +++ b/docroot/channels.php @@ -25,7 +25,7 @@ $thumb = "UbixCube.gif"; $chan2 = substr($channel,1,strlen($channel)-1); - $rw .= " Channel:
Topic:
Now Playing: $channel
$topic
$artist - $title\n"; + $rw .= " Channel:
Topic:
Now Playing: $channel
$topic
$artist - $title\n"; $rw .= "
\n"; } diff --git a/docroot/css/master_styles.css b/docroot/css/master_styles.css index ee5488f..0baad0e 100644 --- a/docroot/css/master_styles.css +++ b/docroot/css/master_styles.css @@ -38,9 +38,11 @@ } #membertext a:link, #membertext a:visited { color:#ff8d07; + font-weight: bold; } #membertext a:hover, #membertext a:active { color:#b66505; + font-weight: bold; } #main_container { width:801px; @@ -50,10 +52,24 @@ margin-left:12px; margin-right:13px; } +#footer_container { + width:700px; + text-align:center; + font-size:9pt; + padding-top:20px; + } +#footer_container a:link, #footer_container a:visited { + color:#ff8d07; +} +#footer_container a:hover, #footer_container a:active { + color:#b66505; +} #navtext { text-align:right; padding-right:15px; padding-top:43px; + font-size:11pt; + font-weight:bold; } #navtext a:link, #navtext a:visited { color:#ff8d07; @@ -78,7 +94,7 @@ color:#003333; } #subnav { - width:130px; + width:100px; min-height:190px; float:left; margin:10px; diff --git a/docroot/index.php b/docroot/index.php index 7b0a4b1..700b869 100644 --- a/docroot/index.php +++ b/docroot/index.php @@ -1,6 +1,6 @@ assign("CVID","1738"); + + $query = "SELECT vid,artist,title,thumb FROM videos ORDER BY vid DESC LIMIT 0,3"; + $res = mysql_query($query); + + //$newVids = ""; + for ($i = 0;$i < mysql_num_rows($res);$i++) { + $VID = mysql_result($res,$i,'vid'); + $vArtist = mysql_result($res,$i,'artist'); + $vTitle = mysql_result($res,$i,'title'); + $vThumb = mysql_result($res,$i,'thumb'); + if (strlen($vArtits) > 18) + $vArtist = substr($vArtist,0,16) . "..."; + if (strlen($vTitle) > 18) + $vTitle = substr($vTitle,0,16) . "..."; + $newVids .= "
$vArtist
$vTitle

"; + //$newVids .= ""; + } + //$newVids .= "

$vArtist
$vTitle
"; + + $data['tpl']->assign("NEW_VIDS",$newVids); + + $query = "SELECT uid,username,main_image,profile_image FROM users WHERE active = 1 ORDER BY uid DESC LIMIT 0,5"; + + $res = mysql_query($query); + + $newMembers = ""; + + for ($i = 0;$i < mysql_num_rows($res);$i++) { + $username = mysql_result($res,$i,'username'); + /* Set Profile Image */ + $mid = mysql_result($res,$i,'profile_image'); + if ($mid == 0) + $thumb = mysql_result($res,$i,'main_image'); + else + $thumb = $avatars[$mid]; + + $newMembers .= ""; + } + + $newMembers .= "

$username
"; + $data['tpl']->assign("NEW_MEMBERS",$newMembers); + + + /* Parse and print */ $data[tpl]->parse(BODY, array("body")); diff --git a/docroot/lostact.php b/docroot/lostact.php index 16e2525..88f02b4 100644 --- a/docroot/lostact.php +++ b/docroot/lostact.php @@ -20,13 +20,16 @@ else { $fName = mysql_result($res,0,'firstname'); $lName = mysql_result($res,0,'lastname'); + $pass = mysql_result($res,0,'password'); $email = mysql_result($res,0,'email'); + $active = mysql_result($res,0,'active'); + $data['tpl']->define(array(body=>"/lostact-sent.html")); $data['tpl']->assign("EMAIL",$email); - if ($active == 1) - $message = "Please Activate"; + if ($active != 1) + $message = "$fname,
Please Click or goto the following link to confirm your email address http://www.tuve.tv/activate.php?active=" . $active . "&email=" . $email . " After confirmation your account will be activated.

Thank you,
The TUve Staff
"; else - $message = "$fName,
Your Password Is: $pass

Sincerely,
TUVe Support"; + $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); } diff --git a/docroot/profile.php b/docroot/profile.php index 2c8bca4..98a355f 100644 --- a/docroot/profile.php +++ b/docroot/profile.php @@ -17,10 +17,13 @@ //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]'"; + $query = "SELECT uid,username,caption,gender,bmonth,byear,city,state_prov,country,main_image,profile_image,registered,about_me FROM users WHERE username LIKE '$data[user]'"; $res = mysql_query($query); + if (mysql_numrows($res) == 0) { + Header("Location: /people.php\n"); + exit; $data['tpl']->assign("USER","Unknown"); } else { @@ -47,22 +50,32 @@ $data['tpl']->assign("CAPTION",mysql_result($res,0,'caption')); /* Set Gender */ - if (mysql_result($res,0,'gender') == 1) + $gender = mysql_result($res,0,'gender'); + + if ($gender == 1) $data['tpl']->assign("GENDER","Male"); - else + else if ($gender == 2) $data['tpl']->assign("GENDER","Female"); + else + $data['tpl']->assign("GENDER","Undefined"); /* Set Profile Image */ - $data['tpl']->assign("PROFILE_IMAGE",mysql_result($res,0,'profile_image')); + $mid = mysql_result($res,0,'profile_image'); + if ($mid == 0) + $data['tpl']->assign("PROFILE_IMAGE",mysql_result($res,0,'main_image')); + else + $data['tpl']->assign("PROFILE_IMAGE",$avatars[$mid]); /* 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')); + $data['tpl']->assign("ABOUT_ME",fixHTML(mysql_result($res,0,'about_me'))); /* Channels */ $uid = mysql_result($res,0,'uid'); + + $data['tpl']->assign("PID",$uid); $query = "SELECT * FROM channels LEFT JOIN videos ON channels.nowplaying = videos.vid WHERE channels.oid = $uid ORDER BY channel"; $result = mysql_query($query); @@ -82,7 +95,7 @@ else $ebr = ""; - $rw .= " Channel:
Topic:$ebr
Now Playing: $channel
$topic
$artist - $title\n"; + $rw .= " Channel:
Topic:$ebr
Playing: $channel
$topic
$artist - $title\n"; $rw .= "
\n"; } $data['tpl']->assign("CHANNELS",$rw); @@ -92,7 +105,7 @@ else $data['tpl']->assign("ONLINE","Currently Offline"); - $query = "SELECT vid,artist,title,thumb FROM videos WHERE oid = $uid"; + $query = "SELECT vid,artist,title,thumb FROM videos WHERE oid = $uid ORDER BY vid DESC"; $result = mysql_query($query); $rows = mysql_numrows($result); @@ -114,7 +127,7 @@ else if (($i % 4) == 0) $media .= ""; - $media .= "
$artist - $title
"; + $media .= "
$artist - $title
"; } if ($m == 0) $media .= ""; @@ -123,7 +136,7 @@ $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"; + $query = "SELECT bid,fid,main_image,profile_image,username FROM friends f INNER JOIN users u ON f.fid = u.uid WHERE f.oid = $uid AND approved = 1 ORDER BY fid DESC"; $result = mysql_query($query); $rows = mysql_numrows($result); @@ -136,13 +149,19 @@ $m = 0; for ($i = 0;$i < $rows;$i++) { - $thumb = mysql_result($result,$i,'profile_image'); + /* Set Profile Image */ + $mid = mysql_result($result,$i,'profile_image'); + if ($mid == 0) + $thumb = mysql_result($result,$i,'main_image'); + else + $thumb = $avatars[$mid]; + $username = mysql_result($result,$i,'username'); if ($buddies == "") $buddies = ""; else if (($i % 4) == 0) $buddies .= ""; - $buddies .= "
$username
\n"; + $buddies .= "
$username
\n"; } if ($m == 0) $buddies .= ""; @@ -151,8 +170,26 @@ $data['tpl']->assign("BUDDIES",$buddies); + $query = "SELECT fid,pdate,message,username,main_image,profile_image FROM comments c INNER JOIN users u ON c.fid = u.uid WHERE oid = $uid ORDER BY pdate DESC"; + $res = mysql_query($query); - } + for ($i = 0;$i < mysql_numrows($res);$i++) { + $user = mysql_result($res,$i,'username'); + /* Set Profile Image */ + $mid = mysql_result($res,$i,'profile_image'); + if ($mid == 0) + $thumb = mysql_result($res,$i,'main_image'); + else + $thumb = $avatars[$mid]; + + $pdate = date("m/d/Y H:i:s",mysql_result($res,$i,'pdate')); + $message = mysql_result($res,$i,'message'); + $comments .= "$user $pdate $message"; + $comments .= " \n"; + } + + $data['tpl']->assign("COMMENTS",$comments); + } /* Parse and print */ diff --git a/docroot/register.php b/docroot/register.php index 83bcbc1..a0f9959 100644 --- a/docroot/register.php +++ b/docroot/register.php @@ -28,6 +28,8 @@ $message .= "Invalid Birth Year "; if ($data['username'] == "") $message .= "Invalid Username "; + if ($data['gender'] == 0) + $message .= "Please Select A Gender "; $query = "SELECT uid FROM users WHERE username = \"$data[username]\""; $res = mysql_query($query); if (mysql_num_rows($res) > 0) @@ -39,21 +41,35 @@ $message .= "This E-Mail Address Is Already Registered "; if ($data['email1'] != $data['email2']) $message .= "E-Mail Mismatch "; + if (!$data['tos']) + $message .= "Please Agree To The Terms Of Use and Privacy Policy"; } if (($message == "") && ($data['register'] != "")) { $data['tpl']->define(array(body=>"/register-success.html")); $active = time(); + + if ($data['gender'] == 2) + $pImage = 2; + else + $pImage = 3; - $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)"; + $query = "INSERT INTO users (firstname,lastname,postal_code,country,bmonth,bday,byear,email,username,password,gid,active,gender,profile_image) VALUES(\"$data[firstname]\",\"$data[lastname]\",\"$data[postal_code]\",\"$data[country]\",$data[bmonth],$data[bday],$data[byear],\"$data[email1]\",\"$data[username]\",\"$data[password1]\",3,$active,$data[gender],$pImage)"; 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"); + $message = "$data[firstname],

Thank you for registering with TUve. Please click or go to the following link to activate your account. http://www.tuve.tv/activate.php?active=$active&email=$data[email1]

Another useful link is http://www.tuve.tv/faq.php where you can find answers to the most frequently asked questions.

Thank you,
The TUve Staff
"; + + send_mail("$data[firstname] $data[lastname] <$data[email1]>",$message,"Please Confirm Your E-Mail Address","support@tuve.tv","TUve Support"); + + send_mail("Christopher Olsen ","New registration

E-Mail: $data[email1]
Activation: $active
Source: $data[source]

","New Registration","support@tuve.tv","TUve Support"); } else { $data['tpl']->define(array(body=>"/register.html")); + if ($data['tos']) + $data['tpl']->assign("TOS","CHECKED"); + else + $data['tpl']->assign("TOS",""); $data['tpl']->assign("FIRSTNAME",$data['firstname']); $data['tpl']->assign("LASTNAME",$data['lastname']); $data['tpl']->assign("POSTAL_CODE",$data['postal_code']); @@ -62,6 +78,7 @@ $data['tpl']->assign("EMAIL2",$data['email2']); $data['tpl']->assign("PASSWORD1",$data['password1']); $data['tpl']->assign("PASSWORD2",$data['password2']); + $data['tpl']->assign("SOURCE",$data['source']); $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"); @@ -101,6 +118,13 @@ $country .= "\n"; } $data['tpl']->assign("COUNTRY",$country); + + if ($data['gender'] == 1) + $data['tpl']->assign("GENDER",""); + else if ($data['gender'] == 2) + $data['tpl']->assign("GENDER",""); + else + $data['tpl']->assign("GENDER","\n\n\n"); } diff --git a/docroot/remind.php b/docroot/remind.php index 9bb7d2c..018412b 100644 --- a/docroot/remind.php +++ b/docroot/remind.php @@ -13,8 +13,8 @@ $email = mysql_result($res,$i,'email'); $active = mysql_result($res,$i,'active'); - send_mail("$fName $lName <$email>","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"); + send_mail("$fName $lName <$email>","Thank you for registering with TUve

Please Click or goto the following link to confirm your email address http://www.tuve.tv/activate.php?active=" . $active . "&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?active=$active&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 index 7649153..8ef5e2e 100644 --- a/docroot/search.php +++ b/docroot/search.php @@ -13,6 +13,11 @@ $skey = $data['search']; + if ($data['stype'] == "people") { + Header("Location: /people.php?data[skey]=$skey\n"); + exit; + } + $data['tpl']->assign("SEARCH",$skey); $gTypes = array('NA','Male','Female'); @@ -29,7 +34,7 @@ $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 .= "
$username
Caption: $caption
Gender: $gTypes[$gender]
Age: $age
Location: $location
Last on: $laston\n"; $srows .= "
"; } $data['tpl']->assign("SROWS",$srows); diff --git a/docroot/topvideos.php b/docroot/topvideos.php index 0113db1..a864503 100644 --- a/docroot/topvideos.php +++ b/docroot/topvideos.php @@ -24,6 +24,7 @@ $ratings = array('None','G','PG','13+','MA','AD'); for ($i=0;$i < $maxLim;$i++) { + $vid = mysql_result($result,$i,'vid'); $thumb = mysql_result($result,$i,'thumb'); $artist = mysql_result($result,$i,'artist'); $title = mysql_result($result,$i,'title'); @@ -31,7 +32,7 @@ $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 .= "Artist: $artist
Title: $title
Genre: $genre
Classification: $classes[$vclass]
Rating: $ratings[$rating]
Played: $count Times\n"; $rows .= "
\n"; } diff --git a/docroot/view.php b/docroot/view.php index 387c962..f745689 100644 --- a/docroot/view.php +++ b/docroot/view.php @@ -14,7 +14,7 @@ //DoSession(); - $query = "SELECT artist,title,oid,username FROM videos v INNER JOIN users u ON v.oid = u.uid WHERE vid = $data[vid]"; + $query = "SELECT v.artist,title,v.oid,description,username,bio,photo FROM videos v INNER JOIN users u ON v.oid = u.uid RIGHT JOIN artists a ON v.aid = a.aid WHERE vid = $data[vid]"; $res = mysql_query($query); if ($res) { @@ -23,13 +23,16 @@ $data['tpl']->assign("CVID",$data['vid']); $data['tpl']->assign("VID_TITLE",$vTitle); $data['tpl']->assign("USER",mysql_result($res,0,'username')); + $data['tpl']->assign("BIOGRAPHY",fixHTML(mysql_result($res,0,'bio'))); + $data['tpl']->assign("BIO_IMG",mysql_result($res,0,'photo')); + $data['tpl']->assign("DESCRIPTION",fixHTML(mysql_result($res,0,'description'))); } 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"; + $query = "SELECT vid,artist,title,thumb,count,length FROM videos WHERE oid = $OID AND rating <= $data[rating] AND mType = 1 ORDER BY vid DESC"; else - $query = "SELECT vid,artist,title,thumb,count,length FROM videos WHERE oid = $OID AND rating < 4 AND mType = 1 ORDER BY artist,title"; + $query = "SELECT vid,artist,title,thumb,count,length FROM videos WHERE oid = $OID AND rating < 4 AND mType = 1 ORDER BY vid DESC"; $res = mysql_query($query); //$rows = mysq_num_rows($res); diff --git a/include/funcs.inc b/include/funcs.inc index 02e89b6..6d70b32 100755 --- a/include/funcs.inc +++ b/include/funcs.inc @@ -1,16 +1,66 @@ /i"; + $str = preg_replace($pattern, "",$str); + + $pattern = "/<\/P>/i"; + $str = preg_replace($pattern, "

",$str); + + $pattern= "/
  • /i"; + $str = preg_replace($pattern, "
  • ",$str); + $pattern= "/<\/LI>/i"; + $str = preg_replace($pattern, "
  • ",$str); + + $pattern= "/
      /i"; + $str = preg_replace($pattern, "
        ",$str); + + $pattern = "/KERNING=\"(.*?)\"/i"; + $str = preg_replace($pattern,"",$str); + + $pattern = "/LETTERSPACING=\"(.*?)\"/i"; + $str = preg_replace($pattern,"",$str); + + $pattern = "/

        /i"; + $str = preg_replace($pattern, "

        ",$str); + + $pattern = "//i"; + $str = preg_replace($pattern, "",$str); + + return($str); + } + +function send_mail($to, $body, $subject, $fromaddress, $fromname, $notification=0) { + $eol="\r\n"; $mime_boundary=md5(time()); + $body = "$body\n

        \n

        If you wish to change how you receive future notifications, please click here.
        \nIf you have any questions, please contact support@tuve.tv.

        \n

        © 2008, Ubix Media Group

        "; + # Common Headers $headers .= "From: ".$fromname."<".$fromaddress.">".$eol; $headers .= "Reply-To: ".$fromname."<".$fromaddress.">".$eol; @@ -20,53 +70,26 @@ # Boundry for marking the split & Multitype Headers $headers .= 'MIME-Version: 1.0'.$eol; - $headers .= "Content-Type: multipart/alternative; $eol boundary=\"".$mime_boundary."\"".$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; + $msg .= "--------------$mime_boundary$eol"; + $msg .= "Content-Type: text/plain; charset=iso-8859-1; format=flowed".$eol; + $msg .= "Content-Transfer-Encoding: 7bit".$eol.$eol; + $msg .= strip_tags(str_ireplace("
        ", "\r\n",$body)) .$eol . $eol; + #$msg .= strip_tags(str_replace("
        ", "\r\n", substr($body, (strpos($body, "")+6)))).$eol.$eol; # HTML Version - $msg .= "--".$mime_boundary.$eol; + $msg .= "--------------$mime_boundary$eol"; $msg .= "Content-Type: text/html; charset=iso-8859-1".$eol; - $msg .= "Content-Transfer-Encoding: 8bit".$eol.$eol; + $msg .= "Content-Transfer-Encoding: 7bit".$eol.$eol; + $msg .= "$eol$eol$eol$eol$eol"; $msg .= $body.$eol.$eol; + $msg .= "$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); @@ -74,8 +97,7 @@ ini_restore(sendmail_from); return $mail_sent; -} - + } function makeRating($rating) { $ret = " 
        @@ -39,6 +47,9 @@
        + diff --git a/templates/main.html b/templates/main.html index 0b40c0d..7e36131 100644 --- a/templates/main.html +++ b/templates/main.html @@ -1,8 +1,116 @@
        +
        +
        +

        Featured Videos

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

        TUvé's Newest Videos:

        +
        +{NEW_VIDS} +
        +
        +
         
        +
        +

        TUvé's Newest Members:

        +{NEW_MEMBERS}

        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). @@ -11,7 +119,7 @@ Windows 98/2000/XP/Vista with IE/Firefox/Opera
        OSX with Firefox/Safari

        - +

        diff --git a/templates/news.html b/templates/news.html index 16381c9..7cdcf36 100644 --- a/templates/news.html +++ b/templates/news.html @@ -4,6 +4,9 @@

        News

        +

        2008-04-22 - Mail System

        +Our new mail system is now online. E-Mail can now be found under the communication tab. This allows you to send messages to all of your buddies. +

        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

        diff --git a/templates/profile.html b/templates/profile.html index 8241741..ceb15fe 100644 --- a/templates/profile.html +++ b/templates/profile.html @@ -8,8 +8,10 @@

        {USER}

        - - + + +
        {CAPTION}

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

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

        Contact:
        Leave Comment
        Send Message
        Make Friend
        +
        @@ -24,6 +26,7 @@ {CHANNELS}
        +See More Channels @@ -40,6 +43,14 @@ + +

        {USER}'s Comments:

        + +{COMMENTS} +
        +Leave Comment + +

        diff --git a/templates/register-success.html b/templates/register-success.html index 0e0ea91..b77ce0b 100644 --- a/templates/register-success.html +++ b/templates/register-success.html @@ -6,7 +6,11 @@

        How TUvé Works

        TUvé Registration Successful



        -Congratulations your account is now registered. Please confirm your email address than log into your account. +Congratulations your account is now registered.

        +Shortly you will be receiving an activation letter in your inbox to confirm your email address.

        +Please follow the instruction provided in your activation letter to active your account.

        +To also avoid any delays this letter will be coming from support@tuve.tv if you use a white list please ensure that you add this address to it otherwise if you do not receive it shortly please check your spam folder for this letter.

        +If you are still having difficulties please feel free to contact us the support address is support@tuve.tv
        diff --git a/templates/register.html b/templates/register.html index 348fea5..94c8a7d 100644 --- a/templates/register.html +++ b/templates/register.html @@ -15,10 +15,13 @@ *Country: *Birthday: *Username: +*Gender: *Password: *Confirm Password: *E-mail: *Confirm E-mail: +Referral Code: I agree to the terms of use and privacy policy. diff --git a/templates/view-row.html b/templates/view-row.html index a48f215..2a612ab 100644 --- a/templates/view-row.html +++ b/templates/view-row.html @@ -1,7 +1,7 @@
        - +
        diff --git a/templates/view.html b/templates/view.html index df3e550..5e46c97 100644 --- a/templates/view.html +++ b/templates/view.html @@ -99,17 +99,31 @@ +

        +Embed:   + -

        More From {USER}

        +

        More From: {USER}

        {NEW_VIDS}
        +
        + +
        +

        Biography:

        +
        {BIOGRAPHY}
        +
        +
         
        +

        Description:

        +{DESCRIPTION} +
        + diff --git a/templates/vs-rows.html b/templates/vs-rows.html index f967519..bf0aac0 100644 --- a/templates/vs-rows.html +++ b/templates/vs-rows.html @@ -1,5 +1,5 @@ - + {ARTIST} - {TITLE}
        Length: {LENGTH}
        From: {USERNAME}
        Views: {VIEWS}