Pages: 11234567891011..11

  2007-06-10 00:50:39

craindepth
» n00b
FTalk Level: zero
20
0
1969-12-31

Re: this is the simplest code for users to understand>>>>> :idea: js code, js extension and js script are all the same, dont be confious.. ^^ css code and css extension are all the same too.. url mea

[quote]hello friends, wanna share dis 2 u all..hehe i discover how to put dis script in our fs.. dont ever rip my code..it will just make you difficulty just ask me and ill give it.. n sori if i reply late sumtyms this site is cannot be diplayed eh see it in action www.friendster.com/june211989 its an welcome alert box...that u can design/resize on what way you like... u can put images/messges inside..u can declare if u wnt 2 stay it in (x) seconds even without pressing the close button... 1st-put this in ur CSS code, u can change the style Code: #fadeinbox { position:absolute; width: 210px; border: 1px solid #000000; background-color: #bbddff; padding: 4px; visibility:hidden; font-family : Tahoma, Verdana; font-size : 11px; font-weight : normal; color : Midnight Blue; } 2nd-put this function in your JS script, //whahahahahaha function maine() { var tame = window.parent.document.getElementById('reviews_1_4').innerHTML; var mhen = "<DIV id='fadeinbox'><br /><div align='right'><a href='#' onClick='hidefadebox();return false'><img src='x.gif' border='0' width='15' height='15'></a><br /></div><br><br /><div align='justify'><div align='center'>CONTENTS</div></div><br><br /></DIV>"; window.parent.document.getElementById('reviews_1_4').innerHTML = mhen; } document.write('<body onload="maine()">') ; //i use reviews_1_4 so i can also hide it.. but u can also use other div id, ex: blogs_1_3, groups_2_5, etc //x.gif is the close button host it in ur OWN hosting site ex: http://photobucket.com //u can create ur own x.gif just create it in 15x15 size //CONTENT <----- edit this to the images and messages u like last-put this script in your JS code /*********************************************** * Sticky Note script- © Dynamic Drive DHTML code library (www.dynamicdrive.com) * Go to http://www.dynamicdrive.com/ for full source code ***********************************************/ var displaymode="always" //(always or oncepersession) will tell dis if every refresh it will come out or not var enablefade="no" //("yes" to enable fade in effect, "no" to disable) better no, if yes it will be laggish var autohidebox=["yes", 10] //Automatically hide box after x seconds? [yes/no, if_yes_hide_after_seconds] var showonscroll="yes" //Should box remain visible even when user scrolls page? ("yes"/"no) ////////No need to edit beyond here/////////// if (parseInt(displaymode)!=NaN) var random_num=Math.floor(Math.random()*displaymode) function displayfadeinbox(){ var ie=document.all && !window.opera var dom=document.getElementById iebody=(document.compatMode=="CSS1Compat")? document.documentElement : document.body objref=(dom)? document.getElementById("fadeinbox") : document.all.fadeinbox var scroll_top=(ie)? iebody.scrollTop : window.pageYOffset var docwidth=(ie)? iebody.clientWidth : window.innerWidth docheight=(ie)? iebody.clientHeight: window.innerHeight var objwidth=objref.offsetWidth objheight=objref.offsetHeight objref.style.left=docwidth/2-objwidth/2+"px" objref.style.top=scroll_top+docheight/2-objheight/2+"px" if (showonscroll=="yes") showonscrollvar=setInterval("staticfadebox()", 50) objref.style.visibility="visible" if (objref.style.MozOpacity){ mozfadevar=setInterval("mozfadefx()", 90) } else controlledhidebox() } function staticfadebox(){ var ie=document.all && !window.opera var scroll_top=(ie)? iebody.scrollTop : window.pageYOffset objref.style.top=scroll_top+docheight/2-objheight/2+"px" } function hidefadebox(){ objref.style.visibility="hidden" if (typeof showonscrollvar!="undefined") clearInterval(showonscrollvar) } function controlledhidebox(){ if (autohidebox[0]=="yes"){ var delayvar=(enablefade=="yes" && objref.filters)? (autohidebox[1]+objref.filters[0].duration)*1000 : autohidebox[1]*1000 setTimeout("hidefadebox()", delayvar) } } function initfunction(){ setTimeout("displayfadeinbox()", 100) } function get_cookie(Name) { var search = Name + "=" var returnvalue = "" if (document.cookie.length > 0) { offset = document.cookie.indexOf(search) if (offset != -1) { offset += search.length end = document.cookie.indexOf(";", offset) if (end == -1) end = document.cookie.length; returnvalue=unescape(document.cookie.substring(offset, end)) } } return returnvalue; } if (displaymode=="oncepersession" && get_cookie("fadedin")=="" || displaymode=="always" || parseInt(displaymode)!=NaN && random_num==0){ if (window.addEventListener) window.addEventListener("load", initfunction, false) else if (window.attachEvent) window.attachEvent("onload", initfunction) } //FINISH! hope u Lyk iT //u can PM if u want me 2 do the script for you...^_^ //june211989@yahoo.com......hehe comment me huh ^_~[/quote] [b]i still dont get it... first put the css in your css ext.. right?.. then the js script where should i put it?... in the compiled one or i should create another file for that... and that js code... will it go to the compiled one or the js script and the js code be at same file... i'm really confuse....[/b] :cloud: :wallbash: :wallbash: :wallbash: :wallbash: :wallbash: :wallbash: :wallbash:

Pages: 11234567891011..11

Board footer

© 2025 F Talk

Current time is 20:49

[ 12 queries - 0.014 second ]
Privacy Policy