Das Google AdManager Matching erlaubt es, dass sich AdSpirit direkt an Werbeflächen anhängt die vom Google AdManager (GAM; ehemals Google DFP) auf einer Seite definiert sind und die von GAM nicht befüllt wurden.
Ablauf
- Binden Sie das Google AdManager Matching Script in Ihre Webseite ein. Die Einbindung sollte möglichst früh im Webseitencode passieren.
- Das Script wird sich an alle von GAM in der Seite definierten Slots anhängen und darauf warten ob diese von GAM gefüllt werden.
- Wird ein Slot nicht befüllt, wird das Matching Script nach einer passenden AdSpirit-Werbefläche suchen und diese an Stelle des GAM slots einfügen.
Setup
Binden Sie den Google AdManager Matching Code wie folgt ein:
<script>
window.asm_host = 'delivery.youradserver.com';
window.asm_cdn = 'cdn.youradserver.com';
window.asm_wsid = '123';
window.asm_global_params = ''; //optional additional parameters to be added to each placment script
</script>
<script src="//cdn.youradserver.com/adasync.min.js" async type="text/javascript"></script>
<script src="//cdn.youradserver.com/adgtp.min.js" async type="text/javascript"></script>
Konfiguration
Per default ist der Code auf automatische Konfiguration eingestellt. Dabei wird das Script automatisch GAM slots suchen und automatisch passende AdSpirit Werbeflächen zuordnen. Wenn Sie stattdessen eine manuelle Zuordnung möchten, verwenden Sie bitte die Variable window.asm_gtp_options:
//disable autodetection for slots:
window.asm_gtp_options.isAutoDetectSlots = false;
//disable autodetection for mappings:
window.asm_gtp_options.isAutoDetectMappings = false;
//set GAM slots that should be added (use GAM slot path):
window.asm_gtp_options.addSlots = ['/123/myslot1','/123/myslot2];
//alternative, set GAM slots that should be added (use GAM slot path):
window.asm_gtp_slots = window.asm_gtp_slots || [];
window.asm_gtp_slots.push('/123/myslot1');
//set mappings that should be added (use GAM slot path):
window.asm_gtp_options.addMappings = [{'query':'/123/myslot1','pid':'789','params':'&target=123'}];
//alternative, set mappings that should be added (use GAM slot path):
window.asm_gtp_mappings = window.asm_gtp_mappings || [];
window.asm_gtp_mappings.push({'query':'/123/myslot1','pid':'789','params':'&target=123'});
window.asm_gtp_mappings.push({'query':'mywebsite_leaderboard3','pid':'789','params':'&target=123'});
window.asm_gtp_mappings.push({'query':'myDivForPlacement','pid':'789','params':'&target=123'});
Mapping
Das Mapping, also die Zuweisung von GAM Slots zu AdSpirit Werbeflächen geschieht für jeden GAM Slot auf die folgende Weise:
- Übereinstimmung von Mapping-Suche (query) mit exakter Slot-ID (path#div#size)
- Übereinstimmung von Mapping-Suche (query) mit exakter Slot-ID (path#div)
- Übereinstimmung von Mapping-Suche (query) mit Slot-ID (path)
- Übereinstimmung von Mapping-Suche (query) mit Slot-Name (Teil des Path nach dem letzten / )
- Übereinstimmung von Mapping-Suche (query) mit Slot-DIV (div)
- (Wenn Autodetection aktiv) Übereinstimmung von Slot-Name mit AdSpirit Werbeflächenname
- (Wenn Autodetection aktiv) Übereinstimmung von Slot-Name mit alternativem AdSpirit Werbeflächenname
- (Wenn Autodetection aktiv) Übereinstimmung von Slot-DIV mit AdSpirit Werbeflächenname
- (Wenn Autodetection aktiv) Übereinstimmung von Slot-DIV mit alternativem AdSpirit Werbeflächenname