';
// and add it to the output string
if( !($ubb_ispdfcreate))
{
$outstr = $selectorstr . $outstr;
}
// and remove the neters from the output string
$outstr = str_replace(chr(13), '', $outstr);
$outstr = str_replace(chr(10), '', $outstr);
$outstr = str_replace('', "\r\n", $outstr);
// replace the sectionlist
$outstr = str_replace('[sectionlist]', getSectionListString($spec), $outstr);
// and remove slashes
$outstr = stripslashes($outstr);
// and dispaly it
$tmpout .= '
' . $outstr . '
';
$tmpparsed = $outstr;
// and display some seperating stuff
$tmpout .= '!
';
// add some norml stuff to prevent it from being parsed by the forum
if( !($ubb_ispdfcreate))
{
$outstr = '[norml]' . $outstr . '[/norml]';
}
// now give the result in an edit box, ready to be pasted
$tmpout .= '';
// create an temporary filename
$tmpname = time();
// and replace the output
$tmpcmd = PDFCONVERTER;
$tmpcmd = str_replace('$@outfile@$', PDFTEMPNAME . $tmpname . '.pdf', $tmpcmd);
$tmpcmd = str_replace('$@infile@$', PDFTEMPNAME . $tmpname . '.html', $tmpcmd);
// create the temporary html file
WriteFile(PDFTEMPNAME . $tmpname . '.html', $outstr);
// create the ubb file
WriteFile(PDFTEMPNAME . $tmpname . '.ubb', $tmpstr);
// show the processing time
if( !($ubb_ispdfcreate))
{
// echo '
Processing time: ' . $endtime - $starttime . '
';
}
// show the user the urls
$tmpout .= '' . $tmpname . '.html -- Print HTML versie ';
$tmpout .= '' . $tmpname . '.ubb -- UBB (input) versie ';
// show the user we are creating an pdf
if( $ubb_ispdfcreate)
{
$tmpout .= 'Aanmaken PDF - dit kan een tijdje duren - ze zijn straks te vinden op onderstaande lokatie (dit kan tot 15 minuten duren!) ';
$tmpout .= '' . $tmpname . '.pdf -- PDF versie ';
// flush output
flush();
// and run the pdf thingie
shell_exec($tmpcmd);
// and show were done
$tmpout .= "Done ...";
}
return Array('out' => $tmpout, 'parsed' => $tmpparsed);
}