A way to vertically center content on a webpage using the css table property. html { height: 100%; } body { display: table; width: 100%; height: 100%; } #childtobody { display: table-cell; vertical-align: middle; text-align: center; }
Tag: html
IE7 Input Button Width Issue
IE7 and IE6 will by default add padding to input button object depending on width, to remove the extra padding, add the following css to your input object: overflow: visible;
IE7 z-index issues
If you have z-index issues, particularly with drop down menus in IE7 this conditional script may help. <!–[if IE 7]> <script type=”text/javascript”> $(document).ready(function(){ $(function() { var zIndexNumber = 1000; $(‘div’).each(function() { $(this).css(‘zIndex’, zIndexNumber); zIndexNumber -= 10; }); }); }) </script> <![endif]–>
Force Files To Download Instead Of Open In Web Browser
You can change the file directivies for a folder by adding a .htaccess file in the folder and including the following code: <IfModule mod_headers.c> <FilesMatch “\.(?i:mp3|ogg)$”> ForceType application/octet-stream Header set Content-Disposition attachment </FilesMatch> </IfModule> This will force .mp3 and .ogg files to prompt for action rather than open with the default browser setting. The IfModule […]
Prevent Access And Directory Listing To A Folder Using .htaccess
If someone browses to a folder on your website that does not have an index file it will, by default, list the directory’s contents. If you have an Apache based web server you can prevent access to this folder by placing a .htaccess file within it containing the following code: Options -Indexes This can also […]
Preloaders – GIF and APNG generator
Preloaders.net has a large range of preloaders and gifs in various categories. Features: Save to gif or apng Transparency Background and foreground colours Animation speed Output size options WEBSITE
Ajaxload Gif Generator
Ajaxload is a quick and simple gif generator. Features: Long list of styles No size options Background and foreground colours Transparency WEBSITE