Skip to content

Instantly share code, notes, and snippets.

View nathan-roberts's full-sized avatar
💭
Building

Nathan Roberts nathan-roberts

💭
Building
View GitHub Profile
span.number span {
padding: 10px 5px;
/* border: 1px solid #ccc; */
/* border-radius: 5px; */
display: inline-block;
/* cursor: move; */
}
.popup {
width: 100%;
@nathan-roberts
nathan-roberts / .gitignore
Created July 22, 2023 05:52
WordPress Gitignore
# WP Config
wp-config.php
# ignore these plugins
wp-content/plugins/hello.php
# ignore specific themes
wp-content/themes/twenty*/
@nathan-roberts
nathan-roberts / function.php
Created November 8, 2023 23:27
ACF JSON - Save Specific Groups within Plugin
// Save ACF JSON for specific field groups only
add_filter('acf/update_field_group', 'hof_acf_json_save_for_specific_groups', 10, 1);
function hof_acf_json_save_for_specific_groups($field_group)
{
// Define your allowed field groups
$allowed_field_groups = array('group_650da9580c565'); // Replace with your actual field group keys
// Check if the current field group is allowed