$('#smSiguup').click(function() { var fname = document.getElementById('fname').value; var lname = document.getElementById('lname').value; var username = document.getElementById('username').value; var email = document.getElementById('signupemail').value; var password = document.getElementById('signuppassword').value; var cpassword = document.getElementById('cpassword').value; if(document.getElementById('signupcaptcha_code')) var captcha_code = document.getElementById('signupcaptcha_code').value; else var captcha_code = ""; var captcha_box = ""; $.ajax({ type: "POST", url: "http://www.freexnxxxvideos.com/includes/ajaxSignup.php", data: {'signup':'signup','fname':fname,'lname':lname,'username':username,'email':email,'password':password,'cpassword':cpassword,'captcha_code':captcha_code,'captcha_box':captcha_box}, dataType: "json", success: function(data) { if(data[0] == 0) { document.getElementById("smregisterError").style.display="block"; $("#smregisterError").html(data[1]); } else window.location.href = data[1]; } }); }); function Signup() { var fname = document.getElementById('fnamelg').value; var lname = document.getElementById('lnamelg').value; var username = document.getElementById('usernamelg').value; var email = document.getElementById('emaillg').value; var password = document.getElementById('passwordlg').value; var cpassword = document.getElementById('confirmPasswordlg').value; if(document.getElementById('captchaCodelg')) var captcha_code = document.getElementById('captchaCodelg').value; else var captcha_code = ""; var captcha_box = ""; $.ajax({ type: "POST", url: "http://www.freexnxxxvideos.com/includes/ajaxSignup.php", data: {'signup':'signup','fname':fname,'lname':lname,'username':username,'email':email,'password':password,'cpassword':cpassword,'captcha_code':captcha_code,'captcha_box':captcha_box}, dataType: "json", success: function(data) { if(data[0] == 0) { $(window).scrollTop(0); document.getElementById("registerError").style.display="block"; $("#registerError").html(data[1]); } else window.location.href = data[1]; } }); } function Signin() { var username = document.getElementById('signUsername').value; var password = document.getElementById('signinPassword').value; if(document.getElementById('signinCaptcha_code')) var captcha_code = document.getElementById('signinCaptcha_code').value; else var captcha_code = ""; var captcha_box = ""; $.ajax({ type: "POST", url: "http://www.freexnxxxvideos.com/includes/ajaxSignup.php", data: {'signin':'signin','username':username,'password':password,'captcha_code':captcha_code,'captcha_box':captcha_box}, dataType: "json", success: function(data) { if(data[0] == 0) { $(window).scrollTop(0); document.getElementById("loginError").style.display="block"; $("#loginError").html(data[1]); } else window.location.href = data[1]; } }); } $('#smSiguin').click(function() { var username = document.getElementById('sm-signUsername').value; var password = document.getElementById('sm-signinpassword').value; if(document.getElementById('sm-signinCaptcha_code')) var captcha_code = document.getElementById('sm-signinCaptcha_code').value; else var captcha_code = ""; var captcha_box = ""; $.ajax({ type: "POST", url: "http://www.freexnxxxvideos.com/includes/ajaxSignup.php", data: {'signin':'signin','username':username,'password':password,'captcha_code':captcha_code,'captcha_box':captcha_box}, dataType: "json", success: function(data) { if(data[0] == 0) { document.getElementById("smloginError").style.display="block"; $("#smloginError").html(data[1]); } else window.location.href = data[1]; } }); }); function ratingByLike(lid,listuserId,likedisLikeStatus,userId) { $.ajax({ type: "POST", url: "http://www.freexnxxxvideos.com/includes/rating.php", data: {'like_dislike':'like','lid':lid,'userId':userId,'likedisLikeStatus':likedisLikeStatus,'listuserId':listuserId}, dataType: "json", success: function(data) { var like=data[0]; var dislike = data[1]; $('#like_vid'+lid).html(like); $('#dislike_vid'+lid).html(dislike); $('#dislike_vid'+lid).removeClass('dislike_vid'); $('#like_vid'+lid).addClass('like_vid'); } }); } function ratingBydisLike(lid,listuserId,likedisLikeStatus,userId) { $.ajax({ type: "POST", url: "http://www.freexnxxxvideos.com/includes/rating.php", data: {'like_dislike':'dislike','lid':lid,'userId':userId,'likedisLikeStatus':likedisLikeStatus,'listuserId':listuserId}, dataType: "json", success: function(data) { var like=data[0]; var dislike = data[1]; $('#like_vid'+lid).html(like); $('#dislike_vid'+lid).html(dislike); $('#like_vid'+lid).removeClass('like_vid'); $('#dislike_vid'+lid).addClass('dislike_vid'); } }); } function addToFavourite(lid,userId,listuserId) { assignedTabName = document.getElementById("FavouriteList"+lid).className; if(assignedTabName == 'btn btn-inverse ' || assignedTabName == 'btn btn-inverse') { $.ajax ({ type:"POST", url: "http://www.freexnxxxvideos.com/includes/addtoFavourite.php", data: {'favorite':'favorite','lid':lid,'userId':userId,'listuserId':listuserId,'bookmark':'0'}, dataType: "json", success: function(response) { var favorite=response[0]; $("#FavouriteList"+lid).html(favorite); } }); $("#FavouriteList"+lid).addClass('favorite_vid'); } else { $.ajax ({ type:"POST", url: "http://www.freexnxxxvideos.com/includes/addtoFavourite.php", data: {'favorite':'favorite','lid':lid,'userId':userId,'listuserId':listuserId,'bookmark':'1'}, dataType: "json", success: function(response) { var favorite=response[0]; $("#FavouriteList"+lid).html(favorite); } }); $("#FavouriteList"+lid).removeClass('favorite_vid'); } } function addToSubscriber(lid,listuserId,userId) { var bookmark = document.getElementById('subscribeValue').value; $.ajax ({ type:"POST", url: "http://www.freexnxxxvideos.com/includes/subscribe.php", data: {'subscribe':'subscribe','lid':lid,'userId':userId,'listuserId':listuserId,'bookmark':bookmark}, dataType: "json", success: function(response) { document.getElementById('subscribeValue').value = response[0]; $("#SubscribeList"+lid).html(response[1]); } }); } function ViewaddToFavourite(lid,userId,listuserId) { assignedTabName = document.getElementById("FavouriteList"+lid).className; if(assignedTabName == 'btn btn-product ' || assignedTabName == 'btn btn-product') { $.ajax ({ type:"POST", url: "http://www.freexnxxxvideos.com/includes/addtoFavourite.php", data: {'favorite':'favorite','lid':lid,'userId':userId,'listuserId':listuserId,'bookmark':'0'}, dataType: "json", success: function(response) { var favorite=response[0]; $("#FavouriteList"+lid).html(favorite); } }); $("#FavouriteList"+lid).addClass('favorite_vid'); } else { $.ajax ({ type:"POST", url: "http://www.freexnxxxvideos.com/includes/addtoFavourite.php", data: {'favorite':'favorite','lid':lid,'userId':userId,'listuserId':listuserId,'bookmark':'1'}, dataType: "json", success: function(response) { var favorite=response[0]; $("#FavouriteList"+lid).html(favorite); } }); $("#FavouriteList"+lid).removeClass('favorite_vid'); } } function userSubscribe(profileuserId,userId) { var subscribeValue = document.getElementById('subscribeValue').value; $.ajax({ type: "POST", url: "http://www.freexnxxxvideos.com/includes/userSubscribe.php", data: {'subscribeValue':subscribeValue,'profileuserId':profileuserId,'userId':userId}, dataType: "json", success: function(data) { document.getElementById('subscribeValue').value = data[0]; $("#subscriberResultAfterAjaxResult").html(data[1]); } }); } function categoriesSubscribe(cid,userId) { var subscribeValue = document.getElementById('subscribeValue').value; $.ajax({ type: "POST", url: "http://www.freexnxxxvideos.com/includes/categorySubscribe.php", data: {'subscribeValue':subscribeValue,'cid':cid,'userId':userId}, dataType: "json", success: function(data) { document.getElementById('subscribeValue').value = data[0]; $("#subscriberResultAfterAjaxResult").html(data[1]); } }); } function tagsSubscribe(tag,userId) { var subscribeValue = document.getElementById('subscribeValue').value; $.ajax({ type: "POST", url: "http://www.freexnxxxvideos.com/includes/tagsSubscribe.php", data: {'subscribeValue':subscribeValue,'tag':tag,'userId':userId}, dataType: "json", success: function(data) { document.getElementById('subscribeValue').value = data[0]; $("#subscriberResultAfterAjaxResult").html(data[1]); } }); } function IncrementSharingSocialLinks(lid,listuserId,socialLink) { $.ajax({ type: "POST", url: "http://www.freexnxxxvideos.com/includes/addSharingClicks.php", data: {'lid':lid,'listuserId':listuserId,'socialLink':socialLink}, success: function(data) {} }); } $("#search_box").keyup(function(event){ if(event.keyCode == 13) $("#go").click(); }); $('#go').click(function(){ var search = $("#search_box").val(); search=search.trim(); if(search!="") { window.location.href="http://www.freexnxxxvideos.com/search/"+search; } }); $("#message_box,#name,#email,#subject,#captcha_code").keyup(function(event){ if(event.keyCode == 13) mailsend(); }); $("#fnamelg,#lnamelg,#usernamelg,#emaillg,#passwordlg,#confirmPasswordlg,#captchaCodelg").keyup(function(event){ if(event.keyCode == 13) Signup(); }); $("#signUsername,#signinPassword,#signinCaptcha_code").keyup(function(event){ if(event.keyCode == 13) Signin(); }); $("#sm-signUsername,#sm-signinpassword,#sm-signinCaptcha_code").keyup(function(event){ if(event.keyCode == 13) $("#smSiguin").click(); }); $("#fname,#lname,#username,#signuppassword,#signupemail,#cpassword,#signupcaptcha_code").keyup(function(event){ if(event.keyCode == 13) $("#smSiguup").click(); }); function orderByLists(order,search) { if(search == "") { var search = $("#search_box").val(); search=search.trim(); } if(search!="") { window.location.href="http://www.freexnxxxvideos.com/search/"+search+"/"+order; } else { window.location.href="http://www.freexnxxxvideos.com/order/"+order; } } function SearchTagList(search) { if(search !="") { search=search.split(/\s+/).slice(0,9).join(" "); search=search.replace(/[^a-z0-9]/gi, " "); search=search.trim(); search=search.replace(/[^a-z0-9]/gi, "-"); search=search.toLowerCase(); var intIndexOfMatch = search.indexOf("--"); while (intIndexOfMatch != -1) { search = search.replace( "--", "-" ) intIndexOfMatch = search.indexOf( "--" ); } window.location="http://www.freexnxxxvideos.com/tag/"+search; } } $(window).load(function(e) { $.ajax({ type:"POST", url: "http://www.freexnxxxvideos.com/includes/count_stats.php", data: {'pageViews':'1'}, }); $.ajax({ type:"POST", url: "http://www.freexnxxxvideos.com/includes/count_stats.php", data: {'uniqueHits':'1'}, }); }); $(document).ready(function() { $('input.typeahead').bind("typeahead:selected", function () { var search=$('#search_box').val().trim(); if(search !="") { search=search.split(/\s+/).slice(0,9).join(" "); search=search.replace(/[^a-z0-9]/gi, " "); search=search.trim(); search=search.replace(/[^a-z0-9]/gi, "-"); search=search.toLowerCase(); var intIndexOfMatch = search.indexOf("--"); while (intIndexOfMatch != -1) { search = search.replace( "--", "-" ) intIndexOfMatch = search.indexOf( "--" ); } window.location="http://www.freexnxxxvideos.com/search/"+search; } }); $('#search_box').typeahead([ { name: 'search', remote: 'http://www.freexnxxxvideos.com/includes/autocomplete.php?query=%QUERY', }]); }); $(function() { $("#userkeywords").tagsInput({ width:"auto", color:"blue" }); });