ob_start(); ?>
AVChat
Welcome To AVChat
';
//setting the cookie
if(empty($_COOKIE["userId"])){
setcookie("userId", "u".rand(10000,999999));
}
if(isset($avconfig['showLoginError']) && $avconfig['showLoginError'] == 1){
$disableLogin ="";
$disableRegister ="";
if(isset($avconfig['loginPageURL']) && isset($avconfig['registerPageURL'])){
if($avconfig['loginPageURL'] ==""){
$disableLogin="disabled";
}
if($avconfig['registerPageURL'] ==""){
$disableRegister="disabled";
}
echo 'Register
Register today to get access to the best video chat technology can offer!
Send private messages and create your own room today!
Go to Registration Page
Sign in
Already have an account on this website?
Go to Sign In Page
';
return;
}
}
//loading the genders
$genders = simplexml_load_file('genders.xml');
$_username="";
$_gender="";
$disabled = "";
if(isset($avconfig['username']) && $avconfig['username'] != ''){
$_username = $avconfig['username'];
}
if(isset($_SESSION["username"]) && $avconfig['username'] == ''){
$_username = $_SESSION["username"];
}
if(isset($avconfig['gender']) && $avconfig['gender'] != ''){
$_gender = $avconfig['gender'];
}
if(isset($avconfig['changegender']) && $avconfig['changegender'] == 0){
$disabled = "disabled";
}
if( $avconfig['changegender'] == 0 && $avconfig['changeuser'] == 0 && !empty($avconfig['username'])){
$_POST['username'] = $avconfig['username'];
$_POST['gender'] = $avconfig['gender'];
header("Location: getRooms.php");
}
if(isset($avconfig['connectionstring']) && $avconfig['connectionstring'] != ''){
echo'';
}else{
echo 'The connection string is empty ';
}
if(isset($avconfig['dropInRoom']) && $avconfig['dropInRoom'] != ''){
$_SESSION["dropInRoom"] = $avconfig['dropInRoom'];
$_SESSION["firstTimeConnected"] = true;
}
if(isset($avconfig['typingEnabled'])){
$_SESSION["typingEnabled"] = $avconfig['typingEnabled'];
}
if(isset($avconfig['disconnectButtonLink']) && $avconfig['disconnectButtonLink'] != ''){
$_SESSION["disconnectButtonLink"] = $avconfig['disconnectButtonLink'];
}else{
$_SESSION["disconnectButtonLink"] = "m.php";
}
if(isset($avconfig['emoticonsurl']) && $avconfig['emoticonsurl'] != ''){
$_SESSION["emoticonsurl"] = $avconfig['emoticonsurl'];
}else{
$_SESSION["emoticonsurl"] = "emoticons/squarePack/emoticons.xml";
}
if(isset($avconfig['autoAddIpToUsername'])){
$_SESSION["autoAddIpToUsername"] = $avconfig['autoAddIpToUsername'];
}
//loading the emoticons
/*$emotes = simplexml_load_file('emoticons/squarePack/emoticons.xml');
$emoticonsArray = array();
foreach($emotes as $emote){
//echo $emote["text"]." ".$emote["url"]." ";
array_push($emoticonsArray, $emote);
}*/
//setcookie("emotes", serialize($emoticonsArray));
//var_dump($_COOKIE["emotes"]);
//die();
/*foreach($_COOKIE["emotes"] as $e){
echo $e["text"]." ".$e["url"]." ";
}*/
?>
AVChat
ob_start(); ?>