One of the things we get asked about a lot is how to avoid detection from Ad Blockers. While we’ve explained other options to respect those visitor’s ad display preferences, we understand that there are some instances that you aren’t using AdSanity for typical advertising. Maybe you’re just using AdSanity to track views and clicks on Image based content, for example. We provide you with a couple of methods to modify the display of individual ads, groups of ads, or all ads.

Unidades de Anúncios de Estilismo

Each Ad Unit has a number of CSS Classes and a unique HTML ID that you can target in your theme’s CSS to change its look. The format of these are:

  1. ad-{size} (exemplo: ad-125x125) – This allows you to style all ads of the same size
  2. column-{column number} (exemplo: column-2) – While relevant only to groups of ads, this allows you to style all ads in a particular column
  3. alignleft | aligncenter | alignright | alignnone – These four styles are generally already handled inside of most themes, but if you want to apply additional styles to better handle alignment, this is the place to do so. Note: only one class will be added to each ad unit.

If all of those classes don’t suit your needs or you want to change them, you can attach additional classes to each Ad Unit using a filter as described below.

Há algumas ações e filtros relacionados à exibição incorporados em nosso sistema de modelos. Estes permitem filtrar as classes CSS e adicionar marcas ao redor da unidade de anúncios para que você possa dar estilo a ela.

Filtros

Ações

Tema Modelos

Sometimes you need to have more control over the markup for your ads. We’ve extended WordPress Core’s template hierarchy to allow you to fully customize an ad’s markup through a theme template.

Se você quiser alterar a marcação de todos os anúncios, basta copiar o ad.php arquivo do theme-templates em seu tema e personalizá-lo à distância.

If you want to modify the markup for all ads of a particular size, you can rename that file to something like ad-125×125.php, where 125×125 is the size that you’re trying to modify. Note: you can find the size by looking at the classes that are applied to the ad in the markup.

Finalmente, se você quiser alterar a marcação de um determinado anúncio, você pode renomear o arquivo para ad-1234.php onde 1234 é o ID do anúncio que você deseja modificar. Nota: você pode encontrar o ID olhando para o ID HTML que é aplicado ao anúncio na marcação.

Didn’t find what you were looking for?

If you’re a subscriber to AdSanity and don’t find an answer to your specific question please submit a request and our support department will address your issue quickly.