Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

function adngin.cmd.startAuction(lots, callback)

argument name

type

optional

value

description

lots

Array

✔️

Array<string> | Array<AuctionLot> | null

An array of strings holding the ad unit names, an array of AuctionLot objects that contain a pair ad unit/placement, a null value that results in no auction being made or undefined (value or no parameter at all), which will auction all existing ad units.

callback

function

✔️

function(result:CallbackResult, success:boolean)

The callback function that is called with the function call result.

Parameters

lots

value undefined

...

Code Block
window.addEventListener('adnginLoaderReady', function() {
  adngin.queue.push(function() {
    // trigger a new auction
    adngin.cmd.startAuction([
      {
        adUnit: "adUnit1",
        placement: "otherdiv1"
      },
      {
        adUnit: "adUnit2",
        placement: "otherdiv2"
      }
    ]);
  });
});

Starting an auction for "adUnit1" in placements "otherdiv1" and "otherdiv2"

Code Block
window.addEventListener('adnginLoaderReady', function() {
  adngin.queue.push(function() {
    // trigger a new auction
    adngin.cmd.startAuction([
      {
        adUnit: "adUnit1",
        placement: "otherdiv1"
      },
      {
        adUnit: "adUnit1",
        placement: "otherdiv2"
      }
    ]);
  });
});

Using GAM path per page with custom sizes

...