Duplicate Post/Page Link (copy)

// 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

Remove trailing slash from homepage URL in AIOSEO sitemap

function aioseo_remove_trailing_slash_from_homepage( $entry, $post_id, $post_type, $entry_type ) { // Get the homepage ID $homepage_id = aioseo()->helpers->getHomePageId(); // Check if this is the homepage if ( $homepage_id && $post_id === $homepage_id ) { // Remove trailing slash from the URL if…Continue reading

Skip Unwanted 404 Logs

add_filter( ‘aioseo_redirects_log_skip’, ‘redirects_log_skip’, 10, 2 ); function redirects_log_skip( $skip, $data ) { // Define a list of unwanted URLs $ignoreUrls = [ ‘/config.json’, ‘/home’, ‘/main’, ‘/server-status’, ‘/private’ ]; // Skip logging these URLs if they result in a 404 error…Continue reading

Studex CM Main Menu

function homelink(){ $homelink = ‘Home‘; return $homelink;} function shoplink() { return ‘Shop‘;} function discoverlink() { $discoverlink = ‘Discover STUDEX®‘; return $discoverlink; } function bloglink() { $bloglink = ‘Trend Blog‘; return $bloglink; } function b2blink() { $b2blink = ‘STUDEX® B2B‘; return…Continue reading

Mjellma Widget

function custom_dashboard_widget() { echo ‘ Për cdo pytje rreth webfaqes ju lutem na kontaktoni. Website: Mjellma.al Email: [email protected] Phone Number: +383 49 844 249 ‘; } function add_custom_dashboard_widget() { wp_add_dashboard_widget( ‘custom_dashboard_widget’, ‘Shërbimi i ndihmës.’, ‘custom_dashboard_widget’ ); } add_action(‘wp_dashboard_setup’, ‘add_custom_dashboard_widget’);Continue reading

Entry Forms

/** * Entry Automation Helper – With Column Loading Fix * Set to “Run Everywhere” in WPCode */ defined(‘ABSPATH’) || exit; add_action(‘admin_enqueue_scripts’, function($hook_suffix) { wp_enqueue_script(‘jquery’); $inline_js = 0) { var $actualSelect = $select2Container.prev(‘select’); if ($actualSelect.length === 0) { $actualSelect =…Continue reading

Mobile Menu Shortcode (copy)

function mobile_menu_shortcode( $atts ) { $atts = shortcode_atts( array( ‘menu_id’ => ”, // Optional menu ID ‘svg_url’ => ”, // Optional SVG URL for submenu toggle icon ), $atts, ‘mobile_menu’ ); // If no menu ID provided, get the first…Continue reading