create ADS.js basic function