mirror of
https://github.com/YunoHost-Apps/limesurvey_ynh.git
synced 2024-09-03 19:36:32 +02:00
16 lines
336 B
PHP
16 lines
336 B
PHP
|
<?php
|
||
|
if($file->type==='php')
|
||
|
{
|
||
|
echo '<div class="content">';
|
||
|
highlight_string($file->content);
|
||
|
echo '</div>';
|
||
|
}
|
||
|
elseif(in_array($file->type,array('txt','js','css')))
|
||
|
{
|
||
|
echo '<div class="content">';
|
||
|
echo nl2br($file->content);
|
||
|
echo '</div>';
|
||
|
}
|
||
|
else
|
||
|
echo '<div class="error">Preview is not available for this file type.</div>';
|
||
|
?>
|