fractaslabs/silverstripe-google-dfp

快速、可配置的SilverStripe实现Google DoubleClick for Publishers (DFP)

安装: 13

依赖项: 0

建议者: 0

安全: 0

星标: 2

关注者: 3

分支: 0

开放问题: 0

类型:silverstripe-vendormodule

1.0.1 2017-11-06 12:23 UTC

This package is auto-updated.

Last update: 2024-08-29 04:18:38 UTC


README

Build Status Scrutinizer Code Quality Latest Stable Version Latest Unstable Version Total Downloads License

概览

一个可定制的Google DoubleClick for Publishers (DFP)模块,适用于SilverStripe。

维护者联系方式

  • Milan Jelicanin [at] Fractas.com
  • Petar Simic [at] Fractas.com

需求

  • SilverStripe框架4+

版本信息

此模块的主分支目前旨在实现SilverStripe 4.x兼容性

安装

  • 推荐通过Composer安装此模块
composer require "fractas/google-dfp" "2.x-dev"
  • 将其添加到配置YML文件中
---
name: mygoogledfp
---
Fractas\GoogleDfp\GoogleDfpSlotHelper:
 enable_in_dev: false # if you wanna test banners in "dev" environment change to true
 publisher_id: 12345678 # change to your Google DFP network code
   layouts:
     PageController: # change to your Controller ClassName or leave it PageController if you wanna apply banners on SiteTree
       div-gpt-ad-123456789012-0: # An exact banner ID from Google DFP system
         alias: billboard # human readable banner type, used in template for banner init
         adUnitPath: /12345678/ad_unit_code # Full path of the ad unit with the network code and ad unit code.
         size: '[[1], [300, 250]]' # An exact size of banner creative
         outOfPage: false # if banner is "floater" or "wallpaper" type, change to "true"
  • 运行?flush=all以更新清单
  • 在模板(例如Page.ss)中按如下方式调用您的横幅:$GoogleDfpSlotByAlias('billboard')以渲染所选横幅HTML

附加文档

错误跟踪器

许可证