diff --git a/index.html b/index.html index da97595..f964fd0 100644 --- a/index.html +++ b/index.html @@ -22,8 +22,8 @@
- - + +
CAT CAST diff --git a/index.js b/index.js index 3fdd44f..ad60762 100644 --- a/index.js +++ b/index.js @@ -15,25 +15,30 @@ function OnLoadDefault(){ function OnLoadIndex(){ OnLoadDefault(); - var numImg=0; - var visibleImg=0; + var numImg=3; + var visibleImg=1; setInterval(function(){ - document.getElementById("backgroundImage"+visibleImg).className="own-indexBackgroundImage"; + console.log(numImg); + console.log("visibleImg: " + visibleImg); + + + document.getElementById("backgroundImage"+visibleImg).className+=" own-opacity0"; + document.getElementById("backgroundImage"+visibleImg).src="imatges/background/background"+numImg+".jpg"; if(visibleImg==0){ visibleImg=1; }else{ visibleImg=0; } - document.getElementById("backgroundImage"+visibleImg).className+=" own-opacity0"; - document.getElementById("backgroundImage"+visibleImg).src="imatges/background/background"+numImg+".jpg"; + + document.getElementById("backgroundImage"+visibleImg).className="own-indexBackgroundImage"; numImg++; if(numImg>9) { numImg=0; } - }, 5000); + }, 4000); } function OnLoadNosaltres(){ OnLoadDefault(); diff --git a/own.css b/own.css index abdadd8..b729da2 100644 --- a/own.css +++ b/own.css @@ -94,10 +94,10 @@ body { left: 0px; top: 0px; - -webkit-transition: opacity 1s ease-in-out; - -moz-transition: opacity 1s ease-in-out; - -o-transition: opacity 1s ease-in-out; - transition: opacity 1s ease-in-out; + /*-webkit-transition: opacity 0.5s ease-in-out; + -moz-transition: opacity 0.5s ease-in-out; + -o-transition: opacity 0.5s ease-in-out; + transition: opacity 0.5s ease-in-out;*/ } } @@ -110,13 +110,13 @@ body { left: 0px; top: 0px; - -webkit-transition: opacity 1s ease-in-out; - -moz-transition: opacity 1s ease-in-out; - -o-transition: opacity 1s ease-in-out; - transition: opacity 1s ease-in-out; + /*-webkit-transition: opacity 0.5s ease-in-out; + -moz-transition: opacity 0.5s ease-in-out; + -o-transition: opacity 0.5s ease-in-out; + transition: opacity 0.5s ease-in-out;*/ } } -.own-opactity0{ +.own-opacity0{ opacity: 0; } .own-langIndex{