Welcome To Snipplr
Everyone's Recent Snippets
- All /
- JavaScript /
- HTML /
- PHP /
- CSS /
- Ruby /
- Objective C
This is source I created from a project currently in development.
0
955
posted 14 years ago by chrislorenz
Of course, you don't have to set the width to 50%. Any width less than the containing div will work. The margin: auto is what does the actual centering.
1
938
posted 14 years ago by alozuldo
This code war written for a project I'm working on where a map of the world may need to be offset to center the view on specific areas. I'm also using it as a part of an iterative blur function to prevent seams from the blur operation.
I would lik...
0
789
posted 14 years ago by Jamie
If you would like to use relative units (em) for your font sizes, declaring 62.5% for the font-size property of the body will make it easier to convert px to em. By doing it this way, converting to em is a matter of dividing the px value by 10 (e.g....
3
988
posted 14 years ago by alozuldo
For progressive enhancement, you could use the transform property that is supported by many browsers that have CSS3 support.
Here’s a trick for enlarging a elements on hover by 110%.
1
836
posted 14 years ago by alozuldo
The code below will change the background-color of divs depending on what browser the user is viewing the web page under. Since * cascades down to IE7 and below, we use _ after that declaration so that IE6 (and below) has a different background color...
1
915
posted 14 years ago by alozuldo
This crude script will export individual icons from an SVG file when using a single canvas workflow, especially for Tango Desktop style icons.
0
533
posted 14 years ago by Dracos
Existen varias formas para hacerlo, pero lo que dejo aquà es a lo que tenemos que acostumbrarnos a hacer cada vez que programemos para prevenir que se pueda inyectar HTML o modificar las consultas SQL.\r\n\r\nThere are several ways to do it, but wha...
0
581
posted 14 years ago by arucordoba
Demo, info & FLA download at http://adamcoulombe.info/lab/as3/card-flip.html
4
1203
posted 14 years ago by adamcoulombe
The command you need to close the mysql port 3306 from external access. You need to use the 2 lines in the snippet below once you have connected to the server via SSH.
0
985
posted 14 years ago by daipratt
Single line to get the package path of the current class path (package)
1
908
posted 14 years ago by dyteq