Skip to content

Instantly share code, notes, and snippets.

@MrUzu
MrUzu / gist:11296423
Created April 25, 2014 17:05
Google Web fonts hacking for chrome Windows
1/ get the SVG version of your font :
a - spoof the user agent
=> Mozilla/4.0 (iPad; CPU OS 4_0_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/4.1 Mobile/9A405 Safari/7534.48.3
b - Display font stylesheet :
=> ex :http://fonts.googleapis.com/css?family=Open+Sans%3A300italic%2C400italic%2C600italic%2C300%2C400%2C600&subset=latin%2Clatin-ext
c - copy the font face declaration
=> ex : @font-face {
font-family: 'Open Sans';
font-style: normal;
font-weight: 400;
<?php
// Sort BuddyPress users by last name
//
// Use this Gist to sort members alphabetically by last name in the
// members directory. Follow the instructions below and drop the code
// in your functions.php or your functions plugin.
//
// Updated to work with BP 1.7. See earlier revisions of this gist for
// earlier versions of BP.
@MrUzu
MrUzu / gist:1268068
Created October 6, 2011 17:41
Remove WordPress admin bar
/*
* Remove admin bar
* Place the script in functions.php
*/
add_filter('show_admin_bar', '__return_false');
@MrUzu
MrUzu / getURIVars.jquery.js
Created July 29, 2011 14:18
jQuery snippet : getURIVars
$.extend({
getURIVars: function( uri ){
var vars = {};
var parts = uri.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {
vars[key] = value;
});
return vars;
},
});
@MrUzu
MrUzu / mobile-meta-html5.html
Created June 24, 2011 14:29
WebApp meta for Icons and Startup screens
<!-- HTML5 DOCTYPE, IMPORTANT -->
<!DOCTYPE html>
<html dir="ltr" lang="en-EN">
<head>
<meta charset="UTF-8" />
<title>Title</title>
<!-- VIEWPORT, AVOID BROWSER NAV BAR, AND HANDHELD DECLARATIONS -->