At work I wrote many classes/function that are hundreds of lines of code. This code rarely changes, but it does happen. Some of this code is also used in all 4 of the sites.
Problem right now is I have "4 sites" with duplicate code on them (copy/pasted). All on a single server running IIS. How can set this up so all 4 sites "share" the same PHP code?
My temporary "dirty" fix to this has been to: Setup a 5th site in IIS. Setup a firewall rule to block any access to it, then rename all my PHP files to ".txt" files then simple do "require "somePHPcode.txt" (this way IIS wont "run them" before sending them).
This works, but its not very elegant. Got a better method?