﻿//搜索input里用的
function showwords(thisobj,keywords,thistype) {
            if (thistype) {
                if (thisobj.value == "") {
                    thisobj.value = keywords;
                    thisobj.style.color = '#999999';
                }
            } else {
                if (thisobj.value == keywords) {
                    thisobj.value = "";
                    thisobj.style.color = '#666666';
                }
            }
        }
//显示剩余字数
function GetLeaveCount(obj, totalcount, des) {
            var dest = document.getElementById(des);
            var old = obj.value;
            var leave = totalcount - obj.value.length;
            dest.innerHTML = (totalcount - obj.value.length);
            if (leave<=0) {
                dest.innerHTML = "0";
                obj.value = (obj.value).substring(0,totalcount);
            } 
         }
