Skip to content

Instantly share code, notes, and snippets.

Avatar
🌴
Coding

Sven hofmannsven

🌴
Coding
View GitHub Profile
@hofmannsven
hofmannsven / google_fonts.md
Created Apr 2, 2020 — forked from cvan/google_fonts.md
get ttf, woff, woff2 from Google Fonts
View google_fonts.md

ttf

curl 'https://fonts.googleapis.com/css?family=Karla'

woff2

curl 'https://fonts.googleapis.com/css?family=Karla' -H 'Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8' -H 'User-Agent: AppleWebKit/537.36 (KHTML, like Gecko) Chrome/48.0.2564.116'

woff

@hofmannsven
hofmannsven / readme.md
Last active Nov 4, 2021 — forked from guenthertheilen/gist:8401080
Install PHP Composer on Managed Hosting at Domainfactory.
View readme.md

Install Composer on Managed Hosting at Domainfactory

Step 1:

Log in to your Managed Hosting Server via SSH. Create your .bashrc:

touch .bashrc
@hofmannsven
hofmannsven / README.md
Last active Sep 3, 2020 — forked from sergejmueller/index.html
Nginx proxy configuration for Google Analytics
View README.md

Google Analytics Nginx Proxy

Google PageSpeed Insights flags browser caching of Google Analytics:

Leverage browser caching

Set up a proxy in your Nginx configuration file to address this issue.

Source

View functions.php
<?php
// add ie conditional html5 shim to header
function _s_add_ie_html5_shim () {
echo '<!--[if lt IE 9]>';
echo '<script src="' . get_template_directory_uri() . '/js/html5.js"></script>';
echo '<![endif]-->';
}
add_action('wp_head', '_s_add_ie_html5_shim');
View r-debug.php
<?php
/*
Plugin Name: R Debug
Description: Set of dump helpers for debug.
Author: Andrey "Rarst" Savchenko
Author URI: http://www.rarst.net/
License: MIT
*/
/**