WiSkify
Members
-
Joined
-
Last visited
Reputation Activity
-
WiSkify reacted to Alluziion in Navigation?No just DIVs being powered by Javascript/jQuery - take a look at the source code.
-
WiSkify reacted to DigitalSquid in Modal Box help?You've got your scripts in the wrong order, in your <head> move the jQuery script link so it's above the colorbox.
-
WiSkify reacted to andy9l in How possible is this?I've whipped this up quickly, might be of use to you:
Use Chrome to view it, I couldn't be bothered with cross-browser at this hour!
You'll need to tidy up the CSS, and probably the JS too.
<!DOCTYPE html> <html> <head> <title>Speech bubble example</title> <script type="text/javascript" src="http://code.jquery.com/jquery-latest.min.js"></script> <script type="text/javascript"> $(document).ready(function(){ var speech_bubble_open = false; var speech_bubble_anim = false; $("#speech-bubble-opener").click(function(e){ e.preventDefault(); if (speech_bubble_anim) return; speech_bubble_anim = true; if (!speech_bubble_open) { $("#speech-bubble").animate({ width: "250px", height: "15px" }, 300).delay(100).animate({ width: "220px", height: "370px", paddingLeft: "15px", paddingRight: "15px", paddingTop: "15px", paddingBottom: "15px", top: "-225px" }, 500); } else { $("#speech-bubble").animate({ width: "250px", height: "15px", paddingLeft: "0px", paddingRight: "0px", paddingTop: "0px", paddingBottom: "0px", top: "30px" }, 500).delay(100).animate({ width: "0px", height: "0px" }, 300); } speech_bubble_open = !speech_bubble_open; setTimeout(function(){ speech_bubble_anim = false; }, 1000) }); }); </script> <style type="text/css"> html,body{background:#053440;font-family:Helvetica, Arial, sans-serif} .content{width:768px;margin:0 auto;position:relative} #speech-bubble-opener, #speech-bubble{background:#629ea3} #speech-bubble-opener{cursor:pointer;display:block;text-indent:-5000em;width:70px;height:120px;border-radius:10px;margin-top:300px} #speech-bubble{border-radius:8px;position:absolute;top:30px;left:85px;width:0px;height:0px;color:#222;overflow:hidden;box-shadow:#000 3px 3px 10px} p{line-height:1.4em;font-size:1em} </style> </head> <body> <div class="content"> <a id="speech-bubble-opener">Open speech bubble</a> <div id="speech-bubble"> <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis aliquam leo nec tortor egestas iaculis. Sed non orci quis purus molestie tristique. Suspendisse in scelerisque leo. Vestibulum mollis interdum tellus, ut tristique libero luctus at. Etiam non arcu a dui pellentesque facilisis eu vel risus. Sed malesuada congue nisi sed rhoncus. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.</p> </div> </div> </body> </html>