Friendster Delight



If you want to access fully in FD. Please do log in or register. Thank You. Welcome. FD

Friendster Delight


 
Home:: Portal ::FAQMemberlistSearchUsergroupsRegisterLog in

Share | 
 

 Gradual Fader W/ready to paste (UPDATED)

View previous topic View next topic Go down 
AuthorMessage
provanz
Full Moderator
Full Moderator
avatar

Posts : 2671

Age : 27


View user profile http://fddelete.forumotion.net
PostSubject: Gradual Fader W/ready to paste (UPDATED)   Sun May 03, 2009 6:41 pm

Compile to JS

Live Preview
Code:

/***********************************************
* Gradual Element Fader- (c) Dynamic Drive DHTML code library (www.dynamicdrive.com)
* Visit http://www.dynamicDrive.com for hundreds of DHTML scripts
* This notice must stay intact for legal use
***********************************************/

var gradualFader={}
gradualFader.baseopacity=0.10
gradualFader.increment=0.2
document.write('\n')
document.write('.commonbox{filter:progid:DXImageTransform.Microsoft.alpha(opacity='
+gradualFader.baseopacity*100+'); -moz-opacity:'+gradualFader.baseopacity+'; opacity:'+gradualFader.baseopacity+';}\n')
document.write('')
gradualFader.setopacity=function(obj, value){
var targetobject=obj
if (targetobject && targetobject.filters && targetobject.filters[0]){
if (typeof targetobject.filters[0].opacity=="number")
targetobject.filters[0].opacity=value*100
else
targetobject.style.filter="alpha(opacity="+value*100+")"
}
else if (targetobject && typeof targetobject.style.MozOpacity!="undefined")
targetobject.style.MozOpacity=value
else if (targetobject && typeof targetobject.style.opacity!="undefined")
targetobject.style.opacity=value
targetobject.currentopacity=value
}
gradualFader.fadeupdown=function(obj, direction){
var targetobject=obj
var fadeamount=(direction=="fadeup")? this.increment : -this.increment
if (targetobject && (direction=="fadeup" && targetobject.currentopacity<1 || direction=="fadedown" && targetobject.currentopacity>this.baseopacity)){
this.setopacity(obj, targetobject.currentopacity+fadeamount)
window["opacityfader"+obj._fadeorder]=setTimeout(function(){gradualFader.fadeupdown(obj, direction)}, 50)
}
}
gradualFader.clearTimer=function(obj){
if (typeof window["opacityfader"+obj._fadeorder]!="undefined")
clearTimeout(window["opacityfader"+obj._fadeorder])
}
gradualFader.isContained=function(m, e){
var e=window.event || e
var c=e.relatedTarget || ((e.type=="mouseover")? e.fromElement : e.toElement)
while (c && c!=m)try {c=c.parentNode} catch(e){c=m}
if (c==m)
return true
else
return false
}
gradualFader.fadeinterface=function(obj, e, direction){
if (!this.isContained(obj, e)){
gradualFader.clearTimer(obj)
gradualFader.fadeupdown(obj, direction)
}
}
gradualFader.collectElementbyClass=function(classname){
var classnameRE=new RegExp("(^|\\s+)"+classname+"($|\\s+)", "i")
var pieces=[]
var alltags=document.all? document.all : document.getElementsByTagName("*")
for (var i=0; i
if (typeof alltags[i].className=="string" && alltags[i].className.search(classnameRE)!=-1)
pieces[pieces.length]=alltags[i]
}
return pieces
}
gradualFader.init=function(){
var targetobjects=this.collectElementbyClass("commonbox")
for (var i=0; i
targetobjects[i]._fadeorder=i
this.setopacity(targetobjects[i], this.baseopacity)
targetobjects[i].onmouseover=function(e){gradualFader.fadeinterface(this, e, "fadeup")}
targetobjects[i].onmouseout=function(e){gradualFader.fadeinterface(this, e, "fadedown")}
}
}
gradualFader.init()


Ready to paste here

Code:
<script src="http://singlevanz.fileave.com/GradualFader.js"></script>



Credits:HCG


Last edited by provanz on Wed May 27, 2009 10:41 am; edited 3 times in total
Back to top Go down
--hayca--
Full Moderator
Full Moderator
avatar

Posts : 2125

Age : 24


View user profile http://www.friendster.com/tinytinytinytinytiny
PostSubject: Re: Gradual Fader W/ready to paste (UPDATED)   Fri May 22, 2009 6:59 pm

so this is the one you've been telling nah inedit ? only those who have the power to edit can do that . by the way thanks fer sharing .

_________________




* PHiLiPPiNES' PRiDE *
Back to top Go down
provanz
Full Moderator
Full Moderator
avatar

Posts : 2671

Age : 27


View user profile http://fddelete.forumotion.net
PostSubject: Re: Gradual Fader W/ready to paste (UPDATED)   Fri May 22, 2009 7:25 pm

yeah this topic na nga Smile)




BTW

your welcome Smile)

_________________





http://pinoy-vanz.tk
Back to top Go down
lheendc
Co-Admin
Co-Admin
avatar

Posts : 973

Age : 22


View user profile http://www.plurk.com/lheendc/invite
PostSubject: Re: Gradual Fader W/ready to paste (UPDATED)   Sat May 23, 2009 12:25 am

Thanks for this.
I`m just quite confused of your title, change it to English.
I didn`t edit your topic, by the way.
Back to top Go down
mz.manicka21
Full Moderator
Full Moderator
avatar

Posts : 1276

Age : 23


View user profile http://profiles.friendster.com/riekosugita
PostSubject: Re: Gradual Fader W/ready to paste (UPDATED)   Tue May 26, 2009 10:26 pm

provanz wrote:
Ready to paste here
Code:



^huh?
where's the ready to paste code?


BTW,thanks for this.
i will use it. XD

_________________
ILYSM. Guest





Spoiler:
 
Back to top Go down
cjay_13rdths
Second Timer
Second Timer
avatar

Posts : 38


View user profile http://us.mg3.mail.yahoo.com/dc/launch
PostSubject: Re: Gradual Fader W/ready to paste (UPDATED)   Sun May 31, 2009 10:34 pm

tnx for sharing^^
Back to top Go down
joshjammark
Promoter
Promoter
avatar

Posts : 120


View user profile http://www.friendster.com/joshjammark
PostSubject: Re: Gradual Fader W/ready to paste (UPDATED)   Thu Jun 11, 2009 8:15 pm

cool
thanks!


Spoiler:
 
Back to top Go down
vhegaricious
Guest
Guest
avatar

Posts : 7

Age : 26


View user profile http://omgcodes.omgforum.net
PostSubject: Re: Gradual Fader W/ready to paste (UPDATED)   Sun Jun 14, 2009 6:50 pm

sir you forgot the onload handler
hahahah
if you are using the codes like that
Promise it won't work
i'm using like this
Code:

function fader()
{
gradualFader.init()
}
window.onload=fader;
Back to top Go down
sEz™
Third Timer
Third Timer
avatar

Posts : 57

Age : 23


View user profile http://profiles.friendster.com/figmentofyourimagination
PostSubject: Re: Gradual Fader W/ready to paste (UPDATED)   Wed Jun 17, 2009 10:37 pm

EiNKSZ FOR SHARiNG ... Smile Smile Smile
Back to top Go down
Sponsored content




PostSubject: Re: Gradual Fader W/ready to paste (UPDATED)   

Back to top Go down
 

Gradual Fader W/ready to paste (UPDATED)

View previous topic View next topic Back to top 
Page 1 of 1

Permissions in this forum:You cannot reply to topics in this forum
Friendster Delight :: FD Tips & Tricks :: Java Script Codes-