網站訪問量增加

來源:互聯網
上載者:User

標籤:val   string   start   value   name   cut   sub   doc   secure   

<script language=JavaScript><!--var caution = falsefunction setCookie(name, value, expires, path, domain, secure) {var curCookie = name + "=" + escape(value) +((expires) ? "; expires=" + expires.toGMTString() : "") +((path) ? "; path=" + path : "") +((domain) ? "; domain=" + domain : "") +((secure) ? "; secure" : "")if (!caution || (name + "=" + escape(value)).length <= 4000)document.cookie = curCookieelseif (confirm("Cookie exceeds 4KB and will be cut!"))document.cookie = curCookie}function getCookie(name) {var prefix = name + "="var cookieStartIndex = document.cookie.indexOf(prefix)if (cookieStartIndex == -1)return nullvar cookieEndIndex = document.cookie.indexOf(";", cookieStartIndex + prefix.length)if (cookieEndIndex == -1)cookieEndIndex = document.cookie.lengthreturn unescape(document.cookie.substring(cookieStartIndex + prefix.length, cookieEndIndex))}function deleteCookie(name, path, domain) {if (getCookie(name)) {document.cookie = name + "=" +((path) ? "; path=" + path : "") +((domain) ? "; domain=" + domain : "") +"; expires=Thu, 01-Jan-70 00:00:01 GMT"}}function fixDate(date) {var base = new Date(0)var skew = base.getTime()if (skew > 0)date.setTime(date.getTime() - skew)}var now = new Date()fixDate(now)now.setTime(now.getTime() + 365 * 24 * 60 * 60 * 1000)var visits = getCookie("counter")if (!visits)visits = 1elsevisits = parseInt(visits) + 1setCookie("counter", visits, now)document.write("歡迎您,您是第" + visits + "位訪問本商店的!")// --></script>

網站訪問量增加

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.