Skip to content

Instantly share code, notes, and snippets.

View Kodzhesyan's full-sized avatar
🎯
Focusing

Roman Kodzhesyan

🎯
Focusing
  • Kharkiv, Ukraine
View GitHub Profile
@Kodzhesyan
Kodzhesyan / functions.php
Last active March 5, 2023 17:28
додає валюту Українська гривня (UAH) до WooCommerce
<?php
// Добавляем валюту гривня в WooCommerce
add_filter('woocommerce_currencies', 'add_my_currency');
function add_my_currency($currencies) {
$currencies['UAH'] = __('Українська гривня', 'woocommerce');
return $currencies;
}
@sonipb
sonipb / ultimate-guide-to-woocommerce-checkout-fields.html
Last active December 16, 2021 01:19
woocommerce checkout page : Ultimate Guide to WooCommerce Checkout Fields
// ref. https://jeroensormani.com/ultimate-guide-to-woocommerce-checkout-fields/
//This post is meant as a one stop shop if you’d like to make any kind of customizations to your WooCommerce checkout fields. Whether this is adding additional fields, removing some unneeded ones or changing the order they’re displayed in.
This post is meant as a one stop shop if you’d like to make any kind of customizations to your WooCommerce checkout fields. Whether this is adding additional fields, removing some unneeded ones or changing the order they’re displayed in.
Additionally there will be guides on how do display fields two field side by side, updates the order totals when a field changes and how to add basic field validation.
This is a post with a lot of code snippets and likely requires changes for it to fit your exact needs. Prefer to use a plugin instead? Take a look at my Advanced Checkout Fields for WooCommerce plugin.
Good to Know
These are some good to know files, hooks and functions/methods. Some of these
@maddisondesigns
maddisondesigns / functions.php
Last active October 28, 2024 06:14
WooCommerce Custom Fields for Simple & Variable Products
/*
* Add our Custom Fields to simple products
*/
function mytheme_woo_add_custom_fields() {
global $woocommerce, $post;
echo '<div class="options_group">';
// Text Field
*PPD-Adobe: "4.3"
*%%%% PPD file for ZPL Label Printer with CUPS.
*%%%% Created by the CUPS PPD Compiler CUPS v1.7.5.
*% Copyright 2007-2012 by Apple Inc.
*% Copyright 1997-2007 by Easy Software Products.
*%
*% These coded instructions, statements, and computer programs are the
*% property of Apple Inc. and are protected by Federal copyright
*% law. Distribution and use rights are outlined in the file "LICENSE.txt"
*% which should have been included with this file. If this file is