MyBB Community Forums

Full Version: Comprehensive Adsense guide
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I couldn't find a good guide to implement adsense on my forum and most adsense plugins are really glitchy and don't work well, so I decided to go through all the templates and researched the best spots to put my adsense code. Here is the guide that I put together.

MYBB Adsense

1-Go to Templates (Modify/Delete) -> Expand on your default template -> Show Thread Templates -> showthread (edit)

Find:
Code:
{$posts}

Add {Your Google Code} Before (if you want advert before posts), or add after (if you want it after posts)


2-
Go to Templates (Modify/Delete) -> Expand on your default template -> Index Page Templates -> index (edit)

Find:
{$header}

Add {Google Code} Before (if you want advert before ), or add after (if you want it after)

Find:
{$footer}
Add {Your Google Code} Before (if you want advert before), or add after (if you want it after)


3-
Go to Templates (Modify/Delete) -> Expand on your default template -> Forum Display Templates -> forumdisplay (edit)

Find:
{$usersbrowsing}
Add {Your Google Code} Before (if you want advert before posts), or add after (if you want it after)


4-
Go to Templates (Modify/Delete) -> Expand on your default template -> Header Templates -> header (edit)

Find:
{$navigation}
Add {Your Google Code} Before (if you want advert before posts), or add after (if you want it after)
(2009-06-12, 04:03 PM)Loondatoon Wrote: [ -> ]I couldn't find a good guide to implement adsense on my forum and most adsense plugins are really glitchy and don't work well, so I decided to go through all the templates and researched the best spots to put my adsense code. Here is the guide that I put together.

MYBB Adsense

1-Go to Templates (Modify/Delete) -> Expand on your default template -> Show Thread Templates -> showthread (edit)

Find:
Code:
{$posts}

Add {Your Google Code} Before (if you want advert before posts), or add after (if you want it after posts)


2-
Go to Templates (Modify/Delete) -> Expand on your default template -> Index Page Templates -> index (edit)

Find:
{$header}

Add {Google Code} Before (if you want advert before ), or add after (if you want it after)

Find:
{$footer}
Add {Your Google Code} Before (if you want advert before), or add after (if you want it after)


3-
Go to Templates (Modify/Delete) -> Expand on your default template -> Forum Display Templates -> forumdisplay (edit)

Find:
{$usersbrowsing}
Add {Your Google Code} Before (if you want advert before posts), or add after (if you want it after)


4-
Go to Templates (Modify/Delete) -> Expand on your default template -> Header Templates -> header (edit)

Find:
{$navigation}
Add {Your Google Code} Before (if you want advert before posts), or add after (if you want it after)

I followed these steps but it cuts everything after I paste the adsense code into it. Any suggestions?
(2009-06-17, 11:24 PM)evanjohan Wrote: [ -> ]
(2009-06-12, 04:03 PM)Loondatoon Wrote: [ -> ]I couldn't find a good guide to implement adsense on my forum and most adsense plugins are really glitchy and don't work well, so I decided to go through all the templates and researched the best spots to put my adsense code. Here is the guide that I put together.

MYBB Adsense

1-Go to Templates (Modify/Delete) -> Expand on your default template -> Show Thread Templates -> showthread (edit)

Find:
Code:
{$posts}

Add {Your Google Code} Before (if you want advert before posts), or add after (if you want it after posts)


2-
Go to Templates (Modify/Delete) -> Expand on your default template -> Index Page Templates -> index (edit)

Find:
{$header}

Add {Google Code} Before (if you want advert before ), or add after (if you want it after)

Find:
{$footer}
Add {Your Google Code} Before (if you want advert before), or add after (if you want it after)


3-
Go to Templates (Modify/Delete) -> Expand on your default template -> Forum Display Templates -> forumdisplay (edit)

Find:
{$usersbrowsing}
Add {Your Google Code} Before (if you want advert before posts), or add after (if you want it after)


4-
Go to Templates (Modify/Delete) -> Expand on your default template -> Header Templates -> header (edit)

Find:
{$navigation}
Add {Your Google Code} Before (if you want advert before posts), or add after (if you want it after)

I followed these steps but it cuts everything after I paste the adsense code into it. Any suggestions?

What do you mean is cuts everything? It should work if you paste the code in the those pages from your control panel in your theme. Maybe try one of the pages first and see if the code shows up. Let me know whether you got it solved.