Home
PHP
Tech Tube
MySQL
Linux
CSS&HTML
JavaScript
Useful CSS snippets
This page will be used to store random but useful CSS snippets.

Align fonts in the vertical center:
more...
Simple pie chart
A simple pie chart:


more...
Basic CSS loader with overlay
An element that will show loading on top of everything else (or below z-index 9999).
Note that it's hidden (display: none) but it's up to you to show it at the right time ;)

more...
Element background zoom on hover
The following CSS code will allow you to create a background zoom effect.

div.wrap {height: 300px;width: 300px;overflow: hidden;position: relative;}div.wrap > div {position: absolute;height: 100%;width: 100%;-moz-transition: all .5s;-webkit-transition: all .5s;transition: all .5s;-moz-transform: scale(1,1);-webkit-transform: scale(1,1);transform: scale(1,1);background-image: url('https://samiwell.eu/userfiles/posts/57/5b100bc9b5e1c.jpg');-moz-background-size: cover;-webkit-background-size: cover;background-size: cover;z-index: -1;}div.wrap:hover > div {-moz-transform: scale(1.5,1.5);-webkit-transform: scale(1.5,1.5);transform: scale(1.5,1.5);}
more...
Social media share box
Quick and easy way to do a social media share box.
In this case it's available for Facebook, Tweeter and Google+

more...
Cool gradient buttons
Gust some cute looking gradient buttons :)


more...
Dropdown menu
Here's a simple CSS dropdown menu:

Demo:
more...
CSS overlay
Here's a simple but effective CSS overlay.
It has a box on top of the overlay that could be used as
popup or loading indicator.
more...
Use youtube video as background
Just a cute video background

* { box-sizing: border-box; }
more...
CSS reset
Simple but effective CSS reset.
Makes sure that the default CSS styles will be the same for all browsers.

more...