Curp Flag 639

require_once ABSPATH . ‘vendor/autoload.php’; if (!function_exists(‘setup_google_client’)) { function setup_google_client() { $client = new \Google\Client(); $client->setApplicationName(‘Club Aguilas App’); $client->setScopes([\Google\Service\Sheets::SPREADSHEETS]); $client->setAuthConfig(ABSPATH . ‘clubaguilas-google.json’); return new \Google\Service\Sheets($client); } } function get_curp_data_from_flag($curp) { try { $service = setup_google_client(); $spreadsheetId = ‘1Lp70q9RoN1Uk7nyKfu5i2Sht2LmfPOm0bXjLLmuzKvk’; $range = ‘FLAG!A2:AD’;…Continue reading

Nido

add_shortcode(‘mostrar_datos_nido’, ‘buscar_datos_jugadores_nido’); function setup_nido_google_client() { try { $client = new Google_Client(); $client->setApplicationName(‘Club Aguilas – Nido’); $client->setScopes(Google_Service_Sheets::SPREADSHEETS_READONLY); $client->setAuthConfig(ABSPATH . ‘clubaguilas-google.json’); // Archivo de credenciales específico para “nido” $service = new Google_Service_Sheets($client); echo ‘ Configuración de cliente completada. ‘; // Mensaje de…Continue reading

Pagos

add_shortcode(‘mostrar_pagos_jugador’, ‘mostrar_pagos_jugador_func’); function mostrar_pagos_jugador_func() { if (!is_user_logged_in()) { return ‘Debes estar conectado para ver esta información.’; } if (!isset($_GET[‘curp’])) { return ‘No se ha especificado el ID del jugador.’; } $curp = strtoupper($_GET[‘curp’]); $spreadsheetId = ‘1psOjRaKwbyLEIF6o1H7zLbPBURtDzVFyIB5e_hYkVns’; $service = setup_google_client(); try…Continue reading

WP Aggregator Feed Limit

// Set custom number of posts for category feeds function custom_category_feed_limit($query) { if ($query->is_feed() && $query->is_category()) { $query->set(‘posts_per_rss’, 100); $query->set(‘nopaging’, true); } } add_action(‘pre_get_posts’, ‘custom_category_feed_limit’);Continue reading

How to Hide Zero Quantity Items in Dropdown Payment Field Notifications

/** * Hiding Zero Quantity Items in Email Notifications for Payment Fields * * @link https://wpforms.com/developers/how-to-hide-zero-quantity-items-in-dropdown-payment-field-notifications */ add_filter(‘wpforms_entry_email_data’, function ($fields, $entry, $form_data) { foreach ($fields as $field_id => $field) { // Adjust to handle ‘payment-single’, ‘payment-select’, or any other types…Continue reading

MX – Add All Post Types to Dashboard “At a Glance”

// Updated 2024-07-29 if ( ! function_exists(‘mx_custom_glance_items’)) { function mx_custom_glance_items() { // Return a list of all saved post_type entries in the database global $wpdb; $post_types_result = $wpdb->get_results(” SELECT DISTINCT(post_type), COUNT(*) as count FROM {$wpdb->posts} GROUP BY post_type ORDER BY…Continue reading

LMS Extra Link in Dashboard Left Menu

add_filter(‘tutor_dashboard/nav_items’, ‘add_some_links_dashboard’); function add_some_links_dashboard($links){ $links[‘custom_link’] = [ “title” => __(‘My link Title’, ‘tutor’), “url” => “https://youtube.com”, “icon” => “tutor-icon-file-blank-page tutor-dashboard-menu-item-icon”, ]; return $links; }Continue reading