Forum perms shortcode templatization#5384
Conversation
|
|
||
| return implode("<span class='forum-perms-separator'><!-- --></span>", $permDisplay); | ||
|
|
||
| global $FORUM_VIEWFORUM_TEMPLATE; |
There was a problem hiding this comment.
Using global is very PHP5. Please load the template. It can be done in the construct()
There was a problem hiding this comment.
It's the way the forum code is written. The template is already loaded in the main forum_view.php code, and for me it was a overload to load the template twice...
There's another way to do it. Pass the template via sc var, but that would require rewrite the main php file code....
Anyway all the forum code needs a major rewrite, it's poorly programmed...
If i'm allowed, i can do it...
There was a problem hiding this comment.
Yeah, for quite some time I've been considering a rewrite from scratch of the forum plugin but while still keeping the same database structure.
We could start a rewrite as a new plugin in a separate repository. Then at some point it can be merged into core.
|
Code Climate has analyzed commit ccf3c5b and detected 0 issues on this pull request. The test coverage on the diff in this pull request is 100.0% (80% is the threshold). This pull request will bring the total coverage in the repository to 48.9% (0.0% change). View more on Code Climate. |
Motivation and Context
Remove harcoded HTML form PERMS forum shortcode
Description
Moved embebed HTML to template
How Has This Been Tested?
Tested in latest Github e107 code
Types of Changes
Checklist