View gist:bafedb58d85a8524618d64078d4b0486
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Ajouter le champ de case à cocher à l'interface d'administration WooCommerce | |
add_action( 'woocommerce_product_options_general_product_data', 'custom_product_checkbox' ); | |
function custom_product_checkbox() { | |
woocommerce_wp_checkbox( array( | |
'id' => 'is_rare', | |
'label' => __( 'Is Rare', 'woocommerce' ), | |
'description' => __( 'Check this box if the product is rare', 'woocommerce' ), | |
'desc_tip' => true, | |
) ); | |
} |
View wysiwyg.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Options wisywg | |
add_filter('mce_buttons_2', function( $buttons ) { | |
array_shift( $buttons ); | |
array_unshift( $buttons, 'fontsizeselect'); | |
return $buttons; | |
} ); | |
add_filter( 'tiny_mce_before_init', function( $initArray ){ | |
$initArray['theme_advanced_font_sizes'] = "9px 10px 12px 13px 14px 16px 18px 22px 24px 28px 32px 36px"; |
View googleSheets.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let spreadsheetid = "ID Spreadsheet" | |
let sheetname = "Sheet Name" | |
let apikey = "COMPLETE" // Activate Google Sheets Service | |
const endpoint = 'https://sheets.googleapis.com/v4/spreadsheets/' + spreadsheetid + '/values/' + sheetname + '?alt=json&key=' + apikey; | |
console.log(endpoint) | |
// The URL of your JSON endpoint | |
View index.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<header> | |
<h1>SITE TITLE</h1> | |
<nav> | |
<ul> | |
<li><a href="#">HOME</a></li> | |
<li><a href="#">ABOUT</a></li> | |
<li><a href="#">SERVICES</a></li> | |
<li><a href="#">CONTACT</a></li> | |
</ul> | |
</nav> |