function wbc_match_admin_shortcode( $atts ) {
// Default
$match_id = 12;
// Shortcode attribute takes priority
if ( isset($atts['match_id']) ) {
$match_id = intval($atts['match_id']);
}
// URL parameter fallback
if ( isset($_GET['match_id']) ) {
$match_id = intval($_GET['match_id']);
}
// If no match ID, stop early
if ( !$match_id ) {
return '
No match selected.
';
}
// Load data
$match = wbc_get_match_data( $match_id );
$availability = wbc_get_availability_data( $match_id );
$status = wbc_get_match_status( $match_id );
ob_start();
?>
Player Availability
Available (
Warning: Undefined variable $availability in /homepages/16/d4299354626/htdocs/wordpress/wp-content/plugins/WBC 2027/wbc-match-admin.php on line 107
Warning: Trying to access array offset on null in /homepages/16/d4299354626/htdocs/wordpress/wp-content/plugins/WBC 2027/wbc-match-admin.php on line 107
Fatal error: Uncaught TypeError: count(): Argument #1 ($value) must be of type Countable|array, null given in /homepages/16/d4299354626/htdocs/wordpress/wp-content/plugins/WBC 2027/wbc-match-admin.php:107
Stack trace:
#0 /homepages/16/d4299354626/htdocs/wordpress/wp-content/plugins/WBC 2027/wbc-2027.php(23): require_once()
#1 /homepages/16/d4299354626/htdocs/wordpress/wp-settings.php(597): include_once('/homepages/16/d...')
#2 /homepages/16/d4299354626/htdocs/wordpress/wp-config.php(114): require_once('/homepages/16/d...')
#3 /homepages/16/d4299354626/htdocs/wordpress/wp-load.php(50): require_once('/homepages/16/d...')
#4 /homepages/16/d4299354626/htdocs/wordpress/wp-blog-header.php(13): require_once('/homepages/16/d...')
#5 /homepages/16/d4299354626/htdocs/wordpress/index.php(17): require('/homepages/16/d...')
#6 {main}
thrown in /homepages/16/d4299354626/htdocs/wordpress/wp-content/plugins/WBC 2027/wbc-match-admin.php on line 107