Skip to content

Instantly share code, notes, and snippets.

View dmassiani's full-sized avatar

Carolinus dmassiani

View GitHub Profile
Verifying that +davidmassiani is my blockchain ID. https://onename.com/davidmassiani
@dmassiani
dmassiani / new_gist_file
Created August 13, 2013 14:57
Sublime text replace simple quotes html by double quotes
REGEX Sublime Text de remplacement des simples quotes par des doubles (et inversement)
(en plus d'ajouter le plugin "toggle quotes")
Find '(.*?)'
Where <open files>
Replace "$1"
@dmassiani
dmassiani / new_gist_file
Created April 19, 2013 15:55
Animated Custom Scroll anchor
function scrollToAnchor(aid,v){
var aTag = $(aid);
$('html,body').animate({scrollTop: aTag.offset().top - 60},v);
}
$(document).ready(function(){
$('.subnav').waypoint('sticky');
$('.subnav a').on('click',function(){
@dmassiani
dmassiani / new_gist_file
Created April 18, 2013 06:36
Clearfix after N columns
<?php
if( ($new->current_post % 3) == 2 ){
?>
<div class="clearfix"></div>
<?php
}
?>
@dmassiani
dmassiani / grid-calcul
Created April 4, 2013 06:37
Méthode de calcul d'un grid
Columns : 12
Grid Columns : 60px
Grid Gutter : 30px
-------------------------------------------------------------------
Grid Columns X Columns = GC
Grid Gutter X ( Columns - 1 ) = GG
-------------------------------------------------------------------
@dmassiani
dmassiani / Scrollto
Created April 3, 2013 14:04
Scroll To
$('#bottom').click(function() {
$(documentBody).animate({scrollTop: $('#top').offset().top}, 2000,'easeInOutCubic');
});
@dmassiani
dmassiani / pagenavi html
Created April 2, 2013 07:33
Change html for wp pagenavi
######################
# Change html pagenavi for transform like bootstrap
######################
//attach our function to the wp_pagenavi filter
add_filter( 'wp_pagenavi', 'wd_pagination', 10, 2 );
//customize the PageNavi HTML before it is output
function wd_pagination($html) {
$out = '';