Skip to content

Instantly share code, notes, and snippets.

@kasparsd
kasparsd / custom-post-taxonomy-permalinks.php
Created June 13, 2012 15:47
Create permalink structure URLs for custom post types that include all parent terms from a custom taxonomy
<?php
/*
Term Archive Pages:
- http://example.com/recipes/dinner/
- http://example.com/recipes/breakfast,brunch/
Single Recipe Pages:
- http://example.com/recipes/dinner/soup-title/
@stela5
stela5 / getfontface.php
Created October 1, 2011 15:53
Return full font face information for a specified Google Web Font
<?php
// Description: Returns json object with Google font-face in woff and ttf, if available
// Usage:
// Bold Italic: get-font-face.php?family=Lobster+Two:700italic
// Italic: get-font-face.php?family=Lobster+Two:400italic
// Bold: get-font-face.php?family=Lobster+Two:700
// Regular: get-font-face.php?family=Lobster+Two:400
// setup
$headers[] = 'Connection: Keep-Alive';