A mixin for writing @font-face rules in SASS.
Create a font face rule. Embedded OpenType, WOFF2, WOFF, TrueType, and SVG files are automatically sourced.
@include font-face(Samplino, fonts/Samplino);
<div class="antialiased p-16 bg-gray-800"> | |
<div class="max-w-6xl mx-auto"> | |
<div class="bg-gray-100 relative flex"> | |
<div class="w-7/12 px-20 py-24"> | |
<svg class="w-48" viewBox="0 0 185 32" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M60.854 28.18h3.768l3.144-11.088 3.168 11.088h3.768l4.704-16.8h-3.48L72.71 23.836 69.182 11.38H66.35l-3.504 12.456L59.63 11.38h-3.48l4.704 16.8zM85.465 28.516c3.528 0 6.36-2.76 6.36-6.336 0-3.576-2.832-6.336-6.36-6.336-3.528 0-6.336 2.76-6.336 6.336 0 3.576 2.808 6.336 6.336 6.336zm0-3.024c-1.824 0-3.24-1.368-3.24-3.312 0-1.944 1.416-3.312 3.24-3.312 1.848 0 3.264 1.368 3.264 3.312 0 1.944-1.416 3.312-3.264 3.312zM97.1 18.244V16.18h-3.097v12H97.1v-5.736c0-2.52 2.04-3.24 3.648-3.048V15.94c-1.512 0-3.024.672-3.648 2.304zM113.622 28.18l-4.968-6.072 4.824-5.928h-3.696l-4.128 5.28V11.38h-3.096v16.8h3.096v-5.448l4.368 5.448h3.6z" fill="#2D3748"/><path d="M120.879 28.516c2.352 0 4.392-1.248 5.424-3.12l-2.688-1.536c-.48.984-1.512 1.584-2.76 1.584-1.848 0-3.2 |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Check Data Object Array Length & Hide When Empty</title> | |
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script> | |
</head> | |
<body> | |
<ul id="app"> | |
<li v-if="!items.length">No item found</li> |
<?php // Do not include this if already open! Code goes in theme functions.php. | |
/* | |
* Force customer creation process in Stripe. | |
*/ | |
add_filter( 'wc_stripe_force_save_source', '__return_true' ); |
ssh -o PreferredAuthentications=password -o PubkeyAuthentication=no account@your-ip |
<?php | |
function my_pmprorh_depends_fields_init() | |
{ | |
//don't break if Register Helper is not loaded | |
if(!function_exists("pmprorh_add_registration_field")) | |
{ | |
return false; | |
} | |
//add a new "About Your Pets" box on checkout form |
<?php | |
/* | |
Plugin Name: PMPro Customizations | |
Plugin URI: https://www.paidmembershipspro.com/wp/pmpro-customizations/ | |
Description: Customizations for my Paid Memberships Pro Setup | |
Version: .1 | |
Author: Paid Memberships Pro | |
Author URI: https://www.paidmembershipspro.com | |
*/ |
add_action( 'wp_ajax_nopriv_ajax_pagination', 'my_ajax_pagination' ); | |
add_action( 'wp_ajax_ajax_pagination', 'my_ajax_pagination' ); | |
function my_ajax_pagination() { | |
echo get_bloginfo( 'title' ); | |
die(); | |
} |
<?php | |
// hacks and mods will go here | |
/** | |
* Disables BuddyPress' registration process and fallsback to WordPress' one. | |
*/ | |
function my_disable_bp_registration() { | |
remove_action( 'bp_init', 'bp_core_wpsignup_redirect' ); | |
remove_action( 'bp_screens', 'bp_core_screen_signup' ); | |
} | |
add_action( 'bp_loaded', 'my_disable_bp_registration' ); |
function get_attachment_id_from_src ($image_src) { | |
global $wpdb; | |
$query = "SELECT ID FROM {$wpdb->posts} WHERE guid='$image_src'"; | |
$id = $wpdb->get_var($query); | |
return $id; | |
} |