core html helper clasess extends core helper classes

Permalink 43 43 Browser Info Environment
https://github.com/concrete5/concrete5/blob/master/web/concrete/core/helpers/html.php#L251

The three core output objects should be extending the "non-core" HeaderOutputObject.


Status: Minor

Still Valid:

This bug is valid a newer version of concrete5. View Current Bug
jshannon
mkly replied on at Permalink
mkly
mkly replied on at Permalink
mkly
The fix throws fatal error because each file then depended on the other file. Chicken and the egg.

The real fix will be more complicated I fear so I reverted it for now.
jshannon replied on at Permalink
jshannon
Shouldn't this be as "simple" as moving them to separate file(s) and then using the Loader to include them?
mkly replied on at Permalink
mkly
Maybe a pull request might explain it better?
jshannon replied on at Permalink
jshannon
I don't have an environment set up to do PRs.

But currently you have helpers/html.

Code (my code and other code) does Loader::helper('html');

In the super-complex and super-extensible world, you would have, at the top of helpers/html:

Loader::model('output/css');
Loader::model('output/javascript');
Loader::model('output/inline');


Each one of those would have:

Loader::model('output/parent'); // or whatever


So, html helper gets loaded. Before it instantiates anything, the others are loaded. If you consider 4 new files as overkill and too complex, they could be collapsed into fewer.

concrete5 Environment Information

github

Browser User-Agent String

Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_8) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.95 Safari/537.36