28 lines
613 B
PHP
28 lines
613 B
PHP
<?php
|
|
|
|
require dirname(__FILE__).'/common.php';
|
|
|
|
$cwd = dirname(__FILE__);
|
|
|
|
$m = setup_mustache();
|
|
|
|
$tpl = $m->loadTemplate('public/cv');
|
|
|
|
$cv_sec = [ "short" , "grants", "responsabilities", "outreach" ];
|
|
$cv_rst = array();
|
|
|
|
$parser = new Doctrine\RST\Parser();
|
|
|
|
foreach ($cv_sec as $sec) {
|
|
$fname = "{$cwd}/cv/{$sec}.rst";
|
|
$handle = fopen($fname, "r");
|
|
$cv_rst[$sec] = $parser->parse(fread($handle, filesize($fname)))->render();
|
|
fclose($handle);
|
|
}
|
|
|
|
$cv_rst['ROOT_URL'] = $iap_root;
|
|
$cv_rst['title'] = 'Guilhem Lavaux\'s CV';
|
|
|
|
header('Content-Type: text/html; charset=utf-8');
|
|
echo $tpl->render($cv_rst);
|