aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes
Commit message (Collapse)AuthorAgeFilesLines
...
| | * | | | | | | | | [feature/template-engine] Corrected an error message in template locator.Oleg Pudeyev2011-08-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Remaining documentation.Oleg Pudeyev2011-08-077-1/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] More documentation for template class.Oleg Pudeyev2011-08-071-8/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Create load_and_render to reduce code duplication.Oleg Pudeyev2011-08-071-7/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Get rid of orig_tpl_* in template engine.Oleg Pudeyev2011-08-042-68/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The origins of orig_tpl_* are not pretty. Please see the following commits and associated tickets: r9823, r9839, r9847, r10150, r10460. In short, multiple hacks were required due to template engine reading inheritance/storedb flags from $user (global) even when the template that was being looked up or rendered was not the "active style of the current user". We no longer store templates in the database, removing half of the problem. This commit fixes the second half of the problem by deleting set_template_path function from template locator, and moving that logic back into the template class' set_template. set_template now calls set_custom_template, the latter only taking the template path and the fallback paths as parameters. With this change template locator no longer uses $user and does not use phpbb root path either. All logic involving setting the user's "active" template is now encapsulated in a single template class's function, set_template. Setting other templates is done via set_custom_template and the caller is responsible for determining and passing in fallback/inheritance path, if any. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Delete $style_name param from locator's ↵Oleg Pudeyev2011-08-042-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | set_custom_template. This parameter was unused, it was only used by template's set_custom_template to determine cache file prefix. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Add constructor to template locator.Oleg Pudeyev2011-08-042-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Factor template locator out of template class.Oleg Pudeyev2011-07-302-118/+283
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Template locator is responsible for maintaining mapping from template handles to filenames and paths, and provides resolution services using these mappings. Template locator is aware of template inheritance and is capable of checking template file existence on the filesystem. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Delete $files_template property.Oleg Pudeyev2011-07-301-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This seems to have been used for db storage of templates. We no longer offer db storage of templates, and thus currenty $files_template is only written to but not read anywhere. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Rename is_absolute to phpbb_is_absolute.Oleg Pudeyev2011-07-242-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Docblocks, no more constructor for filterIgor Wiedler2011-07-161-6/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add docblocks for phpbb_template_filter, remove the useless constructor. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Add ampersands to return refs by reference.Oleg Pudeyev2011-07-101-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Delete useless assignment by reference for $lang.Oleg Pudeyev2011-07-102-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Remove $include_once argument of display()Igor Wiedler2011-07-101-9/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Refactor $config dependency out of the filterIgor Wiedler2011-07-103-10/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The template stream filter no longer depends on the $config global. Instead it uses a 'allow_php' param that is passed via stream_bucket_append's last argument. Tests also adjusted. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Fix some commentsIgor Wiedler2011-07-102-15/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Move template.php to includes/templateIgor Wiedler2011-07-101-0/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows making use of autoloading. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Fixed absolute path PHP includes, added test.Oleg Pudeyev2011-05-191-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Delete @version everywhere.Oleg Pudeyev2011-05-147-7/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is not used since the switch to git. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Moved phpbb_template_filter into own file.Oleg Pudeyev2011-05-142-831/+848
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Delete @access everywhere.Oleg Pudeyev2011-05-143-36/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Access specification in php 5 is done directly on functions/properties. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Make INCLUDEPHP relative to board root.Oleg Pudeyev2011-05-122-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Replaced globals with dependency injection.Oleg Pudeyev2011-05-122-37/+60
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Clarify cache directory path for set_custom_templateOleg Pudeyev2011-05-121-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Even if the template may be outside of phpBB, phpBB's cache directory is still going to be used for storing compiled template code. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Try to handle failed template includes.Oleg Pudeyev2011-05-121-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Rename $filename to $compiled_path for clarity.Oleg Pudeyev2011-05-121-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Move DEBUG_EXTRA check for $recompile up.Oleg Pudeyev2011-05-121-14/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Deleted useless assignment.Oleg Pudeyev2011-05-121-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Added docblocks to get_*_ref in context.Oleg Pudeyev2011-05-121-0/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Fixed reference usage.Oleg Pudeyev2011-05-123-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Hopefully this is right, I have not checked it against the manual (assuming the manual even covers these things). PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Disposed of underscores in property names.Oleg Pudeyev2011-05-122-32/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Remove commented out error reporting logic.Oleg Pudeyev2011-05-121-10/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Refactor hook logic into a separate function.Oleg Pudeyev2011-05-121-7/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Reinstate phpbb_template#destroy function.Oleg Pudeyev2011-05-121-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Add back IN_PHPBB preamble.Oleg Pudeyev2011-05-121-1/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Moved template classes to subdirectory.Oleg Pudeyev2011-05-085-0/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Renamed template executor and friends to renderer.Oleg Pudeyev2011-05-084-33/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Added docblocks and boilerplate to new files.Oleg Pudeyev2011-05-074-0/+76
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Removed more dead code.Oleg Pudeyev2011-05-071-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Added phpbb_template_context class.Oleg Pudeyev2011-05-076-246/+367
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Objects of this class hold variables assigned to templates. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Always call ob_end_clean.Oleg Pudeyev2011-05-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We have to stop output buffering even when rendering fails. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Removed some dead code.Oleg Pudeyev2011-05-041-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Split template execution logic into classes.Oleg Pudeyev2011-05-044-63/+123
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Template executor interface defines a template executor object. It is an object which can execute (i.e. display/render) a template. Currently there are two implementations: * phpbb_template_executor_include includes php code from a file. * phpbb_template_executor_eval eval's php code. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Removed storedb-related logic.Oleg Pudeyev2011-05-041-124/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | phpBB 3.1 will not provide the option to store templates in the database. This commit removes code that handles templates stored in database from the template engine. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Delete template class, use phpbb_template instead.Oleg Pudeyev2011-05-042-10/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Rename template_compile methods for clarity.Oleg Pudeyev2011-05-042-11/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Extracted compile_stream_to_stream.Oleg Pudeyev2011-05-011-4/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Close output stream in compile().Oleg Pudeyev2011-05-011-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is no need to leave the stream to the garbage collector, and the amount of data stuck in it may be substantial. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Fixed description of assign_display().Oleg Pudeyev2011-05-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This function returns false on failure, which can happen if display() failed. Document the failure return value. PHPBB3-9726
| | * | | | | | | | | [feature/template-engine] Check return value of display() in assign_display().Oleg Pudeyev2011-05-011-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If display() failed, propagate the failure out of assign_display(). PHPBB3-9726