久艹网,亚洲一日韩欧美中文字幕2019,国产欧美日韩精品专区黑人,一区二区三区久久99

中山php|最優(yōu)網(wǎng)絡(luò)中山做網(wǎng)站 中山php建站

最優(yōu)良人

Category Page for: 網(wǎng)站前端

用新浪搜狐騰訊jS接口取客戶端IP及省份城市

2013/05/13 at 12:56 » Comments (689)

新浪的IP地址查詢接口:http://int.dpool.sina.com.cn/iplookup/iplookup.php?format=js 新浪多地域測試方法:http://int.dpool.sina.com.cn/iplookup/iplookup.php?format=js&ip=218.192.3.42 搜狐IP地址查詢接口(默認GBK):http://pv.sohu.com/cityjson 搜狐IP地址查詢接口(可設(shè)置編碼):http://pv.sohu.com/cityjson?ie=utf-8 搜狐另外的IP地址查詢接口:http://txt.go.sohu.com/ip/soip 騰訊的接口:http://fw.qq.com/ipaddress (騰訊的接口原本是最好用的,可現(xiàn)在打不開啦) 上面的接口中新浪的是js接口說明: <script type="text/javascript" src="http://int.dpool.sina.com.cn/iplookup/iplookup.php?format=js" charset="gb2312"></script> <script type="text/javascript"> function ipmsg() { var ss = remote_ip_info['country']??+ remote_ip_info['province']+ remote_ip_info['city']; document.getElementByIdx_x_x("<%=HiddenField1.ClientID %>").value = ss; } </script>   more »

select下拉菜單實現(xiàn)友情鏈接跳轉(zhuǎn)

2012/10/07 at 16:47 » Comments (399)

<select name="select" class="home_left_select" onchange="window.location=this.options[this.selectedIndex].value"> <option value="#">友情鏈接</option> <option value="http://www.baidu.com">2</option> <option value="http://www.baidu.com">2</option> <option value="http://www.baidu.com">2</option> <option value="http://www.baidu.com">2</option> <option value="http://www.baidu.com">2</option> </select> 以上代碼實現(xiàn)選中項跳轉(zhuǎn)到指定鏈接 more »

JS獲取file上傳文件路徑,后綴,大小,文件名

2012/08/16 at 11:58 » Comments (184)

/** *函數(shù)描述:獲取input type=file的圖像全路徑 * @obj input type=file的對象 **/ function getFullPath(obj) { if(obj) { //ie if (window.navigator.userAgent.indexOf("MSIE")>=1) { obj.select(); return document.selection.createRange().text; } //firefox else if(window.navigator.userAgent.indexOf("Firefox")>=1) { if(obj.files) { return obj.files.item(0).getAsDataURL(); } return obj.value; } return obj.value; } }   <input type="file" onchange="document.getElementById('img').src=getFullPath(this);" >   =========================================================================     #判斷IE還是Firefox function getFullPath(obj) { if(obj) { //ie if (window.navigator.userAgent.indexOf("MSIE")>=1) { obj.select(); return document.selection.createRange().text; } //firefox else if(window.navigator.userAgent.indexOf("Firefox")>=1) { if(obj.files) { return obj.files.item(0).getAsDataURL(); } return obj.value; } return obj.value; } }       #判斷后綴名 function yulan(){ var filePath =getFullPath(document.getElementById('UpFile')); var fileText =filePath.substring(filePath.lastIndexOf("."),filePath.length); var ...more »

ie6實現(xiàn)div頁面固定不動,純CSS中使用expression兼容fix

2012/08/01 at 17:36 » Comments (437)

* html,* html body /* IE6 Fixed Position Jitter Fix */{background-image:url(about:blank);background-attachment:fixed;} * html .fixed-top /* IE6 position fixed Top */{position:absolute;bottom:auto;top:expression(eval(document.documentElement.scrollTop));} * html .fixed-right /* IE6 position fixed right */{position:absolute;right:auto;left:expression(eval(document.documentElement.scrollLeft+document.documentElement.clientWidth-this.offsetWidth)-(parseInt(this.currentStyle.marginLeft,10)||0)-(parseInt(this.currentStyle.marginRight,10)||0));} * html .fixed-bottom /* ...more »

JS 把字符串轉(zhuǎn)成整數(shù)的函數(shù)

2012/07/21 at 12:35 » Comments (459)

parseInt()把字符串轉(zhuǎn)成整數(shù) parseFloat()把字符串轉(zhuǎn)成浮點數(shù) js在處理變量的數(shù)學運算時一點要注意變量類型的轉(zhuǎn)換 JS 字符串轉(zhuǎn)整數(shù) JS 字符串轉(zhuǎn)整數(shù)方法主要有三種轉(zhuǎn)換函數(shù)、強制類型 轉(zhuǎn)換、利用js 變量弱類型轉(zhuǎn)換。 1.轉(zhuǎn)換函數(shù): js 提供了parseInt()和parseFloat()兩個轉(zhuǎn)換函數(shù)。 前者把值轉(zhuǎn)換成整 數(shù),后者把值轉(zhuǎn)換成浮點數(shù)。只有對String 類型調(diào)用這些方法,這兩個函數(shù)才 能正確運行;對其他類型返回的都是NaN(Not aNumber)。 在判斷字符串是否是數(shù)字值前,parseInt()和parseFloat()都會仔細分析 該字符串。 parseInt()方法首先查看位置0 處的字符,判斷它是否是個有效數(shù)字;如 果不是,該方法將返回NaN,不再繼續(xù)執(zhí)行其他操作。但如果該字符是有效數(shù) 字,該方法將查看位置1 處的字符,進行同樣的測試。這一過程將持續(xù)到發(fā)現(xiàn) 非有效數(shù)字的字符為止,此時 parseInt()將把該字符之前的字符串轉(zhuǎn)換成數(shù)字。 例如,如果要把字符串"1234blue"轉(zhuǎn)換成整數(shù),那么parseInt()將返回 1234,因為當它檢測到字符b 時,就會停止檢測過程。 字符串中包含的數(shù)字字面量會被正確轉(zhuǎn)換為數(shù)字,因此字符串"0xA"會被正 確轉(zhuǎn)換為數(shù)字10。 ...more »

在線客服代碼,qq,msn,skype,淘寶旺旺,阿里巴巴貿(mào)易通,雅虎通

2012/06/05 at 17:43 » Comments (427)

1.QQ在線咨詢代碼 (qq在線交談代碼/qq在線客服代碼/qq在線狀態(tài)代碼/qq在線客服代碼) (將66757924換成你的號碼,site后面換成你的網(wǎng)站就可以了) <a target="blank" href="http://wpa.qq.com/msgrd?V=1&Uin=66757924&Site=服務(wù)易& Menu=yes"><img border="0" SRC=http://wpa.qq.com/pa?p=1:66757924:6 alt="點擊這里給我發(fā)消息" align="absmiddle"></a> 2.MSN在線咨詢代碼 用的時候把[郵件地址]寫成你的MSN賬號,不要方括號,用鏈接即可,如 <a target="blank" href="msnim:chat?contact=sliang@zui88.com">MSN在線客服</a> 3.skype在線狀態(tài)代碼生成 將yisung換成你的skype ID就可以了,需要在skype個人賬戶里設(shè)置對任何人顯示狀態(tài) <a target="blank" href="skype:mengsajewel?call"><img src=http://mystatus.skype.com/smallclassic/yisung style="border: none;" alt="Call me!" /></a> 更多的skype在線狀態(tài)代碼生成樣式,請查看skype的官方網(wǎng)站 http://www.skype.com/share/buttons/ 4.淘寶旺旺 <a target="_blank" ...more »

文字圖片向上滾動的JS代碼

2012/05/29 at 11:38 » Comments (193)

<div id="demo"> <div id="demo1"> <ul> <li> 文字圖片內(nèi)容   </li> </ul> </div> <div id="demo2"></div>   <script type="text/javascript"> var speed=10; var FGDemo=document.getElementById('demo'); var FGDemo1=document.getElementById('demo1'); var FGDemo2=document.getElementById('demo2'); FGDemo2.innerHTML=FGDemo1.innerHTML function Marquee1(){ if(FGDemo2.offsetHeight-FGDemo.scrollTop<=0) FGDemo.scrollTop-=FGDemo1.offsetHeight else{ FGDemo.scrollTop++ } } var MyMar1=setInterval(Marquee1,speed) FGDemo.onmouseover=function() {clearInterval(MyMar1)} FGDemo.onmouseout=function() {MyMar1=setInterval(Marquee1,speed)} </script> </div> more »

ie6下,浮動的li里面文字不換行

2012/05/19 at 17:46 » Comments (192)

在ie6下,浮動的li里面文字在結(jié)尾出寬度不夠,但是不自動換行,而是往下擠,使后面的li亂掉。 解決的方法是在li里面定義樣式 white-space: nowrap; more »

最簡單的設(shè)為首頁,加入收藏代碼

2012/05/05 at 18:20 » Comments (45)

只要一句代碼,可以實現(xiàn)設(shè)為首頁,加入收藏的功能,并且通用其他網(wǎng)站,自動識別標題和鏈接,不用手動修改。但是只兼容ie瀏覽器。 <a href="#" onClick="this.style.behavior='url(#default#homepage)'; this.setHomePage(window.location.href);">設(shè)為首頁</a> | <a href="#" onClick="window.external.addFavorite(window.location.href,document.title)">加入收藏</a> more »

CSS border-collapse 屬性,細邊線table表格樣式

2012/03/08 at 14:56 » Comments (374)

border-collapse 屬性設(shè)置表格的邊框是否被合并為一個單一的邊框,還是象在標準的 HTML 中那樣分開顯示。 可能的值 值 描述 separate 默認值。邊框會被分開。不會忽略 border-spacing 和 empty-cells 屬性。 collapse 如果可能,邊框會合并為一個單一的邊框。會忽略 border-spacing 和 empty-cells 屬性。 inherit 規(guī)定應(yīng)該從父元素繼承 border-collapse 屬性的值。 細邊線table表格樣式 table {width:100%; border:1px solid #ccc; border-collapse:collapse;} table td {border:1px solid #ccc; border-collapse:collapse; padding:10px 15px; color:#999;} more »