Written by admin in Code Snippet | WordPress

Adding a simple popup message to convey message to the user is definitely worth it.

Here’s a simple and lightweight code snippet I found:

button selector: .view-project
div that contains the message: .warning

CSS CODES:

.warning {
	display: none;
    position: absolute;
    background: #000;
    color: #fff;
    padding: 2px 5px;
    border-radius: 3px;	
}
.view-project:hover + .warning {
	display: block;
}

I’m definitely going to add this whenever necesarry.

Leave a Reply

Your email address will not be published. Required fields are marked *