Merge commit 'catalyst/MOODLE_19_STABLE' into mdl19-linuxchix
[moodle-linuxchix.git] / filter / tex / displaytex.php
blobd352f853aa31cd391adc78dc5790dc012c37b562
1 <?php // $Id$
2 // This script displays tex source code.
4 require_once('../../config.php');
6 $texexp = urldecode($_SERVER['QUERY_STRING']);
7 // entities are usually encoded twice, first in HTML editor then in tex/filter.php
8 $texexp = html_entity_decode(html_entity_decode($texexp));
9 // encode all entities (saves non-ISO)
10 $texexp = htmlentities($texexp,ENT_COMPAT,'utf-8');
12 <html>
13 <head>
14 <title>TeX Source</title>
15 <meta http-equiv="content-type" content="text/html; charset=utf-8" />
16 </head>
17 <body bgcolor="#FFFFFF">
18 <?php echo $texexp; ?>
19 </body>
20 </html>