Add custom advertisement (in HTML format) on every user's web page automatically

akymakr

Verified User
Joined
Oct 15, 2011
Messages
20
Location
Hong Kong
Some of the free web hosting providers may gain money from the sponsor advertisements such as Google Adsense. But, not every user will put the advertisement that we gave the code to them, and we suspended them. If there is a way from DirectAdmin to let admin / reseller make a custom advertisement HTML code to control the user's web page to add our advertisement to make sure that every pages have our advertisement but not changing the user's source HTML code.
 
Every skin has a separate "header" and "footer" file, use them to show your code. Take care to protect them against being overwritten with a DA update.
 
This could be done through either .htaccess code (which you could chattr so your clients can't change it, though this would severely limit other functionality supplied by .htaccess.

Another way to do it would be to make changes to httpd.conf include files. You can make customizations to the templates which would make their way into the installed user-level httpd.conf file.

The actual code to use? I have no idea. If you don't know, perhaps someone else will.

Jeff
 
Back
Top