Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.7 > vBulletin 3.7 Template Modifications

Reply
 
Thread Tools
Add Google AdSense Sitesearch to the standard forum search page. Details »»
Add Google AdSense Sitesearch to the standard forum search page.
Version: 1.00, by (Guest)
Developer Last Online: Jan 1970 Show Printable Version Email this Page

Category: Mini Mods - Version: 3.7.0 RC 2 Rating:
Released: 04-05-2008 Last Update: Never Installs: 32
Template Edits
Re-useable Code Translations  
No support by the author.

This will put a google search box above your standard search forum. You will need to generate your sitesearch code using AdSense's tools. Once you have your code, do the following:

ACP-> Styles & Templates -> edit the search_forums template.

Find towards the top:

Code:
$header
$navbar
Add below:

Code:
<!-- Google Search -->
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr>
	<td class="tcat">
		Google Search
	</td></tr>
<tr><td class="alt1" align="center">


GOOGLE SEARCH CODE GOES HERE

</td></tr>
</table>
<br />
<!-- /Google Search -->
Add your AdSense Search code as appropriate. The default AdSense setup only allows for black, white and grey backgrounds. To make it blend in with your site, edit the BGCOLOR attribute of the initial table call in Google's code. For example, I chose the black background:

Code:
<!-- SiteSearch Google -->
<form method="get" action="http://www.google.com/custom" target="google_window">
<table border="0" bgcolor="#000000">
[/code]

My alt1 color is #333333, so I edited the very last bit:

Code:
<!-- SiteSearch Google -->
<form method="get" action="http://www.google.com/custom" target="google_window">
<table border="0" bgcolor="#333333">
So that it matches the overall look of my site and blends in with the table.

Screenshot:

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #2  
Old 04-06-2008, 01:46 PM
Guest210212002
Guest
 
Posts: n/a
Default

Note that one of the more useful reasons for having this on your site is to be able to search for two-character strings. If you want to add a blurb about it, look for:

Code:
</table>
And add the following above it:

Code:
<tr><td class="alt1" align="center">
<span class="smallfont">
Google search is useful for finding terms that are three or less characters long. For example, to search for "9v", enter "9v" in the search pane, and select the 'www.sevenstring.org' button below it.</span></td></tr>
And replace my site's name and the search term with something more relevant to your site.

Reply With Quote
  #3  
Old 04-06-2008, 08:33 PM
onnenkolikko onnenkolikko is offline
 
Join Date: Feb 2008
Posts: 15
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

nice mod. Installed
Reply With Quote
  #4  
Old 04-07-2008, 12:14 AM
PoetJA-1975's Avatar
PoetJA-1975 PoetJA-1975 is offline
 
Join Date: Sep 2006
Location: Meh...
Posts: 1,218
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yes - very nice = Thanx for sharing!

Jacquii.
Reply With Quote
  #5  
Old 04-07-2008, 02:15 AM
PoetJA-1975's Avatar
PoetJA-1975 PoetJA-1975 is offline
 
Join Date: Sep 2006
Location: Meh...
Posts: 1,218
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I edited the html code just slightly to better fit my Forum...
If you want a live example site: http://jpicforum.info/search.php
Thanx again

Jacquii.
Reply With Quote
  #6  
Old 04-08-2008, 12:58 AM
snakeair snakeair is offline
 
Join Date: Jan 2007
Location: under a rock
Posts: 29
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks for the mod. "Installed"
Reply With Quote
  #7  
Old 04-08-2008, 04:31 AM
Playa82 Playa82 is offline
 
Join Date: Mar 2006
Location: Germany
Posts: 319
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Chris-777 View Post
Note that one of the more useful reasons for having this on your site is to be able to search for two-character strings. If you want to add a blurb about it, look for:

Code:
</table>
And add the following above it:

Code:
<tr><td class="alt1" align="center">
<span class="smallfont">
Google search is useful for finding terms that are three or less characters long. For example, to search for "9v", enter "9v" in the search pane, and select the 'www.sevenstring.org' button below it.</span></td></tr>
And replace my site's name and the search term with something more relevant to your site.


Nice addition but u made a little mistake:

u have to search for this:

Code:
</input>
</td></tr></table>
and after add:

Code:
<tr><td class="alt1" align="center">
<span class="smallfont">
Google search is useful for finding terms that are three or less characters long. For example, to search for "9v", enter "9v" in the search pane, and select the 'www.crackmuzik-gfx-elite.de' button below it.</span></td></tr>
-----------------------------------------------------------------------
Example here:
http://crackmuzik-gfx-elite.de/search.php
-----------------------------------------------------------------------
Reply With Quote
  #8  
Old 04-09-2008, 11:57 AM
iogames's Avatar
iogames iogames is offline
 
Join Date: Jan 2007
Location: Las Vegas, NV.
Posts: 1,433
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

how can I add it to the bottom?
Reply With Quote
  #9  
Old 04-09-2008, 06:01 PM
Playa82 Playa82 is offline
 
Join Date: Mar 2006
Location: Germany
Posts: 319
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by iogames View Post
how can I add it to the bottom?
in search_forums template find:

Code:
$footer

</body>
</html>
add above:

Code:
<!-- Google Search -->
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr>
	<td class="tcat">
		Google Search
	</td></tr>
<tr><td class="alt1" align="center">


GOOGLE SEARCH CODE GOES HERE

</td></tr>
</table>
<br />
<!-- /Google Search -->
Reply With Quote
  #10  
Old 04-10-2008, 04:12 PM
kollam003 kollam003 is offline
 
Join Date: May 2007
Posts: 154
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

installed thx
Reply With Quote
Reply

Thread Tools

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:53 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.10515 seconds
  • Memory Usage 2,294KB
  • Queries Executed 23 (?)
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
  • (12)bbcode_code
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (8)postbit_onlinestatus
  • (10)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_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
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • postbit_imicons
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete