<?php
  $post_id = get_the_id();
// echo print_r(get_vehicle_gallery_images()); 
$image_urls = get_post_meta($post_id, 'pictures', true);

if (is_string($image_urls)) {
    $images = explode(',', $image_urls);
} elseif (is_array($image_urls)) {
    $images = $image_urls;
} else {
    $images = [];
}

if (!empty($images)): ?>
    <div class="vehicle-gallery">
        <?php foreach ($images as $index => $img_url): ?>
            <a href="<?php echo esc_url(trim($img_url)); ?>" class="glightbox" data-gallery="vehicle-gallery">
                <?php if ($index === 0): ?>
                    <img src="<?php echo esc_url(trim($img_url)); ?>" alt="Vehicle Image" class="gallery-main-image" />
                <?php else: ?>
                    <img src="<?php echo esc_url(trim($img_url)); ?>" alt="Gallery Thumb" class="gallery-thumb"  />
                <?php endif; ?>
            </a>
        <?php endforeach; ?>
    </div>
<?php endif; ?>

document.addEventListener('DOMContentLoaded', function () {
    new Swiper('.vehicle-gallery', {
        slidesPerView: 5,
        spaceBetween: 10,
        loop: true,
        navigation: {
            nextEl: '.swiper-button-next',
            prevEl: '.swiper-button-prev',
        },
        breakpoints: {
            768: {
                slidesPerView: 3,
            },
            480: {
                slidesPerView: 2,
            }
        }
    });
});
VOLKSWAGEN GOLF (2025)

VOLKSWAGEN 8 MY22 2.0 TSI GTI DSG

R 859 950
Range:
GOLF
Year:
2025
Mileage:
5 000km
Colour:
DOLPHIN GRAY METALLIC
Transmission:
AUTOMATIC
Fuel:
UNLEADED
Vehicle ID:
28510160
Available from Barons Cape Town
<?php
  $post_id = get_the_id();

   $custom_fields = get_post_meta($post_id);
echo $custom_fields['mmcode'][0] . '<br />';
  echo print_r($custom_fields);
    if (empty($custom_fields)) {
        error_log("No custom fields found for post ID: $post_id");
        return;
    }

    error_log("Custom fields for post ID $post_id:");

    foreach ($custom_fields as $key => $value) {
        // $value is always an array
        if (is_array($value)) {
            foreach ($value as $val) {
                error_log("$key => $val");
            }
        } else {
            error_log("$key => $value");
        }
    }
?>
Sales Enquiry

Similar Listings 

https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_1.jpg, https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_2.jpg, https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_3.jpg, https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_4.jpg, https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_5.jpg, https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_6.jpg, https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_7.jpg, https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_8.jpg, https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_9.jpg
VOLKSWAGEN
GOLF
(2019)

VOLKSWAGEN VII MY17 1.0 TSI BMT TRENDLINE (PA)

Array ( [vehicleid] => Array ( [0] => 28509889 ) [dumpdate] => Array ( [0] => 2025-11-03T15:53:51.757 ) [mmcode] => Array ( [0] => 64045401 ) [molstockbooknumber] => Array ( [0] => MOL01386_U0071210 ) [stockbooknumber] => Array ( [0] => U0071210 ) [vinnumber] => Array ( [0] => WVWZZZAUZKP051358 ) [regnumber] => Array ( [0] => CAA499048 ) [uploadtype] => Array ( [0] => USED ) [vehiclemake] => Array ( [0] => VOLKSWAGEN ) [vehiclerange] => Array ( [0] => GOLF ) [vehiclemodel] => Array ( [0] => VII MY17 1.0 TSI BMT TRENDLINE (PA) ) [vehicleyear] => Array ( [0] => 2019 ) [bodytype] => Array ( [0] => HATCH ) [transmissiontype] => Array ( [0] => MANUAL ) [fueltype] => Array ( [0] => UNLEADED ) [colour] => Array ( [0] => Refle Silver Metalli ) [numberofdoors] => Array ( [0] => 5 ) [mileage] => Array ( [0] => 50585 ) [servicehistory] => Array ( [0] => None ) [comments] => Array ( [0] => Barons Cape Town V&A Waterfront. Visit our dealership for a great selection used cars for sale. What you can expect when you purchase a Master Car - a long trusted Brand promise :80-Point Technical Inspection/24-Hour Roadside Assistance/Certified Mileage/Full-Service History, Optional 2-Year / Unlimited mileage. In house vehicle finance available. Chat to our team: Simphiwe Dyani Paul Zibi Daiyaan Edries Elrick Johnson Shamiel Nackerdien Front center armrest Park Distance Control Cruise control system Front fog lamps and cornering Mobile phone interface Lights + Vision package Radio "Composition Media ) [price] => Array ( [0] => 239950 ) [dealershipid] => Array ( [0] => 51 ) [molnumber] => Array ( [0] => MOL01386 ) [dealershipname] => Array ( [0] => Barons Cape Town ) [pictures] => Array ( [0] => a:9:{i:0;s:90:"https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_1.jpg";i:1;s:90:"https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_2.jpg";i:2;s:90:"https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_3.jpg";i:3;s:90:"https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_4.jpg";i:4;s:90:"https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_5.jpg";i:5;s:90:"https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_6.jpg";i:6;s:90:"https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_7.jpg";i:7;s:90:"https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_8.jpg";i:8;s:90:"https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071210_9.jpg";} ) [nmi_vehicle_id] => Array ( [0] => WVWZZZAUZKP051358 ) ) 1
WVWZZZAUZKP051358
WVWZZZAUZKP051358
Colour: Refle Silver Metalli
MOL01386
28509889

Enquire

Sales Enquiry
<?php
  $post_id = get_the_id();

   $custom_fields = get_post_meta($post_id);
echo $custom_fields['mmcode'][0] . '<br />';
  echo print_r($custom_fields);
    if (empty($custom_fields)) {
        error_log("No custom fields found for post ID: $post_id");
        return;
    }

    error_log("Custom fields for post ID $post_id:");

    foreach ($custom_fields as $key => $value) {
        // $value is always an array
        if (is_array($value)) {
            foreach ($value as $val) {
                error_log("$key => $val");
            }
        } else {
            error_log("$key => $value");
        }
    }
?>
R 239 950
50 585km
2019
MANUAL
More details
https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071211_1.jpg, https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071211_2.jpg
VOLKSWAGEN
GOLF
(2024)

VOLKSWAGEN 8 MY23 2.0 TSI R

Array ( [vehicleid] => Array ( [0] => 28509877 ) [dumpdate] => Array ( [0] => 2025-11-03T15:50:37.273 ) [mmcode] => Array ( [0] => 64045944 ) [molstockbooknumber] => Array ( [0] => MOL01386_U0071211 ) [stockbooknumber] => Array ( [0] => U0071211 ) [vinnumber] => Array ( [0] => WVWZZZCD3RW101768 ) [regnumber] => Array ( [0] => CRK946MP ) [uploadtype] => Array ( [0] => USED ) [vehiclemake] => Array ( [0] => VOLKSWAGEN ) [vehiclerange] => Array ( [0] => GOLF ) [vehiclemodel] => Array ( [0] => 8 MY23 2.0 TSI R ) [vehicleyear] => Array ( [0] => 2024 ) [bodytype] => Array ( [0] => HATCH ) [transmissiontype] => Array ( [0] => AUTOMATIC ) [fueltype] => Array ( [0] => UNLEADED ) [colour] => Array ( [0] => PURE WHITE ) [numberofdoors] => Array ( [0] => 5 ) [mileage] => Array ( [0] => 20500 ) [servicehistory] => Array ( [0] => Full ) [comments] => Array ( [0] => Why Choose Us?Full-Service History: All our pre-owned vehicles include a complete service record.80-Point Quality Check: Every vehicle is thoroughly inspected before delivery.Trade-Ins Welcome: Upgrade easily by trading in your current vehicle.Nationwide Delivery: We deliver anywhere in South Africa.Flexible Finance: Hassle-free in-house finance options available.Optional Value-Added Products (not included in listed price):Safety Film (Smash & Grab)Warranty ExtensionPaint ProtectionMaintenance Plan Extens R Performance exhaust system, Blind spot monitor with Rear Park assist Sound system Harman Kardon,300 W total Rear view camera Head-up display Adaptive Cruise Control IQ. Light - LED matrix MP 5Yr 100000km Pics to follow FSH ) [price] => Array ( [0] => 899950 ) [dealershipid] => Array ( [0] => 51 ) [molnumber] => Array ( [0] => MOL01386 ) [dealershipname] => Array ( [0] => Barons Cape Town ) [pictures] => Array ( [0] => a:2:{i:0;s:90:"https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071211_1.jpg";i:1;s:90:"https://bmrprodphotosuitestorage.blob.core.windows.net/stockimages/mol01386_u0071211_2.jpg";} ) [nmi_vehicle_id] => Array ( [0] => WVWZZZCD3RW101768 ) ) 1
WVWZZZCD3RW101768
WVWZZZCD3RW101768
Colour: PURE WHITE
MOL01386
28509877

Enquire

Sales Enquiry
<?php
  $post_id = get_the_id();

   $custom_fields = get_post_meta($post_id);
echo $custom_fields['mmcode'][0] . '<br />';
  echo print_r($custom_fields);
    if (empty($custom_fields)) {
        error_log("No custom fields found for post ID: $post_id");
        return;
    }

    error_log("Custom fields for post ID $post_id:");

    foreach ($custom_fields as $key => $value) {
        // $value is always an array
        if (is_array($value)) {
            foreach ($value as $val) {
                error_log("$key => $val");
            }
        } else {
            error_log("$key => $value");
        }
    }
?>
R 899 950
20 500km
2024
AUTOMATIC
More details