Nullified
02-06-2005, 01:41 PM
I have several pieces of code that are exactly the same on mutiple pages of my site and I would like to store the multiple lines of code in an external source such as mysql or another file and include the source in my documents. This way I will only need to change the code once and it will span across all my pages. By utilizing php's include method I could make the original requested webpage much smaller, however if the included code is within another file the total download process will still be larger then wanted. Thus, I was thinking of using mysql to store the code as I assume it would be faster for the user and less of a download. Am I correct? If so what kind of database/table would I need to store the code in to ensure proper spacing of the code? Sorry, but I'm not that fluent with mysql atm. If any experts can give me some feedback on this I wold greatly appreciate it. Is what I'm doing even worth it as far as performance for visitors?
