MyBB Community Forums

Full Version: What does 'eval' do?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
What does eval do?
I mean how is it asociated with the template system?
http://uk.php.net/eval

Should explain all you need to know.
When something from templates get evaluated(eval) does it get printed or you have to print it with print("....?
Is it a whole new page ? Or just a piece you've added to be used in a existing template ?
If its a new page;
eval("\$new_page = \"".$templates->get("NEW_PAGE_TEMPLATENAME")."\";");
output_page($new_page);

Else you just need to use the $var in your existing template; in this example {$new_page}
Please explain a bit more
Please stick with one thread for asking similar questions.

The 'eval' parses the template variables. To output it, you need to print it out separately, either using print, echo, or MyBB's output_page
Ok
#offtopic
Where did my other topic go?
*Looks at thread notes*

Dennis merged them.