I have two options:
One is to use an external javascript file sitting on a centeralized server. This external javascript file would pull in additional configuration files, also sitting on the server, that are related to the page URL (and additional personalization parameters) requesting the javascript file.
Code: Select all
<script type="text/javascript" src="http://central_server.com/external_file.js"></script>Code: Select all
<script type="text/javascript" src="http://central_server.com/external_script.php?site_id=3"></script>How much additional load time (insignificant, moderate, signifiant) will the php option require?
- If it uses xml files (on the php server) for configuration data
- If it uses MySQL database for configuration data
Obviously using the PHP enable some of my content serving logic to be cloaked compared to javascript. Plus changes and updates would be much easier to manage compared to constantly generating and regenerating the javascript files...but is it worth it.
Thanks