var os;
var dataReqObj;
var owner = new Object;  
var viewer = new Object; 
var orgData = new Object; 
var tournData = new Object; 
tournData.groupId = "0" ;
var groupId ;
var objTourn = {};
var social_UserId ="" ;
var social_UserName = "" ;
var social_UserName_viewer = "" ;
var social_UserId_viewer = "";
var _action ;
var _bannerAction ;
var userId = "0" ;
var tournUserId = "0" ;
var orgId ;
var orgCode ;
var org_perms = 'status_update,publish_stream,manage_pages,user_photos' ;
var app_perms = 'status_update,publish_stream' ;
var strExpress  ;
var _isAdmin ;
var strBannerUrl ;
var isFaceBook ;
var appId ;
var social_appKey ;
var strBanner ;	
var orgAppId = "1" ;
var twitter_id = "0" ;
var fb_access_token;
var hasTwitter = false ;		
var hasFacebook = false ;
var event_xid ;
var orgUrl ;
var userImg  ;
var severTime ;
var currentTitle = null;
var commentId ;
var commentType ;
var commentTypeId ;
var youTubeResults ;
var videoIdResults ;
var videoTitleResults ;
var videoCatResults ;
var videoThmubResults ;
var videoTagResults ;
var fb_appId = 145320948816875 ;
var _protocol = document.location.protocol ;
var _serverNameBzx = _protocol + "//contest.is/" ;
var _serverName = _protocol + "//contest.is/" ;
var _serverNameQuiz = "http://quizkeeper.com/" ;
var _serverWP = _protocol + "//contest.is/" ;
var _serverType = "prod" ;
var bzx_gen = [] ;
var _docDomain = document.domain ;
var _topLocation = 	_docDomain ;

//if(top.location.host)
	//_topLocation = top.location.host ;
	  //window.fbAsyncInit = function() {
	  	
//alert(document.domain) ;
if(document.domain != "contest.is"){
	if((window.location.host == "localhost") || (window.location.host == "127.0.0.1") || (_docDomain.search("localhost") > 0)){
	//if((top.location.host == "localhost") || (top.location.host == "127.0.0.1")){
		//fb_appId = 109379865789189 ;
		fb_appId = 274982269204823 ;
		//alert(document.domain) ;
		_serverName = _protocol + "//" + document.domain + "/" ;
		_serverType = "dev" ;
		_serverNameBzx = _protocol + "//contestis.localhost/";
		_serverNameQuiz = _protocol + "//" + document.domain + "/quizKeeper/" ;
		_serverWP = _protocol + "//" + document.domain + "/" ;
		fb_appName = "/BZX LocalHost" ;
		//alert(_serverNameQuiz) ;
	}else{
		_serverName = _protocol + "//" + document.domain + "/" ;
		_serverWP = _protocol + "_protocol + //" + document.domain + "/" ;		
		_serverType = "prod" ;
	}
}else{
	_serverName = _protocol + "//" + document.domain + "/" ;
	 _serverWP = _protocol + "//" + document.domain + "/" ;
	_serverType = "prod" ;
}	
var _urlChannel = _serverName + "channel.php";
//***ANALYTICS***
  var _gaq = _gaq || [];
  _gaq.push(['_setAccount', 'UA-4301657-10']);
  _gaq.push(['_setDomainName', '.contest.is']);
  _gaq.push(['_trackPageview']);

  (function() {
    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
  })();


function debug_contestis(text) {
    if ((typeof(Debug) !== 'undefined') && Debug.writeln) {
        Debug.writeln(text);
    }
    if (window.console && window.console.log) {
        window.console.log(text);
    }
    if (window.opera) {
        window.opera.postError(text);
    }
    if (window.debugService) {
        window.debugService.trace(text);
    }
}

/* var _gaq = _gaq || [];
  _gaq.push(['_setAccount', 'UA-4301657-4']);
  _gaq.push(['_setDomainName', '.contest.is']);
  _gaq.push(['_trackPageview']);

  (function() {
    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
  })();
*/


