52AV璈A|52AV.ONE

 曉撖蝣
 蝡唾酉
敹急瑕
  • av隢憯BBS
  • 璈A
  • 芣瑟憭瘚
  • 鞎澆
  • 52av鋆貉摰
  • 銝剜-銝剖銝餅
Yahoo!憟拇撠
望: 璈A
Google憟拇撠
望: 璈A
     
亦: 4082|敺: 0
銝銝銝駁 銝銝銝駁

[HTML] 敺桀航閬蝒批捆撠箏站--Javascript[1撘萄]

[銴鋆賡包
頝唾唳摰璅撅
璅銝
潸” 2014-12-10 17:42:11 | 芰閰脖 |芰憭批 撣 |摨閬 |梯璅∪
砍敺 media 2014-12-10 19:08 蝺刻摩 9 X/ p; Y, \- z7 p% \& z* h9 I

; t, C* |4 _  k1 j餈甫avascript閬蝒憭批嚗唬閬賢函⊥菜葫銝撖祇憿敺靘曉唬畾菟畾萇撘蝣潘嗥冽潮曉之銝阡*蝷箸澆臭葉憭桐蝵格撣豢具# n$ h, X. g& C/ g$ }
  1. <script type="text/javascript">3 n8 j7 T5 G/ O# J: ?
  2. <!--
    / b+ }+ s* @' t! `: r
  3. 3 y, Q/ ^. m+ o
  4. var viewportwidth;
    ( ^. d( r7 c( }, E9 K* ~
  5. var viewportheight;  I* Q" \) m* Q7 Z/ N# B
  6. 3 q3 k/ l& Z( i7 Y' V+ E* c: Q" }
  7. // the more standards compliant browsers (mozilla/netscape/opera/IE7) use window.innerWidth and window.innerHeight$ X3 D+ G/ d( ]. X9 H/ Q! B
  8. # f* V) C/ a5 `8 y* B) S. A
  9. if (typeof window.innerWidth != 'undefined')
    3 m4 J4 |0 m% X
  10. {
    ( c8 @% X0 h  l$ s& V! A
  11.       viewportwidth = window.innerWidth,
    ! S7 ~9 c" H5 e1 t% m! D% o7 k
  12.       viewportheight = window.innerHeight
    7 R# U0 W: o+ i0 G" l" B$ }; h
  13. }& Z9 f$ J3 ]4 J+ ?
  14. / `+ n& ^7 s: A4 `0 B
  15. // IE6 in standards compliant mode (i.e. with a valid doctype as the first line in the document)( y2 o, C4 A/ i' R2 B$ Y' Z8 Y! X

  16. 5 O% m& v6 L& ~# k6 P6 `! F
  17. else if (typeof document.documentElement != 'undefined'
    ) m$ `: X1 y! N9 b) J9 [* R( y: y0 z
  18.      && typeof document.documentElement.clientWidth !=9 y1 V) [  H6 J
  19.      'undefined' && document.documentElement.clientWidth != 0)
    7 o) q8 v9 `2 H, }. \2 T
  20. {# z+ G" J# h& q6 t! s1 N6 a8 N
  21.        viewportwidth = document.documentElement.clientWidth,4 l$ d/ h' V* J5 h0 H" s
  22.        viewportheight = document.documentElement.clientHeight
    * L" ?; l# v3 `6 z- R  i1 a
  23. }
    , P# t$ z& ]2 x* H

  24. ! B& @2 j4 m9 F
  25. // older versions of IE6 F  U& n' Y& K+ v* Y

  26. . g) X7 d  n7 Y, l9 G" _
  27. else
    0 p/ f$ l! \* b9 n* `6 _. |1 Q4 B7 k4 Y
  28. {  h/ F8 R, p0 x: ?1 s
  29.        viewportwidth = document.getElementsByTagName('body')[0].clientWidth,, p6 W: r& d! w0 g! S( ]
  30.        viewportheight = document.getElementsByTagName('body')[0].clientHeight. c7 `# d7 k$ Z+ I! P6 l, \8 Z
  31. }
    9 R% w$ h# W, e5 X8 M5 Y
  32. document.write('<p>Your viewport width is '+viewportwidth+'x'+viewportheight+'</p>');* Y  s0 `# U" T
  33. //-->
    " h4 x1 k, w" V  c
  34. </script>
銴鋆賭誨蝣
蝯: 狂oogle chrome 憿舐內蝯2 [0 [" I8 B5 t0 w' ?5 H; ^0 @

; A; N3 c1 d! y) a1 K) C5 e( V

/ b; o, C; A/ ~$ ~靘皞:
Get viewport size (width and height) with javascript

0 U' ?8 e* h& c( c/ {+ o! `' a- {' Z
! [( w4 A! W( h# J" K, F

雿輻券

祉蝛閬

BT蝳

砍憛批捆靘餉衣雯頝臬批捆蝝颲行粹嗥蝬脩嚗摰撟湔遛嚗嚗甇脖誑銝嗅啣摰嗆摰撟湧翩鈭箏ㄚ孵舫脣伐銝憿亙祉璇甈橘芣遛18甇 雓蝯脣亦閬賬粹脩芣遛18甇脖芣撟渡雯閬賜雯頝臭嗥批捆鞈閮嚗撱箄降典舫脰蝬脰楝批捆蝝蝯蝜ICRA蝝摰鋆閮剖 (粹蝯行霅 祉蝬脣銝蝝瘛函隢憯啣嚗祉閮剜蝞∠)

QQ|撠暺撅||52AV璈A

GMT+8, 2024-11-21 23:05 , Processed in 0.064701 second(s), 19 queries .

蝯∠.撱

52avtv@gmail.com | QQ:2405733034     since 2015-01

鋆貉憒 敹恍敺 餈銵