Update successful notice with pure css and a close button
Posted
by Crays
on Stack Overflow
See other posts from Stack Overflow
or by Crays
Published on 2010-05-08T12:53:02Z
Indexed on
2010/05/08
12:58 UTC
Read the original article
Hit count: 238
css
Hi guys, i've seen websites that allow you to say update your profile and when the stuff is done, they'll stay in the same page or redirect you to another and with a fancy notice that says "Update successful. click here to close" with a lowered opacity black background and a box in the middle with the text within.
I've got most of the stuff, the lowred opacity black background, the middle box with the text and even the click here to close function.
But how i did the "Click here to close" function is by using a link.
Let's say after updating the profile, my script redirect me to index.php?update=successful then i use
$update = $_GET['update'];
if ($update == "successful") {
echo '<div id="BlackScreen"><p id="MiddleBox">You\'ve successfully update your
status!<br><span class="close"><a class="menu" href="index.php">Click to close.
</a></span></div></div>';
}
so that the lowered opacity background div will be gone, but is there another way to do this? Any tips please?
© Stack Overflow or respective owner