Lack of interest Javascript Includes

This suggestion has been closed automatically because it did not receive enough votes over an extended period of time. If you wish to see this, please search for an open suggestion and, if you don't find any, post a new one.

Cory Booth

Well-known member
I was thinking,

It would be nice to have an area to designate specific javascript you would want loaded - and then specifiy what page or even what module you want the javascript loaded with.

Say an area in admin:
File: somejava.js
Page: index.php

File: someotherjava.js
Page: members.php

etc...

This could cut down some of the edits to templates to accomidate add-ons and also cut down on javascripts for those pages that don't need it - as many folks just put all the javascript calls in the footer or something and it loads on every page.
 
Upvote 0
This suggestion has been closed. Votes are no longer accepted.
As long as addon's can add the JS via a PHP call it won't be a problem...

So to take an example from modx CMS

Code:
$modx->regClientJS('http://somedomain.com/somejsfile.js');

Would automatically add the JS to the header when it is called by the plugin.
 
As long as addon's can add the JS via a PHP call it won't be a problem...

So to take an example from modx CMS

Code:
$modx->regClientJS('http://somedomain.com/somejsfile.js');

Would automatically add the JS to the header when it is called by the plugin.

I'm not familiar with Modx - but yeah, that is pretty much what I am saying.
Right now with VB I am including java with plugins:
1 so I don't have to reedit templates and
2 so I can control when they load (i.e. this_script = blah blah)
 
I'm not familiar with Modx - but yeah, that is pretty much what I am saying.
Right now with VB I am including java with plugins:
1 so I don't have to reedit templates and
2 so I can control when they load (i.e. this_script = blah blah)

Modx has been my full featured CMS of choice for a while, it is very powerful and can also be really easy to use as an application framework as well for quick deployment... The latest codebase is very much MVC like xenForo.
 
Top Bottom