function guiFormatPage(&$session, $mime, $content) { $session->trace(TC_Gui2, 'guiFormatPage'); switch ($mime) { case TT_Wiki: case M_Wiki: wikiToHtml($session, $content); break; case TT_HTML: case M_HTML: echo $content; break; case TT_Text: case M_Text: echo TAG_PRE; textToHtml($session, $content); echo TAG_PRE_END; default: wikiToHtml($session, $content); break; } }
function guiParagraph(&$session, $text, $convert) { $session->trace(TC_Gui2, 'guiParagraph'); echo '<p>'; if ($convert) { echo textToHtml($text); } else { echo $text; } echo "</p>\n"; }
function dumpVars($header) { $this->Write("HTTP_POST_VARS: {$header}"); foreach ($_POST as $name => $val) { $this->Write($name . ": " . textToHtml($val) . TAG_NEWLINE); } }
function modUserCheckData(&$session, $isnew, $id) { $rc = ""; InitModules($session); foreach ($session->fModules as $name => $module) { $msg = $module->userCheckData($session, $isnew, $id); if ($msg != null) { $rc .= textToHtml($msg) . "<br>\n"; } } return empty($rc) ? null : $rc; }
<?php //Display Page for getting documents echo "<a href='" . $documentFilePaths['zip'] . "' target='_blank'>Hämta protokoll och samtliga bilagor som ZIP</a><br>"; echo "<a href='" . $documentFilePaths['Protokoll'] . "' target='_blank'>Hämta protokoll som ODT</a><br>"; echo "<a href='view.php?ID=" . $currentSeed . "' target='_blank'>För att visa protokollet i efterhand.</a><br>"; $htmlDataString = ""; foreach ($rawDataArray as $key => $value) { if (trim($value) == "") { unset($rawDataArray[$key]); } else { //$txt = textToHtml($value); //echo htmlspecialchars(textToHtml($value)) . "<br>"; echo textToHtml($value) . "<br>"; $htmlDataString = $htmlDataString . textToHtml($value) . "<br>"; } } //Generate Config File //Declare variables that are supposed to be saved in the config $cfgArray = array($documentFilePaths['zip'], $documentFilePaths['Protokoll'], $htmlDataString, $meetingChairperson, $meetingSecretary, $meetingAdjustor1, $meetingAdjustor2); //Create Config File $cfgFile = fopen($meetingFolder . "cfg.php", "w") or die("Error creating file!"); fwrite($cfgFile, "<?php "); $counter = 0; foreach ($cfgArray as $key => $value) { fwrite($cfgFile, "\$" . "cfgVar" . $counter . ' = "'); fwrite($cfgFile, $value); fwrite($cfgFile, '";'); $counter++; } fwrite($cfgFile, "?>");