2014-04-13 09:38:15 +03:00

16 lines
329 B
PHP
Executable File

<?php
$output_dir = dirname(__DIR__).'/html/';
$content_dir = (__DIR__).'/content/';
$template = (__DIR__).'/template.php';
$files = scandir($content_dir);
foreach($files as $file)
{
if($file[0] !== '.')
{
$output_file = $output_dir . str_replace('.php', '.html', $file);
exec("php $template $file > $output_file");
}
}