How to change the dot in an ordered list 2. into a round bracket 2) or something else.
ol { counter-reset: item; list-style-type: none; } li { display: block; } li:before { content: counter(item) ") "; counter-increment: item }
by Rolf van Gelder | CAGE Web Design, Eindhoven
How to change the dot in an ordered list 2. into a round bracket 2) or something else.
ol { counter-reset: item; list-style-type: none; } li { display: block; } li:before { content: counter(item) ") "; counter-increment: item }
To dim the screen while waiting for an Ajax call to finish:
CSS
#loading-ajax { background: rgba(0,0,0,.2) url('/images/ajax-loader.gif') no-repeat 50% 50%; width: 100%; height: 100%; position: fixed; top: 0; left: 0; z-index: 999; }
html
<div id="loading-ajax" style="display:none"></div> (...) <a href="javascript:;" onclick="start_ajax();"><img src="/images/my_img.gif" /></a>
javascript
function start_ajax() { jQuery("#loading-ajax").show(); jQuery.get( "my_ajax_url", { action: "do_something" } ) .done(function( data ) { jQuery("#loading-ajax").hide(); if(data == 'error') alert('error detected') else alert(data); }); }
Resource:
http://stackoverflow.com/questions/7046484/dim-the-page-and-show-a-loading-indicator
Truncate long text (…) using a style sheet.
Code snippet:
.rvg_vacframe .left {
float: left;
width: 450px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
-o-text-overflow: ellipsis;
}
Resources:
http://stackoverflow.com/questions/10762424/html-css-ellipsis-not-working