function initSearch(){storednameval=$("#SearchForaQuestion").val();$("#SearchForaQuestion").focus(function(){if($(this).val()==storednameval){$(this).val("")}});$("#SearchForaQuestion").blur(function(){if($(this).val()==""){$(this).val(storednameval)}})}function initMyTmoPhone(){storednameval=$("#myTMobile-phone").val();$("#myTMobile-phone").focus(function(){if($(this).val()==storednameval){$(this).val("")}});$("#myTMobile-phone").blur(function(){if($(this).val()==""){$(this).val(storednameval)}})}function initMyTmoPassword(){storednameval=$("#myTMobile-password").val();$("#myTMobile-password").focus(function(){if($(this).val()==storednameval){$(this).val("")}});$("#myTMobile-password").blur(function(){if($(this).val()==""){$(this).val(storednameval)}})}function updateWebTrendTag(a){window.location=a}function changeTextToPass(d,c){var b=document.getElementById(d);var a=document.getElementById(c);a.onkeypress=function(g){if(!g){g=window.event}var f=(g.keyCode||g.charCode);if(f==13||f==3){g.cancelBubble=true;g.returnValue=false;handleLogin(mytmoUrl);return false}};b.style.display="none";a.style.display="block";a.focus()}function restorePassToText(c,d){var b=document.getElementById(c);var a=document.getElementById(d);if(b.value==""){a.style.display="block";b.style.display="none"}}function isValidMSISDNCharacter(b){var a=(b.which)?b.which:b.keyCode;if(a==13||a==3){handleLogin(mytmoUrl);return false}if(a>31&&(a<48||a>57)){if(a==189||a==45){return true}else{return false}}else{if(a==8||a==46){return true}else{return true}}}function AutoFocus(){var b=document.getElementById("myTMobile-phone").value;var a=document.getElementById("password-clear");if(b.length==10){a.focus()}}function ValidateMsisdnPassword(){var c;var a;var e;var d=navigator.userAgent.toLowerCase();var b;c=document.getElementById("myTMobile-phone");a=document.getElementById("myTMobile-password");e=document.getElementById("errMessage");if(c.value==""||c.value==" Phone #"||c.value=="Phone #"){if(a.value==""||a.value==" Password"||a.value=="Password"){e.innerHTML=errNoInfo;e.style.display="block";return false}else{e.innerHTML=errNoPhone;e.style.display="block";return false}}else{if(c.value.length<10){e.innerHTML=errInvalidPhone;e.style.display="block";return false}else{if(a.value==""||a.value==" Password"){e.innerHTML=errNoPass;e.style.display="block"}else{e.style.display="none";return true}}}}function handleLogin(){if(ValidateMsisdnPassword()){var a=document.createElement("FORM");a.name="form1";a.method="POST";a.action=mytmoUrl;var c=document.createElement("INPUT");c.type="HIDDEN";c.value=document.getElementById("myTMobile-phone").value;c.name="txtMSISDN";a.appendChild(c);var b=document.createElement("INPUT");b.type="HIDDEN";b.value=document.getElementById("myTMobile-password").value;b.name="txtPassword";a.appendChild(b);document.body.appendChild(a);a.submit();return true}else{return false}}function getClientHeight(){return f_filterResults(window.innerHeight?window.innerHeight:0,document.documentElement?document.documentElement.clientHeight:0,document.body?document.body.clientHeight:0)}function f_filterResults(d,b,a){var c=d?d:0;if(b&&(!c||(c>b))){c=b}return a&&(!c||(c>a))?a:c}var errNoInfo="Please enter phone number & password.";var errNoPass="Please enter password.";var errNoPhone="Please enter phone number.";var errInvalidPhone="Your phone number should be 10 digits.<br/> For example: 4445551212";(function(a){jQuery.fn.pngFix=function(d){d=jQuery.extend({blankgif:"blank.gif"},d);var c=(navigator.appName=="Microsoft Internet Explorer"&&parseInt(navigator.appVersion)==4&&navigator.appVersion.indexOf("MSIE 5.5")!=-1);var b=(navigator.appName=="Microsoft Internet Explorer"&&parseInt(navigator.appVersion)==4&&navigator.appVersion.indexOf("MSIE 6.0")!=-1);if(jQuery.browser.msie&&(c||b)){jQuery(this).find("img[src$=.png]").each(function(){jQuery(this).attr("width",jQuery(this).width());jQuery(this).attr("height",jQuery(this).height());var l="";var g="";var f=(jQuery(this).attr("id"))?'id="'+jQuery(this).attr("id")+'" ':"";var m=(jQuery(this).attr("class"))?'class="'+jQuery(this).attr("class")+'" ':"";var i=(jQuery(this).attr("title"))?'title="'+jQuery(this).attr("title")+'" ':"";var j=(jQuery(this).attr("alt"))?'alt="'+jQuery(this).attr("alt")+'" ':"";var h=(jQuery(this).attr("align"))?"float:"+jQuery(this).attr("align")+";":"";var e=(jQuery(this).parent().attr("href"))?"cursor:hand;":"";if(this.style.border){l+="border:"+this.style.border+";";this.style.border=""}if(this.style.padding){l+="padding:"+this.style.padding+";";this.style.padding=""}if(this.style.margin){l+="margin:"+this.style.margin+";";this.style.margin=""}var k=(this.style.cssText);g+="<span "+f+m+i+j;g+='style="position:relative;white-space:pre-line;display:inline-block;background:transparent;'+h+e;g+="width:"+jQuery(this).width()+"px;height:"+jQuery(this).height()+"px;";g+="filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+jQuery(this).attr("src")+"', sizingMethod='scale');";g+=k+'"></span>';if(l!=""){g='<span style="position:relative;display:inline-block;'+l+e+"width:"+jQuery(this).width()+"px;height:"+jQuery(this).height()+'px;">'+g+"</span>"}jQuery(this).hide();jQuery(this).after(g)});jQuery(this).find("*").each(function(){var f=jQuery(this).css("background-image");if(f.indexOf(".png")!=-1){var e=f.split('url("')[1].split('")')[0];jQuery(this).css("background-image","none");jQuery(this).get(0).runtimeStyle.filter="progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+e+"',sizingMethod='scale')"}});jQuery(this).find("input[src$=.png]").each(function(){var e=jQuery(this).attr("src");jQuery(this).get(0).runtimeStyle.filter="progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+e+"', sizingMethod='scale');";jQuery(this).attr("src",d.blankgif)})}return jQuery}})(jQuery);$(function(){$(document).pngFix()});