|
uCoz Community uCoz Modules Additional Features How to make my ads appear in the first post in the forum? |
How to make my ads appear in the first post in the forum? |
I have a forum: http://www.misamisoccidental.org/forum/. I want to make my advertisement appear below each first post of a thread in the forum. I already spent many days in using the conditional operators but I had no success.
Please help me uCoz team and all the guys out there who mastered the uCoz conditional operators. Attachments:
0588993.jpg
(25.6 Kb)
Post edited by khen - Saturday, 2012-02-18, 3:25 PM
|
Add the following to 'General appearance of forum pages' before BODY:
Code <script> rekPost = 0; </script> Add the following to 'Appearance of entries' where you want it to appear: Quote <script> rekPost = rekPost + 1; if(rekPost == 1){document.write('advertisement');} </script> The red digit means the number of post. This code won't work if your advertisement is a script. I'm not active on the forum anymore. Please contact other forum staff.
|
Thank you so much for the reply Sunny. You're such a great helper. My advertisement is a script. How can I make it work?
Post edited by khen - Monday, 2012-02-20, 10:33 AM
|
khen,
Quote (Sunny) This code won't work if your advertisement is a script. You might be able to include the necessary parts of sunny's code into the one you are planning on using although I'm not 100% sure about this. What exactly is the script you are trying to use? If you go to post the full thing here on the forums don't forget to put it in a spoiler/code box. Jack of all trades in development, design, strategy.
Working as a Support Engineer. Been here for 13 years and counting. |
Paradox, I'm using the Google Adsense script. How is it possible to appear my Google ads the within the provided script of Sunny.
Added (2012-02-25, 5:08 AM) Post edited by khen - Monday, 2012-02-20, 1:32 PM
|
You could make it appear on every post easily.
Proud uCoz user since 2006
Freelance designer - http://pixelkhaos.com PixelKhaos on twitter - @PixelKhaos I can help you develop your site for a small fee. |
I don't want to make it appear in every post. What I want is to appear the ad in the FIRST POST ONLY (thread starter's first post). But how? Please help.
|
Quote (Sunny) {document.write('advertisement');} Unfortunately I am not a coder, all I can say is that you need to edit this part above. You can also try the following codes: - add this to Appearance of entries, to the bottom of the template: Code <div class="advert">ADVERTISEMENT</div> - add to the following to General appearance of forum pages: Code <style> .advert{display:none} .postFirst .advert{display:block !important} </style> I'm not active on the forum anymore. Please contact other forum staff.
|
Sunny, thanks for your great help. I followed your second suggestion and it works now!...
|
| |||
| |||