1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
|
<html>
<head>
<title>test</title>
<script type="text/javascript" src="mootools.v1.11.js"></script>
<script type="text/javascript">
window.addEvent('domready', function(){
var mySlide = new Fx.Slide('a1');
$('q1').addEvent('click', function(e){
e = new Event(e);
mySlide.toggle();
e.stop();
});
});
</script>
<style>
body {
font: Arial;
font-size: 14px;
}
#q1 {
background: #f49401;
color: #ffffff;
padding: 10px;
cursor: pointer;
}
#a1 {
background: #0f0f0f;
color: #ffffff;
padding: 10px;
}
</style>
</head>
<body>
<div id="q1">
How are you today? (click on the question to display the answer)
</div>
<div id="a1">
Actually the answer doesn't matter (but I hope your right anyway). <br>
This is just a test to display the answer of a question in a FAQ, with nice slide fx.
</div>
</body>
</html> |