The insert and execute arbitrary code can be accomplished by creating your own template tag.
To do this in the folder themes/functions add another file. For example, show_my_code.php.
Example:
<?php
if (! defined('DIAFAN'))
{
$path = __FILE__; $i = 0;
while(! file_exists($path.'/includes/404.php'))
{
if($i == 10) exit; $i++;
$path = dirname($path);
}
include $path.'/includes/404.php';
}
echo 'DIAFAN.CMS';
To code within a method has executed, deduce template tag in a single file from the folder themes. As a rule, it is site.php:
<insert name="show_my_code">
Now the code file show_my_code.php will connect each time the template pages of the site is a file site.php. In our case, it will be shown "DIAFAN.CMS".
The tag can also be inserted in the visual editor, for this you need to select the button "Edit HTML-code" (the first visual editor button).