If you were housing them in a database of some kind then I would add a unique id to the particular ad. Without trying to program some sematics indexing since as Prowler suggested its pretty difficult, you probably have a pretty good idea of the kind of visitor each site attracts and the target demographics. I would try something along the lines of a lookup table like he's suggested. Categorize each one of the text based ads based on those keys like age, sex etc. and then assign each ad a number. As an example, #1 could be ads for a site that attracts young males in the 20-30 range. Then all you do is create a nice peice of working code that pulls ads from the database to display them at random. All you would have to do is slightly modify the code for each site. What you might do is write a separate inclusion class so that you just modify that one section for each site. Without creating some kind of ranking system for the ads like scoring them on a number of characteristics I don't think you can get much simpler. You could also add in specific numbers for each site, so that lets say #1 displays ads for young males and #16 would only be shown on a specific site. Just a thought.
|