Video advertisement in the lower right corner of Baidu windows

Source: Internet
Author: User

  1. See the bottom right corner of the window
  2. <Script language = "JavaScript">
  3. VaR bd_hy_videoad ={}; (function () {var F = {videoid: "bd_hy_videoad _" + new date (). gettime (). tostring (). substring (5, 13), bgflashshow: 0, bdlogoshow: "true", bdsmallshow: "true", bdlogo: "http://eiv.baidu.com/mapm2/0306videoTest/malogo.gif", bdsmalllogo: "http://eiv.baidu.com/mapm2/0306videoTest/malogo.gif", cookietime: 1200000, playerwidth: 340, playerheight: 300, minwidth: 177, minheight: 85, bgwidth: 450, bgheight: 400, playersrc: "http://eiv.baidu.com/mapm2/0306videoNewPlayer/videoad.swf", videosrc: "http://eiv.baidu.com/mapm2/ddt0129/1.flv", imagesrc: "http://eiv.baidu.com/mapm2/ddt0129/1.jpg ", bgsrc: "http://eiv.baidu.com/mapm2/0224videobg.swf", logoswf: "http://eiv.baidu.com/mapm2/ddt0129/logo2.jpg", logopic: "http://eiv.baidu.com/mapm2/ddt0129/logo.jpg", words: "\ u767e \ u5ea6 \ u5f39 \ u5f39 \ u5802 \ u706b \ u7206 \ u5f00
    \ U6ce8 \ u518c \ u65e2 \ u9001 \ u767e \ u5143 \ u5927 \ u793c ", ctifshow:" http://tk.baidu.com/tk-rcv/sv/click.php? TRID = 3491 & Tu = d3d3lmjhawr1lmnvbq % 3d % 3d & STD = 0 ", ctautoplay:" http://tk.baidu.com/tk-rcv/sv/click.php? TRID = 3492 & Tu = d3d3lmjhawr1lmnvbq % 3d % 3d & STD = 0 ", ctreplay:" http://tk.baidu.com/tk-rcv/sv/click.php? TRID = 3492 & Tu = d3d3lmjhawr1lmnvbq % 3d % 3d & STD = 0 ", ctallplay:" http://tk.baidu.com/tk-rcv/sv/click.php? TRID = 3493 & Tu = d3d3lmjhawr1lmnvbq % 3d % 3d & STD = 0 ", ctclose:" http://tk.baidu.com/tk-rcv/sv/click.php? TRID = 3494 & Tu = d3d3lmjhawr1lmnvbq % 3d % 3d & STD = 0 ", ctvideourl:" http://tk.baidu.com/tk-rcv/sv/click.php? TRID = 3490 & Tu = percent & STD = 0 ", ctimageurl:" http://tk.baidu.com/tk-rcv/sv/click.php? TRID = 3490 & Tu = http://tk.baidu.com/tk-rcv/sv/click.php & STD = 0 ", ctlogourl? TRID = 3490 & Tu = empty & STD = 0 "}, K = NULL, r = 0, P =! Window. Opera & (navigator. appversion. indexof ("MSIE ")! =-1), j = P &&(! Window. XMLHttpRequest), $ = Document. compatmode = "css1compat", S =! P | (! J & $); Function
    M (B, E, D, C, _, A) {If (d) {var $ = new date (); $. settime ($. gettime () + d)} document. cookie = B + "=" + encodeuricomponent (e) + (D = NULL )? "": "; Expires =" + $. togmtstring () + (C = NULL )? "": "; Path =" + C) + (_ = NULL )? "": "; Domain =" + _) + ()? "; Secure": "")} function D (a) {var $ = "(? :;)? "+ A +" = ([^;] *);? ", _ = New
    Regexp ($); If (_. test (document. cookie) return decodeuricomponent (Regexp. $1); else return NULL} function q (A, $, _) {if (. addeventlistener). addeventlistener ($, _, false); else if (. attachevent). attachevent ("On" + $, _); else a ["on" + $] =_} bd_hy_videoad.setposition = function (_) {VaR
    $ = Document. getelementbyid (F. videoid + "_ Div"); k = _; If (_ = "close") {M ("bd_hy_videoad", "close", F. cookietime); N (F. ctclose); I (); $. style. display = "NONE"} else if (_ = "big") {If (! S) L (); $. style. width = f. playerwidth + "PX"; $. style. height = f. playerheight + "PX"} else if (_ = "small") {$. style. width = f. minwidth + "PX"; $. style. height = f. minheight + "PX"; if (! S) L () }}; bd_hy_videoad.logoclick = function () {window. open (F. ctlogourl, "bdvideoadnewwindow")}; bd_hy_videoad.videoclick = function () {window. open (F. ctvideourl, "bdvideoadnewwindow")}; bd_hy_videoad.videopicclick = function () {window. open (F. ctimageurl, "bdvideoadnewwindow")}; bd_hy_videoad.videoautoplay = function () {n (F. ctautoplay); G ()}; bd_hy_videoad.videoreplay = function () {n (F. ctreplay); G ()}; bd_hy_videoad.videostop = function () {n (F. ctallplay); I ()}; bd_hy_videoad.videotosmall = function () {I ()}; Function
    N ($) {(new image (1, 1 )). src = $ + "& sendtime =" + new date (). gettime (). tostring ()} function extends umentelement. clientwidth-_)-1} else {. style. top = document. body. scrolltop + (document. body. clientheight-B)-1;. style. left = document. body. scrollleft + (document. body. clientwidth-_)-1} Function
    L () {VaR _ = document. getelementbyid (F. videoid + "_ Div"); If (k = "big") E (_, F. playerwidth, F. playerheight); else if (k = "small") E (_, F. minwidth, F. minheight); If (F. bgflashshow = 1 & R = 1) {var $ = document. getelementbyid (F. videoid + "_ BG"); $. style. position = "absolute"; if ($) E ($, F. bgwidth, F. bgheight)} Function
    H () {var $ = document. getelementbyid (F. videoid + "_ Div"); if ($) {$. style. position = "absolute"; L (); q (window, "resize", L); q (window, "scroll", L)} function g () {If (F. bgflashshow = 1 & R = 0) {var $ = document. createelement ("Div"); $. innerhtml = O (F. videoid + "_ bgflash", F. bgsrc, F. bgwidth, F. bgheight); $. id = f. videoid + "_ BG"; if (s) {$. style. position = "fixed"; $. style. right = 0; $. style. bottom = 0} $. style. zindex = 2047483647; document. body. AP Pendchild ($); r = 1; if (! S) L ()} Function
    I () {If (F. bgflashshow = 1 & R = 1) {document. body. removechild (document. getelementbyid (F. videoid + "_ BG"); r = 0} function o (D, C, B, A, $) {VaR _ = '<object classid = "CLSID: d27cdb6e-ae6d-11cf-96b8-444553540000 "'+' codebase =" http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0"
    Width = "'+ B +'" Height = "'+ A +'" id = "'+ D +'" align = "Middle"> '+' <Param name = "allowScriptAccess" value = "always"> '+' <Param name = "quality" value = "high"> '+' <Param name = "wmode" value = "Transparent"> '+' <Param name = "movie" value = "'+ C + "? "+ D + '">' + '<Param name = "flashvars"
    Value = "'+ (! $? "": $) + '">' + '<Embed src ="' + C + '"flashvars ="' + (! $? "": $) + '"Quality =" high "wmode =" Transparent "width ="' + B + '"Height ="' + A + '"name ="' + D + '" align = "Middle" allowScriptAccess = "always" '+ 'Type = "application/X-Shockwave-flash" pluginspage = "http://www.macromedia.com/go/getflashplayer"> </Object> '; return
    _} Function B ($) {VaR _ = "mode =" + $ + "& logomove =" + F. logoswf + "& logopic =" + F. logopic + "& vid =" + F. videosrc + "& words =" + F. words + "& vpic =" + F. imagesrc + "& SL =" + F. bdlogoshow + "& SSL =" + F. bdsmallshow + "& bdlogo =" + F. bdlogo + "& bdslogo =" + F. bdsmalllogo; return _} function a () {var A = O (F. videoid + "_ player", F. playersrc, F. playerwidth, F. playerheight, B (k), $ = document. createelement ("Div"); $. innerhtml = A; $. id = f. videoid + "_ Div"; $. style. zindex = 2147483647; $. style. overflow = "hidden"; $. style. position = "fixed"; $. style. right = 0; $. style. bottom = 0; If (k = "small") {$. style. width = f. minwidth + "PX"; $. style. height = f. minheight + "PX"} else
    If (k = "big") {$. style. width = f. playerwidth + "PX"; $. style. height = f. playerheight + "PX" }_( $); If (! S) H (); N (F. ctifshow)} function _ ($) {If (p) {If (document. readystate = "complete") document. body. appendchild ($); else document. onreadystatechange = function () {If (document. readystate = "complete") document. body. appendchild ($)} else
    Document. Body. appendchild ($)} Function C () {var $ = D ("bd_hy_videoad"); if ($! = "Close") if ($ = "small") {k = "small"; A ()} else {k = "big"; (); M ("bd_hy_videoad", "small", F. cookietime) }} Q (window, "LOAD", c )})()
  4. </SCRIPT>
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

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.