So basically, if you have 4 separate websites (could be hosted on the same or separate servers) and each website uses the same class (e.g. Swiftmailer, RSS, security, etc.). If in future, I need to upgrade these classes for reasons like bug fixes, improvements, etc., I would need to remember to deploy the classes for each website.
My thoughts:
- Develop a mySQL database to contain all client details including their web URLs, etc.
- Develop a "master" website (e.g. non-client)
- Add all relevant assets to a specific folder (e.g. "client_assets")
- On each client website, instead of doing an include_once, use cURL or something similar to load in now-external required files
- The database on the master website could be used to check where the request is coming from
So if I need to replace or upgrade a class, I just need to do it once on the master website.
What are your thoughts?