This page short URL: f9d

wbAMP lets you insert very easily ads in your AMP pages, using only backend settings. You should use the backend settings for ads on almost all occasions, they are easier to use and to maintain. But you may want to insert ads in other location on your pages, or maybe use multiple ads network on the same page. This can be done fairly easily by inserting one or more specific tags in your content. The syntax is as follow:

{wbamp-embed type="ad"}

The tag can be used in two forms:

Ad tag with default settings

Using the ads tag as described above, {wbamp-embed type="ad"}, is enough to insert an advert in the location you inserted the tag, provided that you have selected an ad network in the backend settings, together with the required parameters.

You can have multiple instances of this tag in your content, just do not go too far. Users enjoy Accelerated Mobile Pages because they are fast and simple. Displaying an ad every 2 lines is probably going to make your visitors go away, just as on regular web site.

Ad tag with parameters

In the longest form, the wbamp-embed tag lets you completely specify which ad you want to display. To use this form you have to insert a tag that looks like this:

{wbamp-embed type="ad" ad-type="adtech" width="300px" height="250px" data-atwMN="2842475" data-atwDiv="adtech-ad-container">}

In addition to the short form seen above, you must specify:

  • ad-type="xxxxx" where xxxxx is the name of an ad network accepted by the AMP project.
  • width and height: as with most AMP element, you must explicitely list your ad dimensions, in pixels or another CSS unit
  • all other attributes depends on the network you are using. Please refer to each network documentation for details. This documentation can be reached from the main ad networks documentation page.

If you select the second form, Ad tag with parameters, you must specify yourself all required parameters for the particular network you use. wbAMP will not add anything to the values found in your tag.