Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 03-19-2011, 05:36 PM
yamahapaul's Avatar
yamahapaul yamahapaul is offline
 
Join Date: Aug 2008
Location: UK
Posts: 201
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default First post ad- guests only

How and where do I place this code-

HTML Code:
<SCRIPT charset="utf-8" type="text/javascript" src="http://ws.amazon.co.uk/widgets/q?rt=tf_sw&ServiceVersion=20070822&MarketPlace=GB&ID=V20070822/GB/midlaherit-21/8002/d03520b8-633a-4e27-b9ac-93cb2ff12515"> </SCRIPT> <NOSCRIPT><A HREF="http://ws.amazon.co.uk/widgets/q?rt=tf_sw&ServiceVersion=20070822&MarketPlace=GB&ID=V20070822%2FGB%2Fmidlaherit-21%2F8002%2Fd03520b8-633a-4e27-b9ac-93cb2ff12515&Operation=NoScript">Amazon.co.uk Widgets</A></NOSCRIPT>
so that it is viewable in the first post of a thread as in the same location as adsense and viewable by guests only?
Reply With Quote
  #2  
Old 03-19-2011, 05:46 PM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You should put it in the appropriate ad location template and surrond the code with this conditional:

Code:
<if conditon="$show[guest]">
original code
</if>
Reply With Quote
  #3  
Old 03-19-2011, 05:53 PM
yamahapaul's Avatar
yamahapaul yamahapaul is offline
 
Join Date: Aug 2008
Location: UK
Posts: 201
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I tried all the ad locations for first post but they either showed it above the context of the post or outside it so I'm still head scratching at the moment..
Reply With Quote
  #4  
Old 03-19-2011, 06:09 PM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You can put it directly in the postbit template if you want and use this condition:

Code:
<if conditon="$show[guest] AND $post[isfirstshown]">
original code
</if>
Reply With Quote
  #5  
Old 03-19-2011, 06:28 PM
yamahapaul's Avatar
yamahapaul yamahapaul is offline
 
Join Date: Aug 2008
Location: UK
Posts: 201
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by BirdOPrey5 View Post
You can put it directly in the postbit template if you want and use this condition:

Code:
<if conditon="$show[guest] AND $post[isfirstshown]"><SCRIPT charset="utf-8" type="text/javascript" src="http://ws.amazon.co.uk/widgets/q?rt=tf_sw&ServiceVersion=20070822&MarketPlace=GB&ID=V20070822/GB/midlaherit-21/8002/8e6f80af-66e4-4fc7-8a48-a7545e5b3801"> </SCRIPT> <NOSCRIPT><A HREF="http://ws.amazon.co.uk/widgets/q?rt=tf_sw&ServiceVersion=20070822&MarketPlace=GB&ID=V20070822%2FGB%2Fmidlaherit-21%2F8002%2F8e6f80af-66e4-4fc7-8a48-a7545e5b3801&Operation=NoScript">Amazon.co.uk Widgets</A></NOSCRIPT></if>

I'm not 100% sure whereabouts in there to put it so that shows the same as the adsense would look..
Reply With Quote
  #6  
Old 03-19-2011, 07:07 PM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm not sure how adsense looks, I mean, it looks like whatever it does depending on the ad location template used usually and it depends on what size/shape ad you choose when making your ad.

Places I would try would be immediately before or after $post[message] in the postbit(_legacy) template... probably right after that is best. Do you have a screen shot of an example of what you want it to look like?
Reply With Quote
  #7  
Old 03-19-2011, 07:28 PM
yamahapaul's Avatar
yamahapaul yamahapaul is offline
 
Join Date: Aug 2008
Location: UK
Posts: 201
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I want to achieve something like the attached and the ad is more or less the same sort of size as mine I think.... the only difference here is that I'm running 3.8.5 and the example is 4. something or other..
Attached Images
File Type: jpg ads.jpg (97.3 KB, 0 views)
Reply With Quote
  #8  
Old 03-19-2011, 07:45 PM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

That's probably using some <div> or <table> tags to align the ad to the right. On that page use your browser to view the HTML source and you'll see the HTML around the ad... Just copy it and put it around your ad code.

To me it looks like a <table> but I'm not sure, it could definitely be done with a table...

In your postbit_legacy

find:
Code:
$post[message]
and replace with:
Code:
<if conditon="$show[guest] AND $post[isfirstshown]">
<table border="0" width="100%">
<tr>
<td VALIGN="top">
$post[message]
</td>
<td VALIGN="top" width="200">
Ad Code Here
</td>
</tr>
</table>
<else />
$post[message]
</if>
The width="200" is what I'm guessing is the width, in pixels, of the google ad- set it whatever the real width is.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07:12 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.03834 seconds
  • Memory Usage 2,257KB
  • Queries Executed 14 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (5)bbcode_code
  • (1)bbcode_html
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (8)post_thanks_box
  • (8)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (8)post_thanks_postbit_info
  • (8)postbit
  • (1)postbit_attachment
  • (8)postbit_onlinestatus
  • (8)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • postbit_attachment
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete