";
echo message('MODIFY_CONFIG')." config.php
";
exit;
}
$i = 0;
foreach($ps as $pres_id=>$filename) {
$fh = fopen($filename, "rb");
$p = new XML_Presentation($fh);
$p->setErrorHandling(PEAR_ERROR_TRIGGER, E_USER_WARNING);
$check = $p->parse();
if ($p->isError($check)) {
continue;
}
$pres = $p->getObjects();
// Do we have a generated reveal.js version of this presentation?
if(file_exists(substr($filename,0,strrpos($filename,'.')).".html")) {
$pr[$i]['generated'] = basename(substr($filename,0,strrpos($filename,'.')));
} else {
$pr[$i]['generated'] = false;
}
$pr[$i]['id'] = $pres_id;
$pr[$i]['slidecount'] = count($pres[1]->slides ?? []);
$pr[$i]['title'] = $pres[1]->title;
if(isset($pres[1]->date)) {
$tmp = strtotime($pres[1]->date);
if($tmp==-1) {
$pr[$i]['date'] = $pres[1]->date;
} else {
$pr[$i]['date'] = date('M j, Y',$tmp);
}
} else $pr[$i]['date'] = ' ';
if(isset($pres[1]->speaker)) {
$pr[$i]['speaker'] = $pres[1]->speaker;
} else $pr[$i]['speaker'] = ' ';
if(isset($pres[1]->topic)) {
$pr[$i]['topic'] = $pres[1]->topic;
if(!empty($pres[1]->topic)){
if(!isset($topics[$pres[1]->topic]['count'])) $topics[$pres[1]->topic]['count'] = 0;
$topics[$pres[1]->topic]['count']++;
}
} else $pr[$i]['topic'] = ' ';
if(isset($pres[1]->location)) {
$pr[$i]['location'] = $pres[1]->location;
} else $pr[$i]['location'] = ' ';
if(isset($pres[1]->company)) {
$pr[$i]['company'] = $pres[1]->company;
} else $pr[$i]['company'] = ' ';
$i++;
}
unset($pres);
// default options for the file.
$p = new XML_Presentation(fopen("index.xml", "rb"));
$p->setErrorHandling(PEAR_ERROR_TRIGGER, E_USER_WARNING);
$check = $p->parse();
if ($p->isError($check)) {
die("Could not parse index.xml, not sure what to do");
}
$pres = $p->getObjects();
$pres = $pres[1];
$HEAD_RAND = <<'."\n");
$col = 0;
if (!isset($topic_cols) || $topic_cols == 0) {
$topic_cols = 2;
}
$percent = (int)(100 / $topic_cols);
foreach($topics as $i => $topic) {
printf(' \n' . $i . ' (' . $topic['count'] . ') '."\n", $percent, urlencode($i));
if (++$col >= $topic_cols) {
$col=0;
print("");
}
}
print(' ');
} else {
if(empty($_COOKIE['display_mode'])) { $display_mode = 'html'; $form_speaker='false'; }
else {
list($display_mode,$form_speaker) = explode('|',$_COOKIE['display_mode']);
}
$_SESSION['show_speaker_notes'] = ($form_speaker=='true');
$_SESSION['selected_display_mode'] = $display_mode;
// flags for extensions
if (!extension_loaded('ming')) {
$flag_ext_ming = false;
} else {
$flag_ext_ming = true;
}
if (!extension_loaded('pdf')) {
$flag_ext_pdf = false;
} else {
$flag_ext_pdf = true;
}
?>
".nl2br(message('HTML_KEYBOARD_CONTROLS'))."
".message('HTML_NO_KEYBOARD_CONTROLS')."
\n"; break; } break; case 'flash': echo "".nl2br(message('FLASH_KEYBOARD_CONTROLS'))."
\n"; break; } ?>| {$pr[$j]['title']} | {$pr[$j]['date']} | {$pr[$j]['location']} | {$pr[$j]['speaker']} | {$pr[$j]['slidecount']} | "; } else { echo "
| {$pr[$j]['title']} | {$pr[$j]['date']} | {$pr[$j]['location']} | {$pr[$j]['speaker']} | {$pr[$j]['slidecount']} |
| {$pr[$j]['title']} | {$pr[$j]['date']} | {$pr[$j]['location']} | {$pr[$j]['speaker']} | {$pr[$j]['slidecount']} |