I have inherited a SilverStripe project that I am cleaning up. Ext JS is used and therefor included in multiple pages. I would like to load the script along with other common requirements in Page.php, as other pages inherit from here. In code I have
This produces in <head>
but extjs.js doesn't seem to load, e.g. "flyout" menus depending on it don't appear
If I include extjs.js directly in code with
this produces in <head>
which does work.
Though I have a "workaround" I am trying to understand SilverStripe and http/html better. So I would like to understand the problem before deciding how to structure this site. Can someone explain the difference in behavior? Thanks!