|
|
Line 1: |
Line 1: |
- | <html lang="en">
| |
- | <!--解决IE 6不支持png格式的代码-->
| |
- | <!--[if IE 6]>
| |
- | <script type="text/javascript">
| |
- | /**
| |
- | * DD_belatedPNG: Adds IE6 support: PNG images for CSS background-image and HTML <IMG/>.
| |
- | * Author: Drew Diller
| |
- | * Email: drew.diller@gmail.com
| |
- | * URL: http://www.dillerdesign.com/experiment/DD_belatedPNG/
| |
- | * Version: 0.0.8a
| |
- | * Licensed under the MIT License: http://dillerdesign.com/experiment/DD_belatedPNG/#license
| |
- | *
| |
- | * Example usage:
| |
- | * DD_belatedPNG.fix('.png_bg'); // argument is a CSS selector
| |
- | * DD_belatedPNG.fixPng( someNode ); // argument is an HTMLDomElement
| |
- | **/
| |
| | | |
- | /*
| |
- | PLEASE READ:
| |
- | Absolutely everything in this script is SILLY. I know this. IE's rendering of certain pixels doesn't make sense, so neither does this code!
| |
- | */
| |
- |
| |
- | var DD_belatedPNG = {
| |
- | ns: 'DD_belatedPNG',
| |
- | imgSize: {},
| |
- | delay: 10,
| |
- | nodesFixed: 0,
| |
- | createVmlNameSpace: function () { /* enable VML */
| |
- | if (document.namespaces && !document.namespaces[this.ns]) {
| |
- | document.namespaces.add(this.ns, 'urn:schemas-microsoft-com:vml');
| |
- | }
| |
- | },
| |
- | createVmlStyleSheet: function () { /* style VML, enable behaviors */
| |
- | /*
| |
- | Just in case lots of other developers have added
| |
- | lots of other stylesheets using document.createStyleSheet
| |
- | and hit the 31-limit mark, let's not use that method!
| |
- | further reading: http://msdn.microsoft.com/en-us/library/ms531194(VS.85).aspx
| |
- | */
| |
- | var screenStyleSheet, printStyleSheet;
| |
- | screenStyleSheet = document.createElement('style');
| |
- | screenStyleSheet.setAttribute('media', 'screen');
| |
- | document.documentElement.firstChild.insertBefore(screenStyleSheet, document.documentElement.firstChild.firstChild);
| |
- | if (screenStyleSheet.styleSheet) {
| |
- | screenStyleSheet = screenStyleSheet.styleSheet;
| |
- | screenStyleSheet.addRule(this.ns + '\\:*', '{behavior:url(#default#VML)}');
| |
- | screenStyleSheet.addRule(this.ns + '\\:shape', 'position:absolute;');
| |
- | screenStyleSheet.addRule('img.' + this.ns + '_sizeFinder', 'behavior:none; border:none; position:absolute; z-index:-1; top:-10000px; visibility:hidden;'); /* large negative top value for avoiding vertical scrollbars for large images, suggested by James O'Brien, http://www.thanatopsic.org/hendrik/ */
| |
- | this.screenStyleSheet = screenStyleSheet;
| |
- |
| |
- | /* Add a print-media stylesheet, for preventing VML artifacts from showing up in print (including preview). */
| |
- | /* Thanks to R閙i Pr関ost for automating this! */
| |
- | printStyleSheet = document.createElement('style');
| |
- | printStyleSheet.setAttribute('media', 'print');
| |
- | document.documentElement.firstChild.insertBefore(printStyleSheet, document.documentElement.firstChild.firstChild);
| |
- | printStyleSheet = printStyleSheet.styleSheet;
| |
- | printStyleSheet.addRule(this.ns + '\\:*', '{display: none !important;}');
| |
- | printStyleSheet.addRule('img.' + this.ns + '_sizeFinder', '{display: none !important;}');
| |
- | }
| |
- | },
| |
- | readPropertyChange: function () {
| |
- | var el, display, v;
| |
- | el = event.srcElement;
| |
- | if (!el.vmlInitiated) {
| |
- | return;
| |
- | }
| |
- | if (event.propertyName.search('background') != -1 || event.propertyName.search('border') != -1) {
| |
- | DD_belatedPNG.applyVML(el);
| |
- | }
| |
- | if (event.propertyName == 'style.display') {
| |
- | display = (el.currentStyle.display == 'none') ? 'none' : 'block';
| |
- | for (v in el.vml) {
| |
- | if (el.vml.hasOwnProperty(v)) {
| |
- | el.vml[v].shape.style.display = display;
| |
- | }
| |
- | }
| |
- | }
| |
- | if (event.propertyName.search('filter') != -1) {
| |
- | DD_belatedPNG.vmlOpacity(el);
| |
- | }
| |
- | },
| |
- | vmlOpacity: function (el) {
| |
- | if (el.currentStyle.filter.search('lpha') != -1) {
| |
- | var trans = el.currentStyle.filter;
| |
- | trans = parseInt(trans.substring(trans.lastIndexOf('=')+1, trans.lastIndexOf(')')), 10)/100;
| |
- | el.vml.color.shape.style.filter = el.currentStyle.filter; /* complete guesswork */
| |
- | el.vml.image.fill.opacity = trans; /* complete guesswork */
| |
- | }
| |
- | },
| |
- | handlePseudoHover: function (el) {
| |
- | setTimeout(function () { /* wouldn't work as intended without setTimeout */
| |
- | DD_belatedPNG.applyVML(el);
| |
- | }, 1);
| |
- | },
| |
- | /**
| |
- | * This is the method to use in a document.
| |
- | * @param {String} selector - REQUIRED - a CSS selector, such as '#doc .container'
| |
- | **/
| |
- | fix: function (selector) {
| |
- | if (this.screenStyleSheet) {
| |
- | var selectors, i;
| |
- | selectors = selector.split(','); /* multiple selectors supported, no need for multiple calls to this anymore */
| |
- | for (i=0; i<selectors.length; i++) {
| |
- | this.screenStyleSheet.addRule(selectors[i], 'behavior:expression(DD_belatedPNG.fixPng(this))'); /* seems to execute the function without adding it to the stylesheet - interesting... */
| |
- | }
| |
- | }
| |
- | },
| |
- | applyVML: function (el) {
| |
- | el.runtimeStyle.cssText = '';
| |
- | this.vmlFill(el);
| |
- | this.vmlOffsets(el);
| |
- | this.vmlOpacity(el);
| |
- | if (el.isImg) {
| |
- | this.copyImageBorders(el);
| |
- | }
| |
- | },
| |
- | attachHandlers: function (el) {
| |
- | var self, handlers, handler, moreForAs, a, h;
| |
- | self = this;
| |
- | handlers = {resize: 'vmlOffsets', move: 'vmlOffsets'};
| |
- | if (el.nodeName == 'A') {
| |
- | moreForAs = {mouseleave: 'handlePseudoHover', mouseenter: 'handlePseudoHover', focus: 'handlePseudoHover', blur: 'handlePseudoHover'};
| |
- | for (a in moreForAs) {
| |
- | if (moreForAs.hasOwnProperty(a)) {
| |
- | handlers[a] = moreForAs[a];
| |
- | }
| |
- | }
| |
- | }
| |
- | for (h in handlers) {
| |
- | if (handlers.hasOwnProperty(h)) {
| |
- | handler = function () {
| |
- | self[handlers[h]](el);
| |
- | };
| |
- | el.attachEvent('on' + h, handler);
| |
- | }
| |
- | }
| |
- | el.attachEvent('onpropertychange', this.readPropertyChange);
| |
- | },
| |
- | giveLayout: function (el) {
| |
- | el.style.zoom = 1;
| |
- | if (el.currentStyle.position == 'static') {
| |
- | el.style.position = 'relative';
| |
- | }
| |
- | },
| |
- | copyImageBorders: function (el) {
| |
- | var styles, s;
| |
- | styles = {'borderStyle':true, 'borderWidth':true, 'borderColor':true};
| |
- | for (s in styles) {
| |
- | if (styles.hasOwnProperty(s)) {
| |
- | el.vml.color.shape.style[s] = el.currentStyle[s];
| |
- | }
| |
- | }
| |
- | },
| |
- | vmlFill: function (el) {
| |
- | if (!el.currentStyle) {
| |
- | return;
| |
- | } else {
| |
- | var elStyle, noImg, lib, v, img, imgLoaded;
| |
- | elStyle = el.currentStyle;
| |
- | }
| |
- | for (v in el.vml) {
| |
- | if (el.vml.hasOwnProperty(v)) {
| |
- | el.vml[v].shape.style.zIndex = elStyle.zIndex;
| |
- | }
| |
- | }
| |
- | el.runtimeStyle.backgroundColor = '';
| |
- | el.runtimeStyle.backgroundImage = '';
| |
- | noImg = true;
| |
- | if (elStyle.backgroundImage != 'none' || el.isImg) {
| |
- | if (!el.isImg) {
| |
- | el.vmlBg = elStyle.backgroundImage;
| |
- | el.vmlBg = el.vmlBg.substr(5, el.vmlBg.lastIndexOf('")')-5);
| |
- | }
| |
- | else {
| |
- | el.vmlBg = el.src;
| |
- | }
| |
- | lib = this;
| |
- | if (!lib.imgSize[el.vmlBg]) { /* determine size of loaded image */
| |
- | img = document.createElement('img');
| |
- | lib.imgSize[el.vmlBg] = img;
| |
- | img.className = lib.ns + '_sizeFinder';
| |
- | img.runtimeStyle.cssText = 'behavior:none; position:absolute; left:-10000px; top:-10000px; border:none; margin:0; padding:0;'; /* make sure to set behavior to none to prevent accidental matching of the helper elements! */
| |
- | imgLoaded = function () {
| |
- | this.width = this.offsetWidth; /* weird cache-busting requirement! */
| |
- | this.height = this.offsetHeight;
| |
- | lib.vmlOffsets(el);
| |
- | };
| |
- | img.attachEvent('onload', imgLoaded);
| |
- | img.src = el.vmlBg;
| |
- | img.removeAttribute('width');
| |
- | img.removeAttribute('height');
| |
- | document.body.insertBefore(img, document.body.firstChild);
| |
- | }
| |
- | el.vml.image.fill.src = el.vmlBg;
| |
- | noImg = false;
| |
- | }
| |
- | el.vml.image.fill.on = !noImg;
| |
- | el.vml.image.fill.color = 'none';
| |
- | el.vml.color.shape.style.backgroundColor = elStyle.backgroundColor;
| |
- | el.runtimeStyle.backgroundImage = 'none';
| |
- | el.runtimeStyle.backgroundColor = 'transparent';
| |
- | },
| |
- | /* IE can't figure out what do when the offsetLeft and the clientLeft add up to 1, and the VML ends up getting fuzzy... so we have to push/enlarge things by 1 pixel and then clip off the excess */
| |
- | vmlOffsets: function (el) {
| |
- | var thisStyle, size, fudge, makeVisible, bg, bgR, dC, altC, b, c, v;
| |
- | thisStyle = el.currentStyle;
| |
- | size = {'W':el.clientWidth+1, 'H':el.clientHeight+1, 'w':this.imgSize[el.vmlBg].width, 'h':this.imgSize[el.vmlBg].height, 'L':el.offsetLeft, 'T':el.offsetTop, 'bLW':el.clientLeft, 'bTW':el.clientTop};
| |
- | fudge = (size.L + size.bLW == 1) ? 1 : 0;
| |
- | /* vml shape, left, top, width, height, origin */
| |
- | makeVisible = function (vml, l, t, w, h, o) {
| |
- | vml.coordsize = w+','+h;
| |
- | vml.coordorigin = o+','+o;
| |
- | vml.path = 'm0,0l'+w+',0l'+w+','+h+'l0,'+h+' xe';
| |
- | vml.style.width = w + 'px';
| |
- | vml.style.height = h + 'px';
| |
- | vml.style.left = l + 'px';
| |
- | vml.style.top = t + 'px';
| |
- | };
| |
- | makeVisible(el.vml.color.shape, (size.L + (el.isImg ? 0 : size.bLW)), (size.T + (el.isImg ? 0 : size.bTW)), (size.W-1), (size.H-1), 0);
| |
- | makeVisible(el.vml.image.shape, (size.L + size.bLW), (size.T + size.bTW), (size.W), (size.H), 1 );
| |
- | bg = {'X':0, 'Y':0};
| |
- | if (el.isImg) {
| |
- | bg.X = parseInt(thisStyle.paddingLeft, 10) + 1;
| |
- | bg.Y = parseInt(thisStyle.paddingTop, 10) + 1;
| |
- | }
| |
- | else {
| |
- | for (b in bg) {
| |
- | if (bg.hasOwnProperty(b)) {
| |
- | this.figurePercentage(bg, size, b, thisStyle['backgroundPosition'+b]);
| |
- | }
| |
- | }
| |
- | }
| |
- | el.vml.image.fill.position = (bg.X/size.W) + ',' + (bg.Y/size.H);
| |
- | bgR = thisStyle.backgroundRepeat;
| |
- | dC = {'T':1, 'R':size.W+fudge, 'B':size.H, 'L':1+fudge}; /* these are defaults for repeat of any kind */
| |
- | altC = { 'X': {'b1': 'L', 'b2': 'R', 'd': 'W'}, 'Y': {'b1': 'T', 'b2': 'B', 'd': 'H'} };
| |
- | if (bgR != 'repeat' || el.isImg) {
| |
- | c = {'T':(bg.Y), 'R':(bg.X+size.w), 'B':(bg.Y+size.h), 'L':(bg.X)}; /* these are defaults for no-repeat - clips down to the image location */
| |
- | if (bgR.search('repeat-') != -1) { /* now let's revert to dC for repeat-x or repeat-y */
| |
- | v = bgR.split('repeat-')[1].toUpperCase();
| |
- | c[altC[v].b1] = 1;
| |
- | c[altC[v].b2] = size[altC[v].d];
| |
- | }
| |
- | if (c.B > size.H) {
| |
- | c.B = size.H;
| |
- | }
| |
- | el.vml.image.shape.style.clip = 'rect('+c.T+'px '+(c.R+fudge)+'px '+c.B+'px '+(c.L+fudge)+'px)';
| |
- | }
| |
- | else {
| |
- | el.vml.image.shape.style.clip = 'rect('+dC.T+'px '+dC.R+'px '+dC.B+'px '+dC.L+'px)';
| |
- | }
| |
- | },
| |
- | figurePercentage: function (bg, size, axis, position) {
| |
- | var horizontal, fraction;
| |
- | fraction = true;
| |
- | horizontal = (axis == 'X');
| |
- | switch(position) {
| |
- | case 'left':
| |
- | case 'top':
| |
- | bg[axis] = 0;
| |
- | break;
| |
- | case 'center':
| |
- | bg[axis] = 0.5;
| |
- | break;
| |
- | case 'right':
| |
- | case 'bottom':
| |
- | bg[axis] = 1;
| |
- | break;
| |
- | default:
| |
- | if (position.search('%') != -1) {
| |
- | bg[axis] = parseInt(position, 10) / 100;
| |
- | }
| |
- | else {
| |
- | fraction = false;
| |
- | }
| |
- | }
| |
- | bg[axis] = Math.ceil( fraction ? ( (size[horizontal?'W': 'H'] * bg[axis]) - (size[horizontal?'w': 'h'] * bg[axis]) ) : parseInt(position, 10) );
| |
- | if (bg[axis] % 2 === 0) {
| |
- | bg[axis]++;
| |
- | }
| |
- | return bg[axis];
| |
- | },
| |
- | fixPng: function (el) {
| |
- | el.style.behavior = 'none';
| |
- | var lib, els, nodeStr, v, e;
| |
- | if (el.nodeName == 'BODY' || el.nodeName == 'TD' || el.nodeName == 'TR') { /* elements not supported yet */
| |
- | return;
| |
- | }
| |
- | el.isImg = false;
| |
- | if (el.nodeName == 'IMG') {
| |
- | if(el.src.toLowerCase().search(/\.png$/) != -1) {
| |
- | el.isImg = true;
| |
- | el.style.visibility = 'hidden';
| |
- | }
| |
- | else {
| |
- | return;
| |
- | }
| |
- | }
| |
- | else if (el.currentStyle.backgroundImage.toLowerCase().search('.png') == -1) {
| |
- | return;
| |
- | }
| |
- | lib = DD_belatedPNG;
| |
- | el.vml = {color: {}, image: {}};
| |
- | els = {shape: {}, fill: {}};
| |
- | for (v in el.vml) {
| |
- | if (el.vml.hasOwnProperty(v)) {
| |
- | for (e in els) {
| |
- | if (els.hasOwnProperty(e)) {
| |
- | nodeStr = lib.ns + ':' + e;
| |
- | el.vml[v][e] = document.createElement(nodeStr);
| |
- | }
| |
- | }
| |
- | el.vml[v].shape.stroked = false;
| |
- | el.vml[v].shape.appendChild(el.vml[v].fill);
| |
- | el.parentNode.insertBefore(el.vml[v].shape, el);
| |
- | }
| |
- | }
| |
- | el.vml.image.shape.fillcolor = 'none'; /* Don't show blank white shapeangle when waiting for image to load. */
| |
- | el.vml.image.fill.type = 'tile'; /* Makes image show up. */
| |
- | el.vml.color.fill.on = false; /* Actually going to apply vml element's style.backgroundColor, so hide the whiteness. */
| |
- | lib.attachHandlers(el);
| |
- | lib.giveLayout(el);
| |
- | lib.giveLayout(el.offsetParent);
| |
- | el.vmlInitiated = true;
| |
- | lib.applyVML(el); /* Render! */
| |
- | }
| |
- | };
| |
- | try {
| |
- | document.execCommand("BackgroundImageCache", false, true); /* TredoSoft Multiple IE doesn't like this, so try{} it */
| |
- | } catch(r) {}
| |
- | DD_belatedPNG.createVmlNameSpace();
| |
- | DD_belatedPNG.createVmlStyleSheet();
| |
- |
| |
- | </script>
| |
- |
| |
- | <script type="text/javascript">
| |
- | DD_belatedPNG.fix('.h80');
| |
- | </script>
| |
- | <![endif]-->
| |
- | <!--[if IE]>
| |
- | <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js">
| |
- | </script>
| |
- | <![endif]-->
| |
- | <script type="text/javascript">
| |
- | function featuredcontentslider_init(a){featuredcontentslider.init(a)}var featuredcontentslider={settingcaches:{},init:function(a){if(this.$(a.id)==null)return;this.settingcaches[a.id]=a;a.contentdivs=[];a.toclinks=[];a.topzindex=0;a.currentpage=a.playtab||1;a.prevpage=a.currentpage;a.etype="on"+(a.revealtype||"click");a.curopacity=0;this.buildpaginate(a)},buildpaginate:function(b){this.buildcontentdivs(b);var e=this.$(b.id),f=this.$("paginate-"+b.id),j="",i=b.toc,d=b.nextprev;if(typeof i=="string"&&i!="markup"&&i!="scroll"||typeof i=="object"){for(var c=1;c<=b.contentdivs.length;c++){j+='<i class="iToc iToc'+c+'"><a href="#'+c+'" class="toc">'+(typeof i=="string"?i.replace(/#increment/,c):i[c-1])+'</a></i> '}j=(d[0]!=''?'<i class="iToc iToc'+c+'"><a href="#prev" class="prev">'+d[0]+'</a></i> ':'')+j+(d[1]!=''?'<i class="iToc iToc'+c+'"><a href="#next" class="next">'+d[1]+'</a></i>':'');f.innerHTML='<i class="subLineTab"></i><span class="subPageTab">'+j+'</span>'}var h=[],m=f.getElementsByTagName("*");for(var c=0;c<m.length;c++){if(m[c].nodeType==1)h.push(m[c])}var k=0,n=this;for(var c=0;c<h.length;c++){if(this.css(h[c],"toc","check")){if(k>b.contentdivs.length-1){h[c].style.display="none";continue}if(i=="scroll"){if(!k){var o=f.getElementsByTagName("div");this.masker=o[0];this.maskee=o[1];this.thumbWidth=[0]}var l=this.thumbWidth,g=h[c];g.style.styleFloat=g.style.cssFloat="left";l.push(l[l.length-1]+g.offsetWidth+this.style(g,"marginLeft",true)+this.style(g,"marginRight",true)+this.style(g,"borderLeftWidth",true)+this.style(g,"borderRightWidth",true))}h[c].setAttribute("rel",++k);h[c][b.etype]=function(){var a=this.getAttribute("rel");if(n.delayTimer)window.clearTimeout(n.delayTimer);n.delayTimer=window.setTimeout(function(){featuredcontentslider.turnpage(b,a)},b.delay);return false};b.toclinks.push(h[c])}else if(this.css(h[c],"prev","check")||this.css(h[c],"next","check")){h[c].onclick=function(){featuredcontentslider.turnpage(b,this.className);return false}}}this.turnpage(b,b.currentpage,true);if(b.autorotate[0]){f[b.etype]=function(){return false};e["onmouseover"]=f["onmouseover"]=function(){featuredcontentslider.cleartimer(b,window["fcsautorun"+b.id]);return true};e["onmouseout"]=f["onmouseout"]=function(){featuredcontentslider.autorotate(b);return true};b.autorotate[1]=b.autorotate[1]+(1/b.enablefade[1]*80);this.autorotate(b)}},buildcontentdivs:function(a){var b=this.$(a.id).getElementsByTagName("div");for(var e=0;e<b.length;e++){if(this.css(b[e],"contentdiv","check")){a.contentdivs.push(b[e]);b[e].style.display="none";b[e].style.overflow="hidden"}}},jumpTo:function(a,b){this.turnpage(this.settingcaches[a],b)},turnpage:function(a,b,e){var f=a.currentpage,j=a.contentdivs,i=j.length,d=(/prev/i.test(b))?f-1:(/next/i.test(b))?f+1:b|0;d=(d<1)?i:(d>i)?1:d;if(d==a.currentpage&&typeof e=="undefined")return;a.currentpage=d;j[a.prevpage-1].style.display="none";j[d-1].style.zIndex=++a.topzindex;this.cleartimer(a,window["fcsfade"+a.id]);a.cacheprevpage=a.prevpage;if(a.enablefade[0]){a.curopacity=0;this.fadeup(a)}j[d-1].style.visibility="visible";j[d-1].style.display="block";if(a.prevpage<=a.toclinks.length)this.css(a.toclinks[a.prevpage-1],"selected","remove");if(d<=a.toclinks.length)this.css(a.toclinks[d-1],"selected","add");a.prevpage=d;if(a.toc=="scroll"){var c=this,h=0.25,m=20,k=c.masker.clientWidth,n=a.contentdivs.length,o=a.toclinks[d-1],l=this.thumbWidth[this.thumbWidth.length-1],d=k/2-o.offsetWidth/2-this.thumbWidth[d-1],g=c.maskee.currentStyle?c.maskee.currentStyle["marginLeft"]:window.getComputedStyle(c.maskee,"").getPropertyValue("margin-left");g=g.substr(0,g.length-2)|0;d=d<=k-l?k-l:d;d=d>0?0:d;function p(){g+=(d-g)*h;if(Math.round(d-g)==0){window.clearInterval(c.thumbTimer);return}c.maskee.style.marginLeft=Math.ceil(g)+"px"}if(c.thumbTimer)window.clearInterval(c.thumbTimer);c.thumbTimer=window.setInterval(p,m)}},setopacity:function(a,b){var e=a.contentdivs[a.currentpage-1];e.className="contentdiv sliderfilter";e.style.cssText+=";filter:alpha(opacity="+b*100+");-moz-opacity:"+b+";opacity:"+b;a.curopacity=b},fadeup:function(a){if(a.curopacity<=0.95){this.setopacity(a,a.curopacity+a.enablefade[1]);window["fcsfade"+a.id]=setTimeout(function(){featuredcontentslider.fadeup(a)},25)}else{this.setopacity(a,1);var b=a.contentdivs[a.currentpage-1];b.className="contentdiv";if(a.cacheprevpage!=a.currentpage)a.contentdivs[a.cacheprevpage-1].style.display="none"}},cleartimer:function(a,b){if(b){clearTimeout(b);clearInterval(b);if(a.cacheprevpage!=a.currentpage){a.contentdivs[a.cacheprevpage-1].style.display="none"}}},css:function(a,b,e){var f=new RegExp("(^|\\s+)"+b+"($|\\s+)","ig");if(e=="check")return f.test(a.className);else if(e=="remove")a.className=a.className.replace(f,"");else if(e=="add")a.className+=" "+b},style:function(a,b,e){var f;if(a.currentStyle){f=a.currentStyle[b]}else if(window.getComputedStyle){b=b.replace(/([A-Z])/g,"-$1");b=b.toLowerCase();f=window.getComputedStyle(a,"").getPropertyValue(b)}return!e?f:f.substr(0,f.length-2)|0},autorotate:function(a){window["fcsautorun"+a.id]=setInterval(function(){featuredcontentslider.turnpage(a,"next")},a.autorotate[1])},$:function(a){return document.getElementById(a)}}
| |
- | </script>
| |
- |
| |
- | <style type="text/css">
| |
- | body{ padding:0; margin:0; background:url(/wiki/images/e/e9/57_1958.jpg);}
| |
- | #nd-header{ width:1000px; height:37px; background:url(https://static.igem.org/mediawiki/2012/b/be/Headerbg.jpg) repeat-x left top;overflow:hidden}
| |
- | #globalWrapper{overflow: hidden;background:url(/wiki/images/e/e9/57_1958.jpg); width:100%}
| |
- | #content {border: none;font-family: georgia, helvetica, arial, sans-serif;width:1000px; background:none; overflow:hidden; margin:0 auto}
| |
- | #siteSub {display:none;}
| |
- | #contentSub {display:none;}
| |
- | #catlinks {border:0px;display:none;}
| |
- | #footer-box{background:#590502;background-image: none;border-style: none;z-index: 0;width:100%;margin:0px;}
| |
- | #footer-box a{color: #e8e7b9;text-decoration: none; display: inline;}
| |
- | #footer-box a:hover{color: #e6c300;text-decoration: none; display: inline;}
| |
- | #footer{ width:1000px; margin:0 auto}
| |
- | #mblink a {text-decoration:none;}
| |
- |
| |
- | #top-section { width:100%;height:21px; line-height:21px; background:url(/wiki/images/c/c3/57_21.jpg) repeat-x;overflow:hidden; border:none; margin:0px;}
| |
- |
| |
- | #p-logo {display:none;}
| |
- | #search-controls {display: none;}
| |
- | #menubar{ }
| |
- | #menubar.left-menu {float:left}
| |
- | #menubar.left-menu ul:hover,#menubar.left-menu:hover{background:none }
| |
- | #menubar.right-menu {float:right }
| |
- | #menubar.right-menu ul:hover,#menubar.right-menu:hover,#menubar.right-menu li a{background:none }
| |
- | #menubar a:active,#menubar a:hover,#menubar a:link,#menubar a:visited {color: #FC0;}
| |
- | .firstHeading {display: none;}
| |
- |
| |
- | /* CSS Document */
| |
- | *{ padding:0; margin:0; font-family:Arial;}
| |
- | ul{ padding:0; margin:0; list-style-type:none;}
| |
- | li{ text-indent:inherit;}
| |
- | a{ text-decoration:none;}
| |
- | a:hover{ text-decoration:none;}
| |
- | img{ border:0;}
| |
- | ul,li{ list-style:none}
| |
- | /* head begin*/
| |
- | .head{width:1000px;margin:0 auto;}
| |
- |
| |
- | .h188{ width:976px; height:188px; margin:0 auto; overflow:hidden}
| |
- | .h45{ width:976px; height:45px; background:url(/wiki/images/8/81/32_45.jpg) repeat-x; margin:0 auto;}
| |
- | .h80{ width:1000px; height:80px; background:url(/wiki/images/c/c8/1000_80.png) no-repeat;}
| |
- | /* head end*/
| |
- | /* footer begin */
| |
- | .h49{width:1000px; height:52px; background:url(/wiki/images/7/72/1000_52.jpg) no-repeat; margin:0 auto;}
| |
- | .w59{width:1000px; height:53px; background:url(/wiki/images/e/ed/1000_53.jpg) repeat-x; margin:0 auto;}
| |
- | .w26{width:100%; height:76px; background:#550303;}
| |
- | .h18{width:100%; height:18px; background:url(/wiki/images/7/70/51_18.jpg) repeat-x;}
| |
- | .h58{width:1000px; height:58px; background:url(/wiki/images/3/35/1000_58.jpg) no-repeat; margin:0 auto;}
| |
- |
| |
- |
| |
- | #navMenu { float:left; width:800px; height:34px; display:block; overflow:hidden; margin-left:100px; margin-top:8px; display:inline}
| |
- | #navMenu li { float:left; height:34px; font-size:15px;}
| |
- | #navMenu li a { display: block; color:#820402; border-right:1px solid #c5bba2; float:left; margin-top:8px; padding-left:21px; padding-right:21px;}
| |
- | #navMenu li.none a{ border-right:none}
| |
- | #navMenu li a:hover, #navMenu li.hover a {color:#FF7B0E;}
| |
- | /*-------- 下拉菜单 --------------*/
| |
- | .dropMenu {position:absolute; top:0; z-index:10;width: 140px;visibility: hidden; margin-top: 5px;margin-left:-12px;_margin-left:-455px; _margin-top:-250px; background:#333;padding-top:6px;padding-bottom:6px;filter: Alpha(Opacity=60); -moz-opacity:0.6; opacity: 0.6; }
| |
- | .dropMenu li { margin-top:2px;margin-bottom:4px; }
| |
- | .dropMenu li a{width: 100%;display: block;text-align:center; color:#FFF; padding-bottom:6px; padding-top:4px; border-bottom: 1px dashed #CCC; font-size:14px;}
| |
- | .dropMenu+li a{border-top:none;}
| |
- | * html .dropMenu a {width: 100%;color:#FFF;}
| |
- | .dropMenu a:hover {color:#F09C42;}
| |
- | .hdo{width:100%;height:auto;display:block;overflow:hidden;}
| |
- |
| |
- | /* footer end */
| |
- |
| |
- | /* content begin*/
| |
- | .con{width:976px; min-height:1500px; height:auto; margin:0 auto; background:url(/wiki/images/8/81/976_727.jpg) repeat-y;}
| |
- | .place{ background:url(/wiki/images/3/31/Palcebg.gif) no-repeat; width:875px; height:60px; margin:0 auto}
| |
- | .place span.p{ float:left; color:#000; font-size:14px; font-weight:bold; text-indent:30px;}
| |
- | .place span.p2{ float:right; color:#666}
| |
- | .place span.p2 a{ font-size:12px; color:#666}
| |
- | .bar{ background:url(/wiki/images/7/78/Aboutbar.gif) no-repeat 0 -35px; width:875px; height:35px; margin:0 auto}
| |
- | .bar a{ float:left; display:block; width:102px; height:27px;}
| |
- | .bar a.link{ margin-left:11px; display:inline}
| |
- | .bar a.link2{ margin-left:4px; display:inline}
| |
- | .bar a.link3{ margin-left:1px; display:inline}
| |
- | .bar a.link4{ margin-left:1px; display:inline}
| |
- |
| |
- | .content{ width:875px; height:auto; margin:0 auto; font-size:14px; color:#000; padding-top:20px; padding-bottom:20px; line-height:22px;}
| |
- |
| |
- | .photoList{ width:682px; margin:0 auto; overflow:hidden}
| |
- | .syFocusThumb {POSITION: relative; width: 662px; text-align:center; height:620px; OVERFLOW: hidden; }
| |
- | .sliderwrapper{ background:#dbcfad; width:660px; border:1px solid #FFF }
| |
- | .syFocusThumb .contentdiv {height:auto; padding:7px}
| |
- | .syFocusThumb IMG {border-BOTTOM-STYLE: none; border-right-STYLE: none; border-TOP-STYLE: none; VERTICAL-ALIGN: top; border-LEFT-STYLE: none}
| |
- | .syFocusThumb .prev {background:url(images/left.gif) no-repeat; POSITION: absolute; width: 20px; height: 95px; top:12px; CURSOR: pointer; LEFT: 0px}
| |
- | .syFocusThumb .next {background:url(images/right.gif) no-repeat; POSITION: absolute; width: 20px; height: 95px;top:12px; CURSOR: pointer;right: 0px; LEFT: auto}
| |
- | .syFocusThumb .pagination I.selected IMG { width:144px; height:95px; border:2px solid #dbcfad}
| |
- | .syFocusThumb .pagination { POSITION: absolute; TEXT-ALIGN: left; width: 100%;height: 150px; COLOR: #fff; CLEAR: both; TOP: 450px; LEFT: 0px; border-bottom:1px solid #d8c7a2}
| |
- | .syFocusThumb .pagination IMG { PADDING-LEFT: 2px; PADDING-right: 2px; PADDING-TOP: 2px; padding-bottom:2px;}
| |
- | .syFocusThumb .thumbWrap {POSITION: absolute; width:611px; OVERFLOW: hidden; TOP: 8px; LEFT: 26px; }
| |
- | .syFocusThumb .holder {width: 4000px}
| |
- | .syFocusThumb .holder I {CURSOR: pointer; MARGIN-right: 4px}
| |
- |
| |
- | .info{ width:682px; margin:0 auto; overflow:hidden; line-height:25px;}
| |
- | .info p{ font-size:29px; font-weight:bold; color:#830909; text-align:center; padding-bottom:20px;}
| |
- |
| |
- | /* content end*/
| |
- | </style>
| |
- | </head>
| |
- | <body>
| |
- |
| |
- |
| |
- | <!--head begin-->
| |
- | <div class="head">
| |
- | <div class="h21"></div>
| |
- | <div class="h188"><img src="images/ABOUT_US.jpg" width="976" height="188" alt="南京IGEM"/></div>
| |
- | <div class="h45"></div>
| |
- | <div class="h80">
| |
- | <div id="navMenu">
| |
- | <li><a href='/Team:Nanjing_China_Bio/index'>HOME</a></li>
| |
- | <li><a href='/Team:Nanjing_China_Bio/team' rel='dropmenu1'>ABOUT US</a></li>
| |
- | <li><a href='/Team:Nanjing_China_Bio/projects' rel='dropmenu2'>PROJECTS</a></li>
| |
- | <li><a href='/Team:Nanjing_China_Bio/results' rel='dropmenu3'>RESULTS</a></li>
| |
- | <li><a href='/Team:Nanjing_China_Bio/notebook'>NOTEBOOK</a></li>
| |
- | <li><a href='/Team:Nanjing_China_Bio/outreach'>OUTREACH</a></li>
| |
- | <li class="none"><a href='/Team:Nanjing_China_Bio/safety'>SAFETY</a></li>
| |
- | </div>
| |
- | <script type="text/javascript">
| |
- | var cssdropdown={
| |
- | disappeardelay: 250,
| |
- | disablemenuclick: false,
| |
- | enableswipe: 1,
| |
- | enableiframeshim: 1,
| |
- | dropmenuobj: null, ie: document.all, firefox: document.getElementById&&!document.all, swipetimer: undefined, bottomclip:0,
| |
- |
| |
- | getposOffset:function(what, offsettype){
| |
- | var totaloffset=(offsettype=="left")? what.offsetLeft : what.offsetTop;
| |
- | var parentEl=what.offsetParent;
| |
- | while (parentEl!=null){
| |
- | totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft : totaloffset+parentEl.offsetTop;
| |
- | parentEl=parentEl.offsetParent;
| |
- | }
| |
- | return totaloffset;
| |
- | },
| |
- |
| |
- | swipeeffect:function(){
| |
- | if (this.bottomclip<parseInt(this.dropmenuobj.offsetHeight)){
| |
- | this.bottomclip+=10+(this.bottomclip/10)
| |
- | this.dropmenuobj.style.clip="rect(0 auto "+this.bottomclip+"px 0)"
| |
- | }
| |
- | else
| |
- | return
| |
- | this.swipetimer=setTimeout("cssdropdown.swipeeffect()", 10)
| |
- | },
| |
- |
| |
- | showhide:function(obj, e){
| |
- | if (this.ie || this.firefox)
| |
- | this.dropmenuobj.style.left=this.dropmenuobj.style.top="-500px"
| |
- | if (e.type=="click" && obj.visibility==hidden || e.type=="mouseover"){
| |
- | if (this.enableswipe==1){
| |
- | if (typeof this.swipetimer!="undefined")
| |
- | clearTimeout(this.swipetimer)
| |
- | obj.clip="rect(0 auto 0 0)"
| |
- | this.bottomclip=0
| |
- | this.swipeeffect()
| |
- | }
| |
- | obj.visibility="visible"
| |
- | }
| |
- | else if (e.type=="click")
| |
- | obj.visibility="hidden"
| |
- | },
| |
- |
| |
- | iecompattest:function(){
| |
- | return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
| |
- | },
| |
- |
| |
- | clearbrowseredge:function(obj, whichedge){
| |
- | var edgeoffset=0
| |
- | if (whichedge=="rightedge"){
| |
- | var windowedge=this.ie && !window.opera? this.iecompattest().scrollLeft+this.iecompattest().clientWidth-15 : window.pageXOffset+window.innerWidth-15
| |
- | this.dropmenuobj.contentmeasure=this.dropmenuobj.offsetWidth
| |
- | if (windowedge-this.dropmenuobj.x < this.dropmenuobj.contentmeasure)
| |
- | edgeoffset=this.dropmenuobj.contentmeasure-obj.offsetWidth
| |
- | }
| |
- | else{
| |
- | var topedge=this.ie && !window.opera? this.iecompattest().scrollTop : window.pageYOffset
| |
- | var windowedge=this.ie && !window.opera? this.iecompattest().scrollTop+this.iecompattest().clientHeight-15 : window.pageYOffset+window.innerHeight-18
| |
- | this.dropmenuobj.contentmeasure=this.dropmenuobj.offsetHeight
| |
- | if (windowedge-this.dropmenuobj.y < this.dropmenuobj.contentmeasure){
| |
- | edgeoffset=this.dropmenuobj.contentmeasure+obj.offsetHeight
| |
- | if ((this.dropmenuobj.y-topedge)<this.dropmenuobj.contentmeasure)
| |
- | edgeoffset=this.dropmenuobj.y+obj.offsetHeight-topedge
| |
- | }
| |
- | }
| |
- | return edgeoffset
| |
- | },
| |
- |
| |
- | dropit:function(obj, e, dropmenuID){
| |
- | if (this.dropmenuobj!=null)
| |
- | this.dropmenuobj.style.visibility="hidden"
| |
- | this.clearhidemenu()
| |
- | if (this.ie||this.firefox){
| |
- | obj.onmouseout=function(){cssdropdown.delayhidemenu()}
| |
- | obj.onclick=function(){return !cssdropdown.disablemenuclick}
| |
- | this.dropmenuobj=document.getElementById(dropmenuID)
| |
- | if(!this.dropmenuobj) return;
| |
- | this.dropmenuobj.onmouseover=function(){cssdropdown.clearhidemenu()}
| |
- | this.dropmenuobj.onmouseout=function(e){cssdropdown.dynamichide(e)}
| |
- | this.dropmenuobj.onclick=function(){cssdropdown.delayhidemenu()}
| |
- | this.showhide(this.dropmenuobj.style, e)
| |
- | this.dropmenuobj.x=this.getposOffset(obj, "left")
| |
- | this.dropmenuobj.y=this.getposOffset(obj, "top")
| |
- | this.dropmenuobj.style.left=this.dropmenuobj.x-this.clearbrowseredge(obj, "rightedge")+"px"
| |
- | this.dropmenuobj.style.top=this.dropmenuobj.y-this.clearbrowseredge(obj, "bottomedge")+obj.offsetHeight+1+"px"
| |
- | this.positionshim()
| |
- | }
| |
- | },
| |
- |
| |
- | positionshim:function(){
| |
- | if (this.enableiframeshim && typeof this.shimobject!="undefined"){
| |
- | if (this.dropmenuobj.style.visibility=="visible"){
| |
- | this.shimobject.style.width=this.dropmenuobj.offsetWidth+"px"
| |
- | this.shimobject.style.height=this.dropmenuobj.offsetHeight+"px"
| |
- | this.shimobject.style.left=this.dropmenuobj.style.left
| |
- | this.shimobject.style.top=this.dropmenuobj.style.top
| |
- | }
| |
- | this.shimobject.style.display=(this.dropmenuobj.style.visibility=="visible")? "block" : "none"
| |
- | }
| |
- | },
| |
- |
| |
- | hideshim:function(){
| |
- | if (this.enableiframeshim && typeof this.shimobject!="undefined")
| |
- | this.shimobject.style.display='none'
| |
- | },
| |
- |
| |
- | contains_firefox:function(a, b) {
| |
- | while (b.parentNode)
| |
- | if ((b = b.parentNode) == a)
| |
- | return true;
| |
- | return false;
| |
- | },
| |
- |
| |
- | dynamichide:function(e){
| |
- | var evtobj=window.event? window.event : e
| |
- | if (this.ie&&!this.dropmenuobj.contains(evtobj.toElement))
| |
- | this.delayhidemenu()
| |
- | else if (this.firefox&&e.currentTarget!= evtobj.relatedTarget&& !this.contains_firefox(evtobj.currentTarget, evtobj.relatedTarget))
| |
- | this.delayhidemenu()
| |
- | },
| |
- |
| |
- | delayhidemenu:function(){
| |
- | this.delayhide=setTimeout("cssdropdown.dropmenuobj.style.visibility='hidden'; cssdropdown.hideshim()",this.disappeardelay)
| |
- | },
| |
- |
| |
- | clearhidemenu:function(){
| |
- | if (this.delayhide!="undefined")
| |
- | clearTimeout(this.delayhide)
| |
- | },
| |
- |
| |
- | startchrome:function(){
| |
- | for (var ids=0; ids<arguments.length; ids++){
| |
- | var menuitems=document.getElementById(arguments[ids]).getElementsByTagName("a")
| |
- | for (var i=0; i<menuitems.length; i++){
| |
- | if (menuitems[i].getAttribute("rel")){
| |
- | var relvalue=menuitems[i].getAttribute("rel")
| |
- | menuitems[i].onmouseover=function(e){
| |
- | var event=typeof e!="undefined"? e : window.event
| |
- | cssdropdown.dropit(this,event,this.getAttribute("rel"))
| |
- | }
| |
- | }
| |
- | }
| |
- | }
| |
- | if (window.createPopup && !window.XmlHttpRequest){
| |
- | document.write('<IFRAME id="iframeshim" src="" style="display: none; left: 0; top: 0; z-index: 90; position: absolute; filter: progid:DXImageTransform.Microsoft.Alpha(style=0,opacity=0)" frameBorder="0" scrolling="no"></IFRAME>')
| |
- | this.shimobject=document.getElementById("iframeshim")
| |
- | }
| |
- | }
| |
- |
| |
- | }
| |
- | </script>
| |
- | <ul id="dropmenu1" class="dropMenu">
| |
- | <li><a href="/Team:Nanjing_China_Bio/team">TEAM</a></li>
| |
- | <li><a href="/Team:Nanjing_China_Bio/member">MEMBER</a></li>
| |
- | <li><a href="/Team:Nanjing_China_Bio/university">UNIVERSITY</a></li>
| |
- | <li><a href="/Team:Nanjing_China_Bio/sponsors">SPONSORS</a></li>
| |
- | </ul>
| |
- | <ul id="dropmenu2" class="dropMenu">
| |
- | <li><a href="/Team:Nanjing_China_Bio/background">BACKGROUND</a></li>
| |
- | <li><a href="/Team:Nanjing_China_Bio/methods">METHODS</a></li>
| |
- | </ul>
| |
- | <ul id="dropmenu3" class="dropMenu">
| |
- | <li><a href="/Team:Nanjing_China_Bio/parts">Parts Submitted</a></li>
| |
- | <li><a href="/Team:Nanjing_China_Bio/future">Future Direction</a></li>
| |
- | </ul>
| |
- | <script type="text/javascript">cssdropdown.startchrome("navMenu")</script>
| |
- | <!--//nav-->
| |
- | </div>
| |
- | </div>
| |
- | <!--head end-->
| |
- |
| |
- | <!--content begin-->
| |
- | <div class="con">
| |
- | <div class="place"><span class="p">ABOUT US</span><span class="p2"><a href="">Home</a> > <a href="">About</a> > <a href="">Team</a></span></div>
| |
- | <div class="bar">
| |
- | <a href="team.html" class="link"></a>
| |
- | <a href="member.html" class="link2"></a>
| |
- | <a href="university.html" class="link3"></a>
| |
- | <a href="sponsors.html" class="link4"></a>
| |
- | </div>
| |
- | <div class="content">
| |
- | <!--图片展示-->
| |
- | <div class="photoList">
| |
- | <DIV class=syFocusThumb>
| |
- | <DIV id=syFocusThumb class=sliderwrapper>
| |
- | <DIV class=contentdiv><DIV class=dPic><A href="images/IMG_4049_2.jpg" target=_blank><img src="images/IMG_4049_2.jpg" width="640" height="427" /></A></DIV></DIV>
| |
- | <DIV class=contentdiv><DIV class=dPic><A href="images/IMG_4063.jpg" target=_blank><img src="images/IMG_4063.jpg" width="640" height="427" /></A></DIV></DIV>
| |
- | <DIV class=contentdiv><DIV class=dPic><A href="images/IMG_4064.jpg" target=_blank><img src="images/IMG_4064.jpg" width="640" height="427" /></A></DIV></DIV>
| |
- | <DIV class=contentdiv><DIV class=dPic><A href="images/IMG_4066_2.jpg" target=_blank><img src="images/IMG_4066_2.jpg" width="640" height="427" /></A></DIV></DIV>
| |
- | <DIV class=contentdiv><DIV class=dPic><A href="images/IMG_4069.jpg" target=_blank><img src="images/IMG_4069.jpg" width="640" height="427" /></A></DIV></DIV>
| |
- |
| |
- | </DIV>
| |
- | <DIV id=paginate-syFocusThumb class=pagination>
| |
- | <I id=prev class=prev title=上一幅></I>
| |
- | <DIV class=thumbWrap>
| |
- | <DIV class=holder>
| |
- | <I class=toc><A href="images/IMG_4049_2.jpg" target=_blank><img src="images/IMG_4049_2.jpg" width="144" height="95" /></A></I>
| |
- | <I class=toc><A href="images/IMG_4063.jpg" target=_blank><img src="images/IMG_4063.jpg" width="144" height="95" /></A></I>
| |
- | <I class=toc><A href="images/IMG_4064.jpg" target=_blank><img src="images/IMG_4064.jpg" width="144" height="95" /></A></I>
| |
- | <I class=toc><A href="images/IMG_4066_2.jpg" target=_blank><img src="images/IMG_4066_2.jpg" width="144" height="95" /></A></I>
| |
- | <I class=toc><A href="images/IMG_4069.jpg" target=_blank><img src="images/IMG_4069.jpg" width="144" height="95" /></A></I>
| |
- | </DIV>
| |
- | </DIV>
| |
- | <I id=next class=next title=下一幅></I>
| |
- | </DIV>
| |
- | <SCRIPT type=text/javascript>
| |
- | //焦点图初始化
| |
- | featuredcontentslider.init({
| |
- | id: "syFocusThumb", //指定ID
| |
- | contentsource: ["inline", ""], //有效值: ["inline", ""] 嵌入html or ["ajax", "path_to_file"] 嵌入utf-8文件
| |
- | toc: "scroll", //有效值: "#increment" 标记序号, "markup", ["markup1", "markup2", etc]标记具体内容
| |
- | nextprev: ["", ""], //next_pre标记 ,如:"上一条" "下一条",设置为 "" 为不出现
| |
- | revealtype: "click", //鼠标事件有效值: "click" or "mouseover"
| |
- | enablefade: [false, 0.15], // 切换褪色度 "true"or "false"
| |
- | autorotate: [true,10000], // 切换停留时间 "true"or "false"
| |
- | delay: 0, //事件延迟时间(默认值:0,单位:ms)
| |
- | //playtab: 4, 默认的播放舌签
| |
- | onChange: function(previndex, curindex){ //触发处理;previndex 触发处理上一个记录; curindex 触发处理上一个记录 可以自定义函数控制;参考亲子网首页"亲子部落-相册"
| |
- | }
| |
- | });
| |
- | </SCRIPT>
| |
- | </DIV>
| |
- | </div>
| |
- | <!--//图片展示-->
| |
- |
| |
- | <div class="info">
| |
- | <p>Our Team </p>
| |
- | Our team consists of senior and junior students from departments of Life Science, Computer Science and Journalism and Communication. We come together and work together for one common goal. Though there were difficulties and obstacles during the process, we didn't give up and gave all our efforts. Thanks to iGEM for giving us a chance for us to meet each other and work together and we will do our best.
| |
- | </div>
| |
- | </div>
| |
- |
| |
- | </div>
| |
- | <!--content end-->
| |
- |
| |
- |
| |
- | <!--footer begin-->
| |
- | <div class="h49"></div>
| |
- | <div class="w59"></div>
| |
- | <div class="w26">
| |
- | <div class="h18"></div>
| |
- | <div class="h58"></div>
| |
- | </div>
| |
- | <!--footer end-->
| |
- | </body>
| |
- | </html>
| |