// Add duplicate button to post/page list of actions. add_filter( ‘post_row_actions’, ‘wpcode_snippet_duplicate_post_link’, 10, 2 ); add_filter( ‘page_row_actions’, ‘wpcode_snippet_duplicate_post_link’, 10, 2 ); // Let’s make sure the function doesn’t already exist. if ( ! function_exists( ‘wpcode_snippet_duplicate_post_link’ ) ) { /** *…Continue reading
// Save Stripe Customer ID to user meta upon user registration add_action( ‘gform_after_submission’, function ( $entry, $form ) { $form_ids = array(3,4,12); if ( ! in_array( (int)$form[‘id’], $form_ids, true ) ) { return; } // Retrieve the Stripe Customer ID…Continue reading
function vturb_shortcode_handler($atts, $content = null) { // Parse attributes $atts = shortcode_atts( [ ‘fullscreen’ => ‘true’, // Enable fullscreen experience (true/false) ], $atts, ‘vturb’ ); // Validate fullscreen attribute $fullscreen_enabled = filter_var($atts[‘fullscreen’], FILTER_VALIDATE_BOOLEAN); ob_start(); // Start output buffering ?>Continue reading
################################# # Page Edit View ################################# function add_page_meta_boxes() { add_meta_box( ‘page_type_meta_box’, __(‘Page Settings’), ‘render_page_meta_boxes’, ‘page’, ‘side’, ‘high’ // Ensures the meta box appears first ); } add_action(‘add_meta_boxes’, ‘add_page_meta_boxes’); // Render the Meta Box function render_page_meta_boxes($post) { // Get existing values…Continue reading
function remove_author_column_from_pages($columns) { if (isset($columns[‘author’])) { unset($columns[‘author’]); // Remove the “Author” column } return $columns; } add_filter(‘manage_page_posts_columns’, ‘remove_author_column_from_pages’);Continue reading
add_filter( ‘aioseo_report_summary_enable’, ‘__return_false’ );Continue reading
add_action( ‘woocommerce_order_status_processing’, ‘rudr_complete’ ); function rudr_complete( $order_id ) { $order = wc_get_order( $order_id ); //$order_data = $order->get_data(); $msg = [ ‘order_id’ => $order_id, ‘site’ => get_site_url() ]; $webhook_url = ‘https://server.bergwerk.li:9000/hooks/kaybee-woocommerce-palos’; //$webhook_url = ‘https://eo9dxhypahm1gsc.m.pipedream.net’; $headers = array(‘Content-Type: application/json’); $ch = curl_init();…Continue reading
add_action( ‘admin_enqueue_scripts’, function () { if ( ! function_exists( ‘aioseo’ ) ) { return; } // Remove the “Select Primary Category” box from the post editor. wp_dequeue_script( ‘aioseo/js/src/vue/standalone/primary-term/main.js’ ); }, 100 ); // Prevent AIOSEO from changing the category to…Continue reading