Are there any alternative methods in PHP to preload images for users without active JavaScript?

When users have JavaScript disabled, the typical method of preloading images using JavaScript may not work. One alternative method in PHP is to output the image tags directly in the HTML with the "preload" attribute set to "auto". This will instruct the browser to preload the images when the page is loaded.

<?php
// Array of image URLs to preload
$images = array('image1.jpg', 'image2.jpg', 'image3.jpg');

// Output image tags with preload attribute
foreach($images as $image) {
    echo '<img src="' . $image . '" style="display: none;" preload="auto">';
}
?>