这个是焦点图的
<!--#include file="inc/head1.asp"-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>flash</title>
<style type="text/css">
<!--
html{ margin:0; padding:0; background:#000;}
body{ margin:0; padding:0; background:#000; }
-->
</style>
</head><body><div>
<script type="text/javascript">
          document.write('<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="480" height="281">');
          document.write('<param name="movie" value="flash.swf" />');
          document.write('<param name="quality" value="high" />');
          document.write('<param name="menu" value="false" />');
          document.write('<param name="wmode" value="transparent" />');
          document.write('<embed src="flash.swf" wmode="opaque"  menu="false" quality="high" width="480" height="281" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');
          document.write('</object>');
  
setTimeout(function(){
          var config = '4|0xffffff|0xff0000|50|0xffffff|0xff0000|0x000000';
  var files="";
  
<%
sql="select top 4 * from Photo where PhotoUrl<>'' and BigClassName='首页大图' and Passed=true order by addtime desc"
Set rs= Server.CreateObject("ADODB.Recordset")
rs.open sql,conn,1,1
t=0
do while not rs.eof
if t<rs.recordcount-1 then
%>   
 files=files+"<%=GetImg(rs("PhotoUrl"),0)%>|"; 
<%
else
%>   
 files=files+"<%=GetImg(rs("PhotoUrl"),0)%>"; 
<%
end if
t=t+1
rs.movenext
loop
rs.close
set rs=nothing
%>
     var links ="";
     var texts ="";
  document.write('<div style="top:0; left:0; background:#000; position:absolute;">');
          document.write('<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="480" height="283">');
          document.write('<param name="movie" value="focus.swf" />');
          document.write('<param name="quality" value="high" />');
          document.write('<param name="menu" value="false" />');
          document.write('<param name="wmode" value="transparent" />');
          document.write('<param name="FlashVars" value="config='+config+'&bcastr_flie='+files+'&bcastr_link='+links+'&bcastr_title='+texts+'" />');
          document.write('<embed src="focus.swf" wmode="opaque" FlashVars="config='+config+'&bcastr_flie='+files+'&bcastr_link='+links+'&bcastr_title='+texts+'" menu="false" quality="high" width="480" height="283" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');
          document.write('</object>');
          document.write('</div>');



},4300); 
</script>
</div>
</body>
</html>

解决方案 »

  1.   

    下面这个是jq框架
    // lightwindow.js v2.0
    //
    // Copyright (c) 2007 stickmanlabs
    // Author: Kevin P Miller | http://www.stickmanlabs.com
    // 
    // LightWindow is freely distributable under the terms of an MIT-style license.
    //
    // I don't care what you think about the file size...
    //   Be a pro: 
    //     http://www.thinkvitamin.com/features/webapps/serving-javascript-fast
    //      http://rakaz.nl/item/make_your_pages_load_faster_by_combining_and_compressing_javascript_and_css_files
    ///*-----------------------------------------------------------------------------------------------*/if(typeof Effect == 'undefined')
      throw("lightwindow.js requires including script.aculo.us' effects.js library!");// This will stop image flickering in IE6 when elements with images are moved
    try {
    document.execCommand("BackgroundImageCache", false, true);
    } catch(e) {}var lightwindow = Class.create();
    lightwindow.prototype = {
    //
    // Setup Variables
    //
    element : null,
    contentToFetch : null,
    windowActive : false,
    dataEffects : [],
    dimensions : {
    cruft : null,
    container : null,
    viewport : {
    height : null,
    width : null,
    offsetTop : null,
    offsetLeft : null
    }
    },
    pagePosition : {
    x : 0,
    y : 0
    },
    pageDimensions : {
    width : null,
    height : null
    },
    preloadImage : [],
    preloadedImage : [],
    galleries : [],
    resizeTo : {
    height : null,
    heightPercent : null,
    width : null,
    widthPercent : null,
    fixedTop : null,
    fixedLeft : null
    },
    scrollbarOffset : 18,
    navigationObservers : {
    previous : null,
    next : null
    },
    containerChange : {
    height : 0,
    width : 0
    },
    activeGallery : false,
    galleryLocation : {
    current : 0,
    total : 0
    },
    //
      

  2.   

    // Initialize the lightwindow.
    //
    initialize : function(options) {
    this.options = Object.extend({
    resizeSpeed : 8,
    contentOffset : {
    height : 20,
    width : 20
    },
    dimensions : {
    image : {height : 250, width : 250},
    page : {height : 250, width : 250},
    inline : {height : 250, width : 250},
    media : {height : 250, width : 250},
    external : {height : 250, width : 250},
    titleHeight : 25
    },
    classNames : {
    standard : 'lightwindow',
    action : 'lightwindow_action'
    },
    fileTypes : {
    page : ['asp', 'aspx', 'cgi', 'cfm', 'htm', 'html', 'pl', 'php4', 'php3', 'php', 'php5', 'phtml', 'rhtml', 'shtml', 'txt', 'vbs', 'rb'],
    media : ['aif', 'aiff', 'asf', 'avi', 'divx', 'm1v', 'm2a', 'm2v', 'm3u', 'mid', 'midi', 'mov', 'moov', 'movie', 'mp2', 'mp3', 'mpa', 'mpa', 'mpe', 'mpeg', 'mpg', 'mpg', 'mpga', 'pps', 'qt', 'rm', 'ram', 'swf', 'viv', 'vivo', 'wav'],
    image : ['bmp', 'gif', 'jpg', 'png', 'tiff']
    },
    mimeTypes : {
    avi : 'video/avi',
    aif : 'audio/aiff',
    aiff : 'audio/aiff',
    gif : 'image/gif',
    bmp : 'image/bmp',
    jpeg : 'image/jpeg',
    m1v : 'video/mpeg',
    m2a : 'audio/mpeg',
    m2v : 'video/mpeg',
    m3u : 'audio/x-mpequrl',
    mid : 'audio/x-midi',
    midi : 'audio/x-midi',
    mjpg : 'video/x-motion-jpeg',
    moov : 'video/quicktime',
    mov : 'video/quicktime',
    movie : 'video/x-sgi-movie',
    mp2 : 'audio/mpeg',
    mp3 : 'audio/mpeg3',
    mpa : 'audio/mpeg',
    mpa : 'video/mpeg',
    mpe : 'video/mpeg',
    mpeg : 'video/mpeg',
    mpg : 'audio/mpeg',
    mpg : 'video/mpeg',
    mpga : 'audio/mpeg',
    pdf : 'application/pdf',
    png : 'image/png',
    pps : 'application/mspowerpoint',
    qt : 'video/quicktime',
    ram : 'audio/x-pn-realaudio-plugin',
    rm : 'application/vnd.rn-realmedia',
    swf : 'application/x-shockwave-flash',
    tiff : 'image/tiff',
    viv : 'video/vivo',
    vivo : 'video/vivo',
    wav : 'audio/wav',
    wmv : 'application/x-mplayer2'
    },
      

  3.   

    classids : {
    mov : 'clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B',
    swf : 'clsid:D27CDB6E-AE6D-11cf-96B8-444553540000',
    wmv : 'clsid:6BF52A52-394A-11d3-B153-00C04F79FAA6'
    },
    codebases : {
    mov : 'http://www.apple.com/qtactivex/qtplugin.cab#version=6,0,2,0',
    swf : 'http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0',
    wmv : 'http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,5,715'
    },
    viewportPadding : 10,
    EOLASFix : 'swf,wmv,fla,flv',
    overlay : {
    opacity : 0.7,
    image : 'images/black.png',
    presetImage : 'images/black-70.png'
    },
    skin :  {
    main :  '<div id="lightwindow_container" >'+
    '<div id="lightwindow_title_bar" >'+
    '<div id="lightwindow_title_bar_inner" style="margin-left:10px;">'+
    '<span id="lightwindow_title_bar_title"></span>'+
    '<a id="lightwindow_title_bar_close_link" ><img src="images/closelabel.gif" style="margin-right:10px;"></a>'+
    '</div>'+
    '</div>'+
    '<div id="lightwindow_stage" >'+
    '<div id="lightwindow_contents" >'+
    '</div>'+
    '<div id="lightwindow_navigation" >'+
    '<a href="#" id="lightwindow_previous" >'+
    '<span id="lightwindow_previous_title"></span>'+
    '</a>'+
    '<a href="#" id="lightwindow_next" >'+
    '<span id="lightwindow_next_title"></span>'+
    '</a>'+
    '<iframe name="lightwindow_navigation_shim" id="lightwindow_navigation_shim" src="javascript:false;" frameBorder="0" scrolling="no"></iframe>'+
    '</div>'+
    '<div id="lightwindow_galleries">'+
    '<div id="lightwindow_galleries_tab_container" >'+
    '<a href="#" id="lightwindow_galleries_tab" >'+
    '<span id="lightwindow_galleries_tab_span" class="up" >Galleries</span>'+
    '</a>'+
    '</div>'+
    '<div id="lightwindow_galleries_list" >'+
    '</div>'+
    '</div>'+
    '</div>'+
    '<div id="lightwindow_data_slide" >'+
    '<div id="lightwindow_data_slide_inner" >'+
    '<div id="lightwindow_data_details" >'+
    '<div id="lightwindow_data_gallery_container" >'+
    '<span id="lightwindow_data_gallery_current"></span>'+
    ' of '+
    '<span id="lightwindow_data_gallery_total"></span>'+
    '</div>'+
    '<div id="lightwindow_data_author_container" >'+
    'by <span id="lightwindow_data_author"></span>'+
    '</div>'+
    '</div>'+
    '<div id="lightwindow_data_caption" >'+
    '</div>'+
    '</div>'+
    '</div>'+
    '</div>',
    loading :  '<div id="lightwindow_loading" >'+
    '<img src="images/ajax-loading.gif" alt="loading" />'+
    '<span>Loading or <a href="javascript: myLightWindow.deactivate();">Cancel</a></span>'+
    '<iframe name="lightwindow_loading_shim" id="lightwindow_loading_shim" src="javascript:false;" frameBorder="0" scrolling="no"></iframe>'+
    '</div>',
    iframe :  '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">'+
    '<html xmlns="http://www.w3.org/1999/xhtml">'+
    '<body>'+
    '{body_replace}'+
    '</body>'+
    '</html>',
    gallery : {
    top : '<div class="lightwindow_galleries_list">'+
    '<h1>{gallery_title_replace}</h1>'+
    '<ul>',
    middle :  '<li>'+
    '{gallery_link_replace}'+
    '</li>',
    bottom :  '</ul>'+
    '</div>'
    }
    },
    formMethod : 'get',
    hideFlash : false,
    hideGalleryTab : false,
    showTitleBar : true,
    animationHandler : false,
    navigationHandler : false,
    transitionHandler : false,
    finalAnimationHandler : false,
    formHandler : false,
    galleryAnimationHandler : false,
    showGalleryCount : true
    }, options || {});
    this.duration = ((11-this.options.resizeSpeed)*0.15);
    this._setupLinks();
    this._getScroll();
    this._getPageDimensions();
    this._browserDimensions();
    this._addLightWindowMarkup(false);
    this._setupDimensions(); 
    this.buildGalleryList();
    },
    //
    // Activate the lightwindow.
    //
    activate : function(e, link){
    // Clear out the window Contents
    this._clearWindowContents(true);

    // Add back in out loading panel
    this._addLoadingWindowMarkup(); // Setup the element properties
    this._setupWindowElements(link);

    // Setup everything
    this._getScroll();
    this._browserDimensions();
    this._setupDimensions();
    this._toggleTroubleElements('hidden', false);
    this._displayLightWindow('block', 'hidden');
    this._setStatus(true);
    this._monitorKeyboard(true);
    this._prepareIE(true);
    this._loadWindow();
    },
    //
    // Turn off the window
    //
    deactivate : function(){
    // The window is not active
    this.windowActive = false;

    // There is no longer a gallery active
    this.activeGallery = false;
    if (!this.options.hideGalleryTab) {
    this._handleGalleryAnimation(false);
    }

    // Kill the animation
    this.animating = false;

    // Clear our element
    this.element = null;

    // hide the window.
    this._displayLightWindow('none', 'visible');

    // Clear out the window Contents
    this._clearWindowContents(false);

    // Stop all animation
    var queue = Effect.Queues.get('lightwindowAnimation').each(function(e){e.cancel();});

    // Undo the setup
    this._prepareIE(false);
    this._setupDimensions();
    this._toggleTroubleElements('visible', false);
    this._monitorKeyboard(false);
    },
      

  4.   

    代码真的很多,我是一个完全不懂JS的人,他也不是完全的冲突,只是点击另外一个JQ框架时,多点几次,焦点图的一张图会变成空白,刷新又没事了,真的搞不懂
      

  5.   

    代码真的很多,我是一个完全不懂JS的人,他也不是完全的冲突,只是点击另外一个JQ框架时,多点几次,焦点图的一张图会变成空白,刷新又没事了,真的搞不懂