Custom Countries
Illustrates how to add a custom list of countries
Generate a virtual coupon when order is completed.
This snippet will generate a new virtual coupon for a coupon that you've enabled virtual coupon…
Disable PayPal for Multi-Item Checkout
Disables the PayPal gateway when the cart contains multiple items. PayPal disabled the ability to purchase…
How to change the store address country for all vendors
/** * Set the vendor's store country to us. */ function wcv_set_vendor_country() { if ( function_exists(…
Current Year
function current_year_shortcode() { return date('Y'); } add_shortcode('year', 'current_year_shortcode');
Untitled Snippet
google-site-verification=Z6ci_S0g839p6z-pqU4OUb5KSQpdoJBRrjh791uaErY
Escaping data with wp_kses
// ❌ Don't use html tags in escaping functions like esc_html, esc_attr and their localized equivalents…
Tweak Price Display (Adjusts the Prices) | Display Eventbrite Events
The Display Eventbrite plugin premium version can display prices. If you want to tweak to display…
Disable WP Texturize
// Disable curly quotes remove_filter( 'the_content', 'wptexturize' );
unitap.io
function myfirsttheme_setup() { /* * Load additional block styles. */ $styled_blocks = ['latest-comments']; foreach ( $styled_blocks…
Untitled Snippet
// Get the butterflies container const butterfliesContainer = document.querySelector('.butterflies'); // Create a function to generate a…
om-emberjs.js
// Using Ember.js. import Route from '@ember/routing/route'; export default Route.extend({ beforeModel(transition) { if (window.om5678_1234) { window.om5678_1234.reset();…
slide-bottom-center.css
html div#om-{{id}} { width: 350px !important; left: calc(350px / 2) !important; right: calc(350px / 2) !important;…
The draft of receipt
from reportlab.lib.pagesizes import A4 from datetime import datetime from reportlab.platypus import Table, TableStyle, Paragraph, SimpleDocTemplate, Image,…