Here's two methods to display html output: function vs include. Is there a performance hit when accessing the file system as opposed to accessing memory? If each page load has dozens, or even hundreds of includes, at what point does this become a problem?
Option 1: Html display loop using a function
foreach ($items as $item){
displayItem($item);
}
function displayItem($item){ ?>
<html output>
<?php }
Option 2: Html display loop using include
foreach ($items as $item){
include $path . 'displayItem.php';
}
//inside displayItem.php:
<html output>
includemechanism itself that matters, rather than FS performance.