Page Index Toggle Pages: 1
Topic Tools
Hot Topic (More than 10 Replies) Inserting ad code (Read 1,928 times)
Bill Myers
God Member
Beta Testers
*****
Offline



Posts: 1,600
Location: Los Angeles

YaBB 2.4
Re: Inserting ad code
Reply #14 - Feb 24th, 2013 at 7:37am
Post Tools
xnoddyx wrote on Feb 24th, 2013 at 4:49am:
here is the code working  Wink

Thank you for producing your video. Your instructions worked perfectly. Smiley

Edited:
alakazam wrote on Feb 21st, 2013 at 3:30pm:
I followed the instructions, but it doesn't seem to be working...  Undecided

I thought the same thing, but clearly I was wrong. After seeing his video, which illustrated his original instructions more thoroughly, I realized I was looking in the wrong place for the change I had made in our forum's default/Display template.

In other words, his instructions literally produce what you want. Cool


« Last Edit: Feb 24th, 2013 at 8:12am by Bill Myers »  

Morning, noon, or night, have a great one!

Note: This forum doesn't allow for us to freely edit our posts or topics to make corrections as needed, so please remember to look for subsequent posts if you see any mistakes or outdated information. Sorry for the inconvenience.
Back to top
IP Logged
 
freediver
Senior Member
****
Offline



Posts: 518
Re: Inserting ad code
Reply #13 - Feb 24th, 2013 at 7:21am
Post Tools
I can give you a copy of my files if you want.
  

Founding member of . I recently upgraded from YaBB 2.2.1 to 2.5 AE to 2.5.2.
Back to top
WWW  
IP Logged
 
xnoddyx
Support Team
Documentation Team
YaBB Moderators
YaBB Next Team
Beta Testers
****
Offline



Posts: 1,587
Location: UK:Scotland/livingston

None
Re: Inserting ad code
Reply #12 - Feb 24th, 2013 at 4:49am
Post Tools
last time i went to post this forum when into MM
here is the code working Wink

  

YaBB install help video
1. what yabb forum are you running and the url
2. describe in as much detail as you can what happens and also post screenshots if you can
3. please be patient we live in different time zones and have other commitments but we will help you
as bill and ted say (Be excellent to each other)
Back to top
IP Logged
 
Bill Myers
God Member
Beta Testers
*****
Offline



Posts: 1,600
Location: Los Angeles

YaBB 2.4
Re: Inserting ad code
Reply #11 - Feb 24th, 2013 at 3:09am
Post Tools
Dandello wrote on Feb 23rd, 2013 at 8:16pm:
And yes, it can be a challenge to figure out exactly where.

Thankfully, YaBB's template editing has made it relatively easy for me even when I wasn't quite sure where I was supposed to place the text I wanted to appear.

Basically, I just insert the word "test" where I think the placement should be, and then I search for that word to see where it ended up on the page. I'm usually pretty good at getting it in the right place, or at least close enough where a little more trial and error ends up getting it right in the end.

Using the Ctrl-F command in Windows makes searching for text really easy, and fast.

  

Morning, noon, or night, have a great one!

Note: This forum doesn't allow for us to freely edit our posts or topics to make corrections as needed, so please remember to look for subsequent posts if you see any mistakes or outdated information. Sorry for the inconvenience.
Back to top
IP Logged
 
Dandello
YaBB Administrator
YaBB Next Team
Operations Team
Beta Testers
Support Team
*****
Offline



Posts: 2,255
Location: Earth

YaBB 2.6.0
Re: Inserting ad code
Reply #10 - Feb 23rd, 2013 at 8:16pm
Post Tools
Basically,you have to figure out where you want to put the ad and then find the specific place (default.html or one of the templates) and put in the ad pretty much like adding it to a static page using proper HTML. And yes, it can be a challenge to figure out exactly where.
  

If you only have one solution to a problem you're not trying hard enough!
Back to top
WWW  
IP Logged
 
Bill Myers
God Member
Beta Testers
*****
Offline



Posts: 1,600
Location: Los Angeles

YaBB 2.4
Re: Inserting ad code
Reply #9 - Feb 21st, 2013 at 5:58pm
Post Tools
xnoddyx wrote on Feb 21st, 2013 at 5:42pm:
works i will make a video and show you after i have somthing to eat.

I'm sure you're correct. The thing is, following your instructions doesn't work for me, and like he stated, it didn't work for him either.

At least in my case, I suspect the reason your instructions aren't working for me is because I'm using our default/default.html template rather than the Display.template one you mentioned. I literally tried that, and it didn't work; at least for me it didn't.

But I'm sure it's not you; it's me that's messing up somehow. Wink

In any case, I've been placing ads wherever I've wanted in our forum since 2002, so the way I've been doing it has obviously been working just fine; thank you YaBB!

On that note, I did some more testing, and found a better placement for his ad, which is as follows:

Find:

Code
Select All
<div style="width: 96%; margin-left: auto; margin-right: auto; text-align: left;">{yabb main}</div>
<div style="width: 96%; margin-left: auto; margin-right: auto; text-align: right; padding-top: 10px;">{yabb forumjump}</div>
 


Just before the coding above, type the following:

<center>
Test
</center>

The word "Test" will appear exactly where you want, so that means you can place your ad there, too.

Good luck, and have fun templating your forum the way you like. Cool

« Last Edit: Feb 21st, 2013 at 6:01pm by Bill Myers »  

Morning, noon, or night, have a great one!

Note: This forum doesn't allow for us to freely edit our posts or topics to make corrections as needed, so please remember to look for subsequent posts if you see any mistakes or outdated information. Sorry for the inconvenience.
Back to top
IP Logged
 
xnoddyx
Support Team
Documentation Team
YaBB Moderators
YaBB Next Team
Beta Testers
****
Offline



Posts: 1,587
Location: UK:Scotland/livingston

None
Re: Inserting ad code
Reply #8 - Feb 21st, 2013 at 5:42pm
Post Tools
Bill Myers wrote on Feb 21st, 2013 at 5:11pm:
His explanation didn't work for me either. However ...

it works i will make a video and show you after i have somthing to eat.
  

YaBB install help video
1. what yabb forum are you running and the url
2. describe in as much detail as you can what happens and also post screenshots if you can
3. please be patient we live in different time zones and have other commitments but we will help you
as bill and ted say (Be excellent to each other)
Back to top
IP Logged
 
xnoddyx
Support Team
Documentation Team
YaBB Moderators
YaBB Next Team
Beta Testers
****
Offline



Posts: 1,587
Location: UK:Scotland/livingston

None
Re: Inserting ad code
Reply #7 - Feb 21st, 2013 at 5:15pm
Post Tools
alakazam wrote on Feb 21st, 2013 at 4:16pm:
Don't think so. I copy-pasted it from the advertising website, just as they gave it to me...


are you are you shore like my google ads are in two parts and wont load with out one part

looks like this
Code
Select All
<script type="text/javascript"><!--
google_ad_client = "pub-xx**xx**xx**xx**xx**xx";
/* xx**xx**xx 2ed 728x90, created xx/xx/xx */
google_ad_slot = "xx**xx**xx**xx**xx";
google_ad_width = 728;
google_ad_height = 90;
//-->
</script>


<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
 



also has your site been verified as most ad companies won't display ads on your site till you are verified.
  

YaBB install help video
1. what yabb forum are you running and the url
2. describe in as much detail as you can what happens and also post screenshots if you can
3. please be patient we live in different time zones and have other commitments but we will help you
as bill and ted say (Be excellent to each other)
Back to top
IP Logged
 
Bill Myers
God Member
Beta Testers
*****
Offline



Posts: 1,600
Location: Los Angeles

YaBB 2.4
Re: Inserting ad code
Reply #6 - Feb 21st, 2013 at 5:11pm
Post Tools
alakazam wrote on Feb 21st, 2013 at 12:49pm:
I don't want ads on my forum's main page. Just on top of the threads.

His instructions didn't work for me either. However ...

... including ads at the bottom of every page of our forum, I've had my own menu appear just where you want your ad to appear. The thing is, it literally appears on the top of every page of our forum. But that should be fine.

Try the following experiment to see if it works for you, and if it does, simply place your ad code where you want it. That's one of the great things about using YaBB. It allows HTML language to be used, which has worked out well for our forum.

So, in your Admin Center go to Forum Layout and then Template ... open default/default.html (or whatever template your forum uses) ... and then look for the following code:

</table>
{yabb addtab}

Right below that code, type in the following to test how it works in your forum:

<center>
Test
</center>


Save your work.

Go to your forum, and you should see the word "Test" appearing just where you want it. You'll see that it will always appear throughout your forum.

As such, all you need to do is to place your ad there, and you'll be good to go.

Hint: You may want to place your ad in a table to make it show up more clearly. If you want to test how that will look, use the following HTML language where you want it:

Code
Select All
<center><p><table border=2 cellpadding=6><td align=center bgcolor="#FFFFFF">

Paste your ad here or type the word "Test" to see how it looks.

</p></center>
</td></table>
 


That's it!  Wink

Edited:
This is based on the 2.4 version of YaBB.

By the way, I think I found a better placement for your ad; I'm guessing where you want it to be. You can scroll to my next post, or click here for it.

« Last Edit: Feb 21st, 2013 at 6:06pm by Bill Myers »  

Morning, noon, or night, have a great one!

Note: This forum doesn't allow for us to freely edit our posts or topics to make corrections as needed, so please remember to look for subsequent posts if you see any mistakes or outdated information. Sorry for the inconvenience.
Back to top
IP Logged
 
alakazam
YaBB Newcomer
*
Offline



Posts: 26
Re: Inserting ad code
Reply #5 - Feb 21st, 2013 at 4:16pm
Post Tools
Don't think so. I copy-pasted it from the advertising website, just as they gave it to me...
  
Back to top
YIM  
IP Logged
 
xnoddyx
Support Team
Documentation Team
YaBB Moderators
YaBB Next Team
Beta Testers
****
Offline



Posts: 1,587
Location: UK:Scotland/livingston

None
Re: Inserting ad code
Reply #4 - Feb 21st, 2013 at 3:41pm
Post Tools
ok i did a test and the test works just that your ad code don't is it possible that you are missing some of the ad code?
  

YaBB install help video
1. what yabb forum are you running and the url
2. describe in as much detail as you can what happens and also post screenshots if you can
3. please be patient we live in different time zones and have other commitments but we will help you
as bill and ted say (Be excellent to each other)
Back to top
IP Logged
 
xnoddyx
Support Team
Documentation Team
YaBB Moderators
YaBB Next Team
Beta Testers
****
Offline



Posts: 1,587
Location: UK:Scotland/livingston

None
Re: Inserting ad code
Reply #3 - Feb 21st, 2013 at 3:37pm
Post Tools
alakazam wrote on Feb 21st, 2013 at 3:30pm:
I followed the instructions, but it doesn't seem to be working... Undecided Do I need to place it anywhere else except for Display.template ?

pm me your ad code as i think i still have admin on your forum and i will ad it i will do a check for you just now as well to see if i still have admin on it.
  

YaBB install help video
1. what yabb forum are you running and the url
2. describe in as much detail as you can what happens and also post screenshots if you can
3. please be patient we live in different time zones and have other commitments but we will help you
as bill and ted say (Be excellent to each other)
Back to top
IP Logged
 
alakazam
YaBB Newcomer
*
Offline



Posts: 26
Re: Inserting ad code
Reply #2 - Feb 21st, 2013 at 3:30pm
Post Tools
I followed the instructions, but it doesn't seem to be working... Undecided Do I need to place it anywhere else except for Display.template ?
  
Back to top
YIM  
IP Logged
 
xnoddyx
Support Team
Documentation Team
YaBB Moderators
YaBB Next Team
Beta Testers
****
Offline



Posts: 1,587
Location: UK:Scotland/livingston

None
Re: Inserting ad code
Reply #1 - Feb 21st, 2013 at 1:27pm
Post Tools
goto admin > Forum Layout > Template > then load default/Display

in Display.template find
Code
Select All
$display_template = qq~

<!-- Navigation Bar start --> 



the ad code
Code
Select All
<!-- ad code start-->
<table class="navbarcontainer" width=100% cellpadding="0" cellspacing="0">
<td cellpadding="0" cellspacing="0" border="0" align="center" valign="center">
ad code here
</table>
<!-- ad code end--> 


then add this before <!-- Navigation Bar start -->

so you endup with
Code
Select All
$display_template = qq~
<!-- ad code start-->
<table class="navbarcontainer" width=100% cellpadding="0" cellspacing="0">
<td cellpadding="0" cellspacing="0" border="0" align="center" valign="center">
ad code here
</table>
<!-- ad code end-->
<!-- Navigation Bar start -->
 

  

YaBB install help video
1. what yabb forum are you running and the url
2. describe in as much detail as you can what happens and also post screenshots if you can
3. please be patient we live in different time zones and have other commitments but we will help you
as bill and ted say (Be excellent to each other)
Back to top
IP Logged
 
alakazam
YaBB Newcomer
*
Offline



Posts: 26
Inserting ad code
Feb 21st, 2013 at 12:49pm
Post Tools
Hi

Can you please tell me where I need to insert the ads code so that the text ads may appear on top of every thread, like in the image below?



I don't want ads on my forum's main page. Just on top of the threads.
  
Back to top
YIM  
IP Logged
 
Page Index Toggle Pages: 1
Topic Tools
 
  « Board Index ‹ Board  ^Top