Just getting the issue queue going to add the new 300x600 ad format: http://adsense.blogspot.com/2012/11/larger-brand-friendly-ad-sizes.html

I tried to add it into the

function adsense_ad_formats($key = NULL) {
  $ads = array(

area but couldn't seem to get it to work... (tried clearing the cache, didn't help)

Comments

jursx’s picture

Yes please add ...

philsward’s picture

I looked into the issue again and figured out how to add the 300x600 Large Skyscraper to the module code. I must have missed a step last time I looked into it...

1) Create your 300x600 ad in adsense
2) go to "/sites/all/modules/adsense/" and edit adsense.module
3) Look around line 51 for:

function adsense_ad_formats($key = NULL) {
  $ads = array(
    '120x90'   =>  array('type' => ADSENSE_TYPE_LINK, 'desc' => t('4-links 120x90'),   'code' => '120x90_0ads_al',   'width' => 120, 'height' =>  90),
    '160x90'   =>  array('type' => ADSENSE_TYPE_LINK, 'desc' => t('4-links 160x90'),   'code' => '160x90_0ads_al',   'width' => 160, 'height' =>  90),
    '180x90'   =>  array('type' => ADSENSE_TYPE_LINK, 'desc.....

4) go to the very bottom of the ad format setup. Copy the very last ad format:

    '728x90'   =>  array('type' => ADSENSE_TYPE_AD,   'desc' => t('Leaderboard'),      'code' => '728x90_as',        'width' => 728, 'height' =>  90),

then paste it underneath itself, so you have a duplicate.
5) Next change everything in the second copy to reflect the 300 x 600 ad format (or just copy and paste the following):

    '300x600'   =>  array('type' => ADSENSE_TYPE_AD,   'desc' => t('Large Skyscraper'), 'code' => '300x600_as',        'width' => 300, 'height' =>  600),

6) Save it, that part is done
7) Add the adsense code to your page: [adsense:300x600:{your ad code#}]
8) Flush your cache
9) Check on browser that isn't logged in. If you did it right, the first few times you check the page it will probably be blank. as long as you aren't seeing the code identifier [adsense:300x600....] you should be all set.

I don't have a clue how to create a patch for this... so anyone else who want's to give it a stab, feel free.

fenstrat’s picture

Status: Active » Needs review
StatusFileSize
new1.21 KB

Here it is in patch format as per what was done in #1603174: Add 320 x 50 Mobile Banner size.

jcnventura’s picture

Status: Needs review » Fixed

Sorry for the time it took. I've now committed it to git.

fenstrat’s picture

No worries @jcnventura, thanks for committing.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.