Skip to content

Instantly share code, notes, and snippets.

@WPDevHQ
WPDevHQ / font-awesome.php
Created August 23, 2016 11:27 — forked from justintadlock/font-awesome.php
PHP array of Font Awesome icons.
<?php
// Font Awesome v. 4.6.
function jt_get_font_icons() {
return array(
'fa-glass' => 'f000',
'fa-music' => 'f001',
'fa-search' => 'f002',
'fa-envelope-o' => 'f003',
@WPDevHQ
WPDevHQ / 0_reuse_code.js
Created August 10, 2016 05:51
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@WPDevHQ
WPDevHQ / woo-custom-redirect
Created August 6, 2016 23:00 — forked from anant1811/woo-custom-redirect
Woocommerce - custom redirection on checkout
//*Add custom redirection
add_action( 'template_redirect', 'wc_custom_redirect_after_purchase' );
function wc_custom_redirect_after_purchase() {
global $wp;
if ( is_checkout() && ! empty( $wp->query_vars['order-received'] ) ) {
wp_redirect( 'http://mysite.com/thank-you-for-your-order/' );
exit;
}
}
@WPDevHQ
WPDevHQ / _base.scss
Created March 19, 2016 02:36 — forked from yratof/_base.scss
WooCommerce Checkout for Mobile
@media only screen and (max-width: 760px) {
.woocommerce-cart #content .woocommerce table.shop_table td,
.woocommerce-cart #content .woocommerce-page table.shop_table td,
.woocommerce-checkout #content .woocommerce table.shop_table td,
.woocommerce-checkout #content .woocommerce-page table.shop_table td {
padding: 3px 0;
border-top: 0;
}