includes/render.php
changeset 1157 e154e8176700
parent 1123 777f32ac6b7c
child 1171 d42d46e13b36
equal deleted inserted replaced
1156:417e66a664d0 1157:e154e8176700
   927     foreach ( $code as $cmd )
   927     foreach ( $code as $cmd )
   928     {
   928     {
   929       eval($cmd);
   929       eval($cmd);
   930     }
   930     }
   931     
   931     
   932     $can_do_php = ( $session->get_permissions('php_in_pages') && !$strip_all_php );
   932     $can_do_php = ( !$strip_all_php && $session->get_permissions('php_in_pages') );
   933     $can_do_html = $session->get_permissions('html_in_pages');
   933     $can_do_html = $session->check_acl_scope('html_in_pages', $paths->namespace) && $session->get_permissions('html_in_pages');
   934     
   934     
   935     if ( $can_do_html && !$can_do_php )
   935     if ( $can_do_html && !$can_do_php )
   936     {
   936     {
   937       $text = preg_replace('#<(\?|\?php|%)(.*?)(\?|%)>#is', '&lt;\\1\\2\\3&gt;', $text);
   937       $text = preg_replace('#<(\?|\?php|%)(.*?)(\?|%)>#is', '&lt;\\1\\2\\3&gt;', $text);
   938     }
   938     }