Our Smartphone Network: BlackBerryWindows MobileAndroidPalm Pre
iPhone Forums
EverythingiCafe iPhone cases, accessories iPhone Social iPhone Wallpapers iPhone forums iPhone blog iPhone accessory reviews iPhone news

Go Back   iPhone Forums > Modifications > iPhone Modifications




Reply
 
LinkBack Thread Tools Display Modes
Old 11-08-2009, 07:33 PM   #1 (permalink)
 
Join Date: Nov 2009
Posts: 14
Thanks: 0
Thanked 0 Times in 0 Posts
Exclamation Adding 2nd background

right now im using this script as 'Wallpaper.html'

<?xml version="1.0" encoding="UTF-16"?>
<html><head>
<base href="Private/"/>
<!--meta name="viewport" content="width=320, minimum-scale=1.0, maximum-scale=1.0"/-->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>

<style>
body {
background-color: black;
margin: 0;
padding: 20px 0 0 0;
height: 442px;
width: 320px;
}

img {
-webkit-transition-property: opacity;
-webkit-transition-duration: 2s;
position: absolute;
width: 320px;
height: auto;
}

img.fade-out {
opacity: 0;
}

img.fade-in {
opacity: 1;
}
</style>
</head><body style="color: black">
<img id="one"/>
<img id="two"/>
<script>
var images = ['BG1.png', 'BG2.png'];
var index = 0;

var fade_in = one;
var fade_out = two;

fade_in.src = images[0];
fade_out.src = images[images.length - 1];

var fade = function () {
fade_in.src = images[index];
index = (index + 1) % images.length;

fade_in.className = 'fade-out';
fade_out.className = 'fade-in';

var fade_tmp = fade_in;
fade_in = fade_out;
fade_out = fade_tmp;

setTimeout(fade, 5000);
};

fade();
</script>
</body></html>
it makes my background fade in and out, but the middle part of the image i do not want to fade. i would like to have a second background which would rest on top or behind (either way is fine because the section i want to not fade is transparent.)

let me know if you need pictures to understand. thanks!!
cnotethegr8 is offline  
Digg this Post!Share on Facebook!
Reply With Quote
Old 11-08-2009, 09:00 PM   #2 (permalink)
 
mr.reggaeton72's Avatar
 
Join Date: Jun 2009
Posts: 476
Thanks: 0
Thanked 7 Times in 5 Posts
Default

yes, i need pics to understand, please...
__________________
random articulations of codes inward of iphone OS, coadjute to contrive unpremeditated behavior
mr.reggaeton72 is offline  
Digg this Post!Share on Facebook!
Reply With Quote
Old 11-08-2009, 09:52 PM   #3 (permalink)
 
Join Date: Nov 2009
Posts: 14
Thanks: 0
Thanked 0 Times in 0 Posts
Default

i figured it out, thanks
cnotethegr8 is offline  
Digg this Post!Share on Facebook!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



All times are GMT -5. The time now is 12:56 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0
Integrated by BBpixel