Javascript + FLASH slides play image scripts and organize code to make calling easier! Javascript + FLASH slide playback image scripts, code sorting, making calls more convenient
Many major websites have javascript + FLASH slide playing image scripts, and the code has been compiled to make the call more convenient!
<! Doctype html public "-// W3C // dtd html 4.0 Transitional // EN"> <HTML> <HEAD> <TITLE> Generate a slide-type webpage image effect demonstration </TITLE> <META http-equiv = Content-Type content = "text/html; charset = gb2312 "> <META content =" "name = Keywords> <META content =" "name = Description> </HEAD> <BODY> <center> Generate a slide-type webpage image effect demonstration <pr style = "border-style: dotted; border-width: 1px "width =" 80% "size =" 1 "color =" # C0C0C0 "> <SCRIPT type = text/javascript> // slide-based webpage image scrolling function (no need to do anything changes) // This program is organized by Guangzhou real estate network. You are welcome to repost it and provide comments. The copyright does not include function roll_pic_flash (roll_pic_ary) {// generate a slide-type webpage image scrolling code var w = roll_pic_ary [3] [0]; var h = roll_pic_ary [3] [1]; var text_h = roll_pic_ary [3] [2]; var bgcolor = roll_pic_ary [3] [3]; var roll_swf = roll_pic_ary [3] [4]; var swf_height = h + text_h; var pics = roll_pic_ary [0]. join ("|"); var links = roll_pic_ary [1]. join ("|"); var texts = roll_pic_ary [2]. join ("|"); return '<object classid = "clsid: d27cdb6e-ae6d-11cf-96b8-444553540000" codebase =" http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0 "Width =" '+ w +' "height =" '+ swf_height +' "> <param name =" default_url "value =" http://www.hbw.cn/ "> <Param name =" allowScriptAccess "value =" sameDomain "> <param name =" movie "value =" '+ roll_swf +' "> <param name =" quality "value = "high"> <param name = "bgcolor" value = "'+ bgcolor +'"> <param name = "menu" value = "false"> <param name =" improved_by "value =" http://www.gzfangzi.com /"> <Param name = wmode value =" opaque "> <param name =" FlashVars "value =" pics = '+ pics +' & links = '+ links + '& texts = '+ texts +' & borderwidth = '+ w +' & borderheight = '+ h +' & textheight = '+ text_h +' "> <embed src =" '+ roll_swf + '"wmode =" opaque "FlashVars =" pics =' + pics + '& links =' + links + '& texts =' + texts + '& borderwidth =' + w + '& borderheight =' + h + '& textheight =' + text_h + '"menu =" false "bgcolor ="' + bgcolor + '"quality =" high "width = "'+ w +'" height = "'+ h +'" allowScriptAccess = "sameDomain" type = "application/x-shockwave-flash" pluginspage =" http://www.macromedia.com/go/getflashplayer "/> </Object> ';} // start to set the slide parameter var roll_pic_width = 450; // The Image Width var roll_pic_height = 300; // The Image Height var roll_text_height = 22; // text height var roll_bgcolor = '# ffff'; // slide background color var roll_flash =' http://www.gzfangzi.com /Demo/ad/roll_js_flash.swf '; // slide flash Address. Download and save the flash to your server to avoid invalidation. // initialize the slide array roll_pic_ary (no changes are required) var roll_pic_ary = new Array (0), Array (0), Array (0), Array (roll_pic_width, roll_pic_height, roll_text_height, roll_bgcolor, roll_flash )); // Add an image, connect, and text description roll_pic_ary [0]. push (" http://www.gzfangzi.com /Demo/ad/1.jpg"); roll_pic_ary [1]. push (escape (" http://www.gzfangzi.com "); Roll_pic_ary [2]. push (" Picture 1 of a Super Girl Press Conference "); roll_pic_ary [0]. push (" http://www.gzfangzi.com /Demo/ad/2.jpg"); roll_pic_ary [1]. push (escape (" http://www.gzfangzi.com "); Roll_pic_ary [2]. push (" Super Girl press conference Image 2 "); roll_pic_ary [0]. push (" http://www.gzfangzi.com /Demo/ad/3.jpg"); roll_pic_ary [1]. push (escape (" http://www.gzfangzi.com "); Roll_pic_ary [2]. push (" Super Girl's wonderful performance 1 "); roll_pic_ary [0]. push (" http://www.gzfangzi.com /Demo/ad/4.jpg"); roll_pic_ary [1]. push (escape (" http://www.gzfangzi.com "); Roll_pic_ary [2]. push (" Super Girl's wonderful performance 2 "); roll_pic_ary [0]. push (" http://www.gzfangzi.com /Demo/ad/5.jpg"); roll_pic_ary [1]. push (escape ("Super Girl's wonderful performance 3"); roll_pic_ary [2]. push ("text description"); roll_pic_ary [0]. push (" http://www.gzfangzi.com /Demo/ad/6.jpg"); roll_pic_ary [1]. push (escape ("Super Girl's wonderful performance 4"); roll_pic_ary [2]. push ("text description"); // display a slide-type webpage image scroll document. write (roll_pic_flash (roll_pic_ary); SCRIPT <pr style = "border-style: dotted; border-width: 1px "width =" 80% "size =" 1 "color =" # C0C0C0 "> </center> </BODY> </HTML>
[Ctrl + A select all Note: If you need to introduce external Js, You need to refresh it to execute]