I like Twitter API method displaying information message in flash style. I had developed a small web application like twitter flash message using jQuery. It's useful and simple just enrich your web projects.
Twitter information message.
Javascript Code:
You have to modify setTimeout() value.
<script type="text/javascript"
src="http://ajax.googleapis.com/ajax/libs/
jquery/1.3.0/jquery.min.js">
</script>
<script type="text/javascript" > $(document).ready(function(){ setTimeout(function(){ $(".flash").fadeOut("slow", function () { $(".flash").remove(); }); }, 2000); }); </script>
flash.php
Contains PHP and HTML Code.
<?php
if($_SERVER["REQUEST_METHOD"] == "POST")
{
// Some data....
$message="<div class='flash'> Information message !</div>";
}
?>
<div align="center">>
<?php echo $message; ?>
</div>
Style Sheet
CSS code.
.flash{
width:759px;
padding-top:8px;
padding-bottom:8px;
background-color: #fff;
font-weight:bold;
font-size:20px;-moz-border-radius: 6px;-webkit-border-radius: 6px;
}
12 comments:
awesome, man
thanks for the share
wow, thats what i was waiting for
amazing, dude
I'm loving it
amazing, dude
I'm loving it
thanks, keep visiting
thats alright
keep on visit, to get more
thanks, and keep on visit
thanks, and keep on visit
thanks, and keep on visit
Very helpful and easy
Post a Comment