J3 Issue ?
avatar ranggasito
ranggasito
4 Apr 2019

Is your feature request related to a problem? Please describe.

I'am trying to remove scriptOptions from JDocument but it's protected property so I can't remove or disable it. I need to build joomla in amp format, so it's not allowed in amp format to add scripts except from amp source.

Describe the solution you'd like

I think Joomla should support html document type in AMP version

Additional context

image

avatar ranggasito ranggasito - open - 4 Apr 2019
avatar joomla-cms-bot joomla-cms-bot - change - 4 Apr 2019
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 4 Apr 2019
avatar mbabker
mbabker - comment - 4 Apr 2019

Your template is in the scope of the Document class chain, so you can $this->scriptOptions = []; all you want and take the risk of breaking something along the way. You're right there isn't a setter to just overwrite the property from outside, and making it public isn't the fix for that (it's wrong that there are so many public properties on the class in the first place but the time to fix that was in 2011, trying to fix it in 2019 is API suicide at this point).

avatar franz-wohlkoenig franz-wohlkoenig - change - 4 Apr 2019
Status New Information Required
avatar franz-wohlkoenig franz-wohlkoenig - change - 4 Apr 2019
Category Feature Request Templates (site)
avatar franz-wohlkoenig franz-wohlkoenig - change - 4 Apr 2019
Labels Added: J3 Issue
avatar franz-wohlkoenig franz-wohlkoenig - labeled - 4 Apr 2019
avatar brianteeman
brianteeman - comment - 6 Apr 2019

This should be closed. There are extensions available that provide amp support and/or you can use the method described by @mbabker

avatar franz-wohlkoenig
franz-wohlkoenig - comment - 6 Apr 2019

Closed as stated above.

avatar franz-wohlkoenig franz-wohlkoenig - close - 6 Apr 2019
avatar franz-wohlkoenig franz-wohlkoenig - change - 6 Apr 2019
Status Information Required Closed
Closed_Date 0000-00-00 00:00:00 2019-04-06 18:08:46
Closed_By franz-wohlkoenig

Add a Comment

Login with GitHub to post a comment