$(document).ready(function(){$("#login").click(function(){$("#member-login").slideToggle(400);$("#login-username").focus()});$("#login-submit").click(function(){if($("#myLogin").valid()){var a=$("#login-username").val(),b=$("#login-password").val();$.post("/resources/vb/post-member-login.asp",{username:a,password:b},function(c){if(c=="")window.location="/members/members-home";else{$("#login-response").empty();$("#login-response").css("color","red");$("#login-response").append(c);Cufon.replace("h2")}})}return false}); $("#logout").click(function(){$.post("/resources/vb/post-member-login.asp",function(a){if(a=="")window.location="/"})});$("#update-profile").click(function(){if($("#myForm").valid()){$.post("/resources/vb/post-member-profile-update.asp",{fAction:$(this).attr("id"),fPassword:$("#fPassword").val(),fTitle:$("#fTitle").val(),fForename:$("#fForename").val(),fSurname:$("#fSurname").val(),fEmail:$("#fEmail").val(),fCompany:$("#fCompany").val(),fAddress:$("#fAddress").val(),fTown:$("#fTown").val(),fCounty:$("#fCounty").val(), fPostcode:$("#fPostcode").val()});$("#content").empty();$("#content").append("<h1>Thank you</h1>Your profile has been successfully updated");Cufon.replace("h1");$("#fPassword").val("")}return false});$(".i-delete").click(function(){var a=$(this).attr("id").replace("this","");$.post("/resources/vb/post-member-message-update.asp",{id:a},function(b){if(b=="ok"){$("#row_"+a).fadeOut(250);$(".member-message-header").fadeOut(250)}else $("#row_"+a).fadeOut(250)})});$("#btnSearch").click(function(){if($("#mySearch").valid())return true; return false});$(".lightbox").lightBox({fixedNavigation:true});$(".search").focus(function(){if(this.value=="search...")this.value=""});window.opera&&$("a.bookmark").attr("rel")!=""&&$("a.bookmark").attr("rel","sidebar");$("a.bookmark").click(function(a){a.preventDefault();a=this.href;var b=this.title;if(window.sidebar)window.sidebar.addPanel(b,a,"");else if(window.external)window.external.AddFavorite(a,b);else if(window.opera)return false;else alert("Sorry, your browser does not support the requested action, please add this page manually to your bookmarks.")})}); Cufon.replace("h1")("h2")(".h3");function notify(a){$("#response").empty();$("#response").fadeIn("slow");$("#response").css("color","#e97d0d");$("#response").append(a);$("#response").animate({opacity:1},5E3);$("#response").fadeOut("slow")};