PDA

View Full Version : Integration with vBulletin - vB Google Adsense for Search plus Integration


Pages : [1] 2

davidw
05-22-2008, 10:00 PM
I've done an overhaul on this and you will need to resetup your adsense for search account for this to work. If you aren't happy with that, please use the 3.6 version of this, which works fine for 3.7 from what I've been told. :)

Step 1:
You may have to resetup your adsense. If you do, you will get a new pub ID - this one includes your previous pub and tacks on your GALT (which is set up when you resetup your adsense account). I used www.christianboards.org and www.google.com (so it would search my site and the web - you can choose only your site, or any location that is web-accessible for results)

Example: partner-pub-0123456789012345:lnucfbm5dtp

If your partner-pub ID does not look like the example, you will see an error.

Also, keep in mind, all sites you put into the box for the adsense (one per line) will be integrated into the search and the search results.

Step 2:
Edit your searchresults.php file.
Find:
chdir('/path/to/your/forums/');
Put your correct value.

Example: chdir('/var/www/vhosts/yoursite.com/forums/');

Step 3:
Upload this file your forum's root. An example of your forum's root is below.

Example: http://www.yoursite.com/forums/searchresults.php

Step 4:
Install the product
Go to Admincp => Plugins & Products => Manage Products => [Add/Import Product] => Browse for product-davidw_vb_google_search.xml => Import

Step 5:
Configure your Admincp options
Go to Admincp => vBullitin Options => vBulletin Options => Find vB Google Search (Adsense) then click [Edit Settings]
Edit your new Partner-pub ID (the one you just had reset up - see example in red above), Google box width, iframe widthfor your results (I use 800 in the screenshot, but you can change this based on your needs), and the full URL to your searchresults.php.

NOTE! If you do not enter these in, you will see errors.

Step 6: Optional
Edit 1 template:
Admincp => Styles & Templates => Style Manager => Edit Templates (on your style) => Search Templates => search_forums => under $navbar, add $google_siteadsearch

Step 7: Optional (for vBAdvanced 3.x only)
vBa CMPS => Default Settings => Main Options => Portal Output Global Variables

Add these variables:
template_hook
google_navadsearch
homeurl

=> Save

vBa CMPS => Edit Modules => Search Forums => Select Action => Copy Module

Main Options
Module Title Google Search site / Forums
Template To Include search_google

Module Wrapper Template Options
Form Code Replace default code with <form action="http://www.yoursite.com/forums/searchresults.php" type="hidden" name="search" target="_blank">

Click Save
Edit locations where you want to set this active to.

dvduval
05-23-2008, 04:36 PM
Nice, thanks for this release. I will Download Now. :)

davidw
05-23-2008, 08:57 PM
Added navbar screenshot. Let me know how it goes. :) If you like it click install.

nene94
05-23-2008, 09:06 PM
Thanks, nice hack :)

mry
05-24-2008, 01:57 PM
ı install this hack but

error :

Google
Error


Bad Request
Your client has issued a malformed or illegal request.

Edited...

Problem solved ...

davidw
05-24-2008, 08:11 PM
Don't forget to click install :)

IR15H
05-24-2008, 09:24 PM
Thanks for this.

Is there a way to get the width as a percentage, rather than pixels? Also, a way to enable different pallets for different forum styles?

davidw
05-24-2008, 09:51 PM
I've tried to do percentages, but its fixed for width (I would prefer percentage personally). Unfortunately, colors are set to what's tacked to your pub (account). Unless you have multiple accounts, you couldn't have multiple colors set. This was possible previously before Google's change. However, this is something I will keep an eye on as I have multiple styles as well, and it would be nice to do this.

IR15H
05-24-2008, 09:59 PM
Bah! Never mind, good job anyway :).

davidw
05-24-2008, 10:18 PM
Thanks :)

digicom
05-24-2008, 11:35 PM
Thanks installed:up:

Basit
05-25-2008, 03:53 PM
Installed, but getting following error message.



Google Error Bad Request

Your client has issued a malformed or illegal request.


For more detail see following page

http://www.hallagulla.com/urdu/searchresults.php?cx=pub-2757209652731126&cof=FORID%3A9&q=urdu+poetry&sa=Go

use to search term "urdu poetry"

Any idea what's wrong ?

davidw
05-25-2008, 04:22 PM
If you don't do this:

When you resetup your adsense, you will get a new pub ID - this one includes your previous pub and tacks on your GALT (which is set up when you resetup your adsense account).

Example: partner-pub-0123456789012345:lnucfbm5dtp

And put that in your admincp, you will get that error

Basit
05-25-2008, 04:42 PM
If you don't do this:



And put that in your admincp, you will get that error


I was following instructions from AdminCP>vBulletin Options.



Thank you very much very helpful.

davidw
05-25-2008, 05:47 PM
I will update instructions to make it easier for others to understand :)

Arkidas
05-27-2008, 01:55 PM
Is it not possible to make the width 750 or so? Google only allows 795 :(

davidw
05-27-2008, 03:08 PM
Did you edit the width in the admincp options? If it is unchangeable in the admincp, then it may only be changeable when you resetup your adsense account information.

ahayat
05-31-2008, 05:28 AM
thanks i installed and it works when we search but still gives an error

Warning: chdir() [function.chdir]: No such file or directory (errno 2) in /home/rootname/public_html/searchresults.php on line 8

i did follow everything any idea where i went wrong?

nirvana43
06-01-2008, 03:09 AM
thanks i installed and it works when we search but still gives an error

Warning: chdir() [function.chdir]: No such file or directory (errno 2) in /home/rootname/public_html/searchresults.php on line 8

i did follow everything any idea where i went wrong?

same problem i'm facing!! plz help man!! :confused:

davidw
06-01-2008, 01:15 PM
Did you edit searchresults.php as in Step 1: Edit chdir('/path/to/your/forums/'); in searchresults.php That would give this error if it was not edited or if the path was incorrect.

nirvana43
06-01-2008, 02:37 PM
Did you edit searchresults.php as in Step 1: Edit chdir('/path/to/your/forums/'); in searchresults.php That would give this error if it was not edited or if the path was incorrect.

yes i did edited searchresults.php
my searchresults.php reads as follows :

<?php
// ####################### SET PHP ENVIRONMENT ###########################
error_reporting(E_ALL & ~E_NOTICE);

// #################### DEFINE IMPORTANT CONSTANTS #######################
define('NO_REGISTER_GLOBALS', 1);
define('THIS_SCRIPT', 'searchresults');
chdir('/home/public_html/searchresults.php');

// ################### PRE-CACHE TEMPLATES AND DATA ######################
// pre-cache templates used by all actions
$globaltemplates = array(
'google_navadsearch',
'google_siteadsearch',
'google_searchresults'
);

// ######################### REQUIRE BACK-END ############################
require_once('./global.php');

// ######################## START MAIN SCRIPT ############################
$navbits = array();
$navbits[$parent] = 'Search Results';
$navbits = construct_navbits($navbits);
eval('$navbar = "' . fetch_template('navbar') . '";');
eval('print_output("' . fetch_template('google_searchresults') . '");');
?>

My forum is located at http://www.projectsplanet.com
please tell me what should i write in searchresults.php ????
kindly help :(

Regards

davidw
06-01-2008, 03:21 PM
For example, somewhat edited, here is mine:
chdir('/home/xxxxxxx/christianboards/forums/');
This is my /path/to/my/forums/ since searchresults.php is located at forums/searchresults.php
You will never use a file in a path (a path is a directory). In your case, try taking out searchresults.php from your path.

chdir('/home/public_html/');

It has to be the full path to your searchresults.php, but don't include the file itself. Hope that helps :)

nirvana43
06-02-2008, 03:00 AM
For example, somewhat edited, here is mine:
chdir('/home/xxxxxxx/christianboards/forums/');
This is my /path/to/my/forums/ since searchresults.php is located at forums/searchresults.php
You will never use a file in a path (a path is a directory). In your case, try taking out searchresults.php from your path.

chdir('/home/public_html/');

It has to be the full path to your searchresults.php, but don't include the file itself. Hope that helps :)

Still same problem persist bro... :(
i tried these :

chdir('/home/projects/public_html/');

chdir('/home/public_html/');

btw in your case u've written chdir('/home/xxxxxxx/christianboards/forums/');

what to write at xxxxxxx please can tell me in my case what do i write??
my forum is located in main public_html directory
please have a look here www.projectsplanet.com
please tell me what do i write after /home/
:confused:


also when i try to search it gives me server not found error...

davidw
06-02-2008, 11:13 AM
Each website is going to be different. If you have vbadvanced, there is a tool in the Extras (do not upload) folder called forumpath.php that you can upload to your forums directory that will tell you your exact forum path. If you use that tool, remove it after you use it. The path in the chdir must begin and end with a slash "/".

Also, for my site I edited it in at least two places, but just wanted to show that as an example.

ahayat
06-02-2008, 12:41 PM
Still same problem persist bro... :(
i tried these :

chdir('/home/projects/public_html/');

chdir('/home/public_html/');

btw in your case u've written chdir('/home/xxxxxxx/christianboards/forums/');

what to write at xxxxxxx please can tell me in my case what do i write??
my forum is located in main public_html directory
please have a look here www.projectsplanet.com
please tell me what do i write after /home/
:confused:


also when i try to search it gives me server not found error...

Bro when u get an error u must see the link above ?? PM me that link then i will reply you how to fix it.

in other words u must have seen the error like that chdir("/home/ur_root_name_/public_html")

ur_root_name = here u should see root name when u get error just put it there.

@david
Thanks alot mate , My Problem has been fixed.

nirvana43
06-03-2008, 04:06 AM
Bro when u get an error u must see the link above ?? PM me that link then i will reply you how to fix it.

in other words u must have seen the error like that chdir("/home/ur_root_name_/public_html")

ur_root_name = here u should see root name when u get error just put it there.

@david
Thanks alot mate , My Problem has been fixed.

yeah!! mine 2!!! its working lika charm now!!!
u rox david!!:D
thanks again!!
here is test : http://www.projectsplanet.com/searchresults.php?cx=partner-pub-8311037325266850%3Afqqomvub8m9&cof=FORID%3A10&ie=ISO-8859-1&q=projects&sa=Search#1270

davidw
06-03-2008, 10:48 AM
It shows to be working for me :)

ahayat
06-03-2008, 02:14 PM
One question please.

Can i place it on Forumhome somewhere ? it would be good if users can see it on the page instead going to search list?
I thought i should ask you before trying anywhere :D

Cheers

davidw
06-03-2008, 02:36 PM
Feel free to modify it to your forums needs. I won't be able to support it being modified for displaying results on the forumhome, but you are welcome to put it there. As for the search box itself, you can add that easily by using $google_siteadsearch and modifying that slightly.

MadK
06-08-2008, 02:48 AM
Thank you davidw! It works great!
http://www.mafia-mp.com

davidw
06-08-2008, 04:19 PM
Glad you like it :)

DawnsWebDesigns
06-08-2008, 06:08 PM
I'm not sure if it's this mod & this mod alone but my site's been acting a bit strange. I can't create custom bbcode modules in my vbadvanced...not in FF...I can in IE.

But I noticed while I had this mod going it pushed that side column over to the left thereby pushing the other 2 over as well & made my page look strange. It was even worse in IE then it was in FF. I also noticed my drop down menus quit working. The search drop down still don't work for guests...but it does for members? The other 2 drop downs work?

Perhaps the search drop down don't work for guests because on my site guests have to do the human verification thingy. The link does work bringing up an entire search page for various things where they can also do the human verification thingy. Maybe that's it?

But when I turned your mod off my table/page straightened out & the other 2 drop down menus kicked back on. And yes sir I even put those variables in the vbadvanced global output blah blah. I just thought you should know.

davidw
06-09-2008, 01:16 AM
My first thought - if it works in one browser but not another, it might be a cookie, or a cache issue (I've had both affect me on multiple occasions in both IE and FF).

- Column size issue
However, if you've tried deleting both cookies and cache and your module is moving over, one thing it could be is the way the browser renders the width of the search box. In your admincp, one of the options is the width of your Google search box, this is a global setting for your drop-down, the CMPS portal search, and for the search page. Try tweaking this variable smaller than what you have as IE and FF might render these different sizes.

- Drop down not working
One thing this will not do on a default board is disable javascript. That isn't to say that this modification will or will not have issues with another modification. If the drop down does not work for guests but does for members, this makes me think back to a cookie/cache issue.

So, ultimately, I would have to either say A) its either a cookie/cache issue with one or more browsers or B) an issue with a mod conflicting with this one - or a very slim chance that it is both, but unlikely

Hope that helps. :)

djilou
06-10-2008, 09:42 AM
When you resetup your adsense, you will get a new pub ID - this one includes your previous pub and tacks on your GALT (which is set up when you resetup your adsense account).

Example: partner-pub-0123456789012345:lnucfbm5dtp

I don't see where can I get this code : :lnucfbm5dtp?

my code is look like
<input type="hidden" name="client" value="pub-0123456789012345"></input>
<input type="hidden" name="forid" value="1"></input>
<input type="hidden" name="ie" value="ISO-8859-1"></input>
<input type="hidden" name="oe" value="ISO-8859-1"></input>
<input type="hidden" name="cof" value="GALT:#008000;GL:1;DIV:#336699;VLC:663399;AH:center ;BGC:FFFFFF;LBGC:336699;ALC:0000FF;LC:0000FF;T:000 000;GFNT:0000FF;GIMP:0000FF;FORID:1"></input>
<input type="hidden" name="hl" value="fr"></input>

davidw
06-10-2008, 10:47 AM
That's weird as I've gone through the setup 2-3 times and they both ended up with a full new code (which looks very different than this).

When you reset your adsense account, did you go to https://www.google.com/adsense/login/en_US/ and it did it ask you to set up a new username/password combination by chance?

djilou
06-10-2008, 10:59 AM
Yes I did set up a new username/password and it's work now
Thanks!

davidw
06-10-2008, 12:02 PM
Great news :)

andrewc_11890
06-13-2008, 04:02 AM
How do you exactly resetup your adsense account?

davidw
06-13-2008, 11:00 AM
Use the link in post #35 - if you haven't set it up in a while, when you log in and want to set up your adsense it will prompt you to set up a change, if not, you can go on through and redo your adsense.

ahayat
06-13-2008, 05:54 PM
one question pls.

after adding this on my vbadvanced the size of search box has become big a bit. what should i do?

davidw
06-13-2008, 06:16 PM
...In your admincp, one of the options is the width of your Google search box, this is a global setting for your drop-down, the CMPS portal search, and for the search page. Try tweaking this variable smaller than what you have as IE and FF might render these different sizes.Alternatively for this you can manually edit this in the templates either in the product or through the style (the product would be easier - then reupload and overwrite as it would affect all styles). The area to edit is under adv_portal_search_google this line:
<input type="text" name="q" size="{$vboptions['google_box_width']}" />
The next update I will probably separate these values so it isn't global.

andrewc_11890
06-15-2008, 11:48 PM
Use the link in post #35 - if you haven't set it up in a while, when you log in and want to set up your adsense it will prompt you to set up a change, if not, you can go on through and redo your adsense.

What do you mean? The link in post 35 takes you to the adsense login page. I logged in, but how do you resetup after you login I can find the pub ID, but it doesn't have the GALT thingy after it.

davidw
06-16-2008, 01:39 AM
When you go to the adsense choices, do you see this? AdSense for Search Improved!? If so, click on that and go from there - it will tie in to your existing account.

cmedic101
06-16-2008, 03:58 AM
Great Mod!

Works perfect:up:


thanks

cmedic101

davidw
06-19-2008, 06:12 PM
Version 1.6 has been released. Details have been given on the changes to those who have clicked install.

amaarvell
06-21-2008, 08:18 AM
Hi this dont work on my forum, could it be the fact our "search" button is called "search for solution"?
if so what do i need to change on the script to get it working

cheers

davidw
06-21-2008, 10:15 AM
For one thing you have errors on your searchresults.php, which most likely means the path on the chdir is incorrect. Do the search locations show up correctly elsewhere (navbar/search.php)? Also, do you have the full URL in the admincp?

RedGTiVR6
06-30-2008, 02:54 PM
installed! instructions are good, though they do say that your ID should start with PUB....

I pasted the entire ID starting with partner- and it works fine.

davidw
06-30-2008, 03:15 PM
Yeah, that's right - It does start with partner (I have partner-pub in the instructions above but will need to edit the other instructions).
Thanks!

RedGTiVR6
06-30-2008, 03:46 PM
thanks for the support! now if only we could get that in the advertisement management plug-in thread....:(

davidw
06-30-2008, 03:54 PM
No problem - I'm considering working on Adsense for Content in the future.

LAJAURIA
07-07-2008, 06:13 AM
it doesn't work....

how do I "resetup" my account?? I don't understand.


the pub number + the code you say, online appears in the adsense for search code, but not in the account-settings...


It doesn't show the pages i set up in my adsense and, when i do a search, shows this error:


Forbidden

You don't have permission to access /search/ on this server.

davidw
07-07-2008, 10:44 AM
If you are seeing something like this: partner-pub-0123456789012345:lnucfbm5dtp

your account is already under the new setup. This whole code you need for the admincp options. If you are not seeing the whole code (including the parts in red) then your account is based on the old style.

Please ensure you have set up the chdir in the searchresults.php file and that the admincp options point directly to that file (you can usually open the searchresults.php page and then copy and paste the URL into the admincp options).

dilbert
07-07-2008, 12:47 PM
Thanks David,
This looks great.

Is it possible to get it to highlight the searched text in the posts similar to the default search? "&highlight=seach phrase"

davidw
07-07-2008, 01:32 PM
Honestly I'm not sure as you are using Google, rather than vBulletin for the search engine on this. I cannot say no as I am not 100% sure.

marcossalazar
07-07-2008, 01:41 PM
Great Mod. Can the color of the search results (changing the white background) be altered?

Thanks!

Marcos

jlew24asu
07-07-2008, 01:52 PM
am I doing something wrong? I just get a blank page when I do a search. and is it showing up in the correct spot?


https://vborg.vbsupport.ru/external/2008/07/81.jpg

davidw
07-07-2008, 02:01 PM
Great Mod. Can the color of the search results (changing the white background) be altered?

Thanks!

Marcos
All that is edited when you set up or reset your adsense for search. Go back to the adsense for search page and recustomize it and then put the new partner-pub in there (your id itself will not change, just what is after it).

am I doing something wrong? I just get a blank page when I do a search. and is it showing up in the correct spot?Yeah, something isn't right with that page. You may want to reimport the product and ensure you have the correct path on your searchresults.php page. Going to that page you should see a minimum of your header, footer, navbar, and an iframe.

jlew24asu
07-07-2008, 02:22 PM
Yeah, something isn't right with that page. You may want to reimport the product and ensure you have the correct path on your searchresults.php page. Going to that page you should see a minimum of your header, footer, navbar, and an iframe.

when editing the search.php do I keep the ' www.chicagophotoshop.com/forums.....' that are inbetween the (...)

davidw
07-07-2008, 02:38 PM
You never have to edit the search.php page - its the searchresults.php page. That page has a line that says chdir('/path/to/your/forums/'); - this should be edited to match yours - such as /home/www/site/forums/ (whatever yours is).

jlew24asu
07-07-2008, 02:53 PM
You never have to edit the search.php page - its the searchresults.php page. That page has a line that says chdir('/path/to/your/forums/'); - this should be edited to match yours - such as /home/www/site/forums/ (whatever yours is).

right, thats what I meant, searchresults.php.

I'm getting confused by the example here..

Step 1:
Edit chdir('/path/to/your/forums/'); in searchresults.php - put the correct value then upload to your forum's root.

Example: http://www.yoursite.com/searchresults.php


I entered the full UNIX path in chdir. do I add the site like your example? (http://www.chicagophotoshop.com/forums/searchresults.php) ?

LAJAURIA
07-08-2008, 12:31 AM
If you are seeing something like this: partner-pub-0123456789012345:lnucfbm5dtp

that's ok.!!


Please ensure you have set up the chdir in the searchresults.php file and that the admincp options point directly to that file (you can usually open the searchresults.php page and then copy and paste the URL into the admincp options).

in the searchresults.php file, i seted up the chdir:

./search/

and in the admincp:

./search/



the file is in the folder: www.mysite.com/search



but i get the FORBIDDEN ERROR.


Forbidden

You don't have permission to access /search/ on this server.

davidw
07-08-2008, 12:46 AM
right, thats what I meant, searchresults.php.

I'm getting confused by the example here..

Step 1:
Edit chdir('/path/to/your/forums/'); in searchresults.php - put the correct value then upload to your forum's root.

Example: http://www.yoursite.com/searchresults.php


I entered the full UNIX path in chdir. do I add the site like your example? (http://www.chicagophotoshop.com/forums/searchresults.php) ?
That would explain a bit.
It needs to be more like /your/server/www/forums/

The forums root example is where to upload the file to.


that's ok.!!


in the searchresults.php file, i seted up the chdir:

./search/

and in the admincp:

./search/



the file is in the folder: www.mysite.com/search



but i get the FORBIDDEN ERROR.
The chdir in the searchresults.php file should be the path as in the above response to jlew24asu
The admincp path should be http://www.yoursite.com/forums/searchresults.php (something like that).

LAJAURIA
07-08-2008, 01:19 AM
not working yet.

searchresults.php is in www.mysite.com/gsearch/searchresults.php


in the file chmod, i put www.buforo.com/gsearch/


in the admincp: http://www.buforo.com/gsearch/searchresults.php



not working!! please help.

davidw
07-08-2008, 01:40 AM
The location of where you put the searchresults.php file is not a problem and the admincp location is good too. However, the chdir in the searchresults.php file should be something like

/usr/var/home/www/

not

www.buforo.com/gsearch/

You may need to ask your site host for this information. When you get that info, it should work fine.

LAJAURIA
07-08-2008, 03:39 AM
I still couldn't solve the problem:

this is the error:


Warning: chdir() [function.chdir]: No such file or directory (errno 2) in /www/buforo.com/htdocs/gsearch/searchresults.php on line 8

Warning: require_once(./global.php) [function.require-once]: failed to open stream: No such file or directory in /www/buforo.com/htdocs/gsearch/searchresults.php on line 19

Fatal error: require_once() [function.require]: Failed opening required './global.php' (include_path='./:/usr/local/php5/lib/php') in /www/buforo.com/htdocs/gsearch/searchresults.php on line 19


this is the searchresult.php file:


<?php
// ####################### SET PHP ENVIRONMENT ###########################
error_reporting(E_ALL & ~E_NOTICE);

// #################### DEFINE IMPORTANT CONSTANTS #######################
define('NO_REGISTER_GLOBALS', 1);
define('THIS_SCRIPT', 'searchresults');
chdir('./htdocs/gsearch/');

// ################### PRE-CACHE TEMPLATES AND DATA ######################
// pre-cache templates used by all actions
$globaltemplates = array(
'google_navadsearch',
'google_siteadsearch',
'google_searchresults'
);

// ######################### REQUIRE BACK-END ############################
require_once('./global.php');

// ######################## START MAIN SCRIPT ############################
$navbits = array();
$navbits[$parent] = 'Search Results';
$navbits = construct_navbits($navbits);
eval('$navbar = "' . fetch_template('navbar') . '";');
eval('print_output("' . fetch_template('google_searchresults') . '");');


this is the admincp config:

http://img79.imageshack.us/img79/7320/partnerfz3.jpg



where am I failing??

LAJAURIA
07-08-2008, 04:10 AM
I think I fixed some problems. I found the path.

Now my searchresults.php file seems like this:


<?php
// ####################### SET PHP ENVIRONMENT ###########################
error_reporting(E_ALL & ~E_NOTICE);

// #################### DEFINE IMPORTANT CONSTANTS #######################
define('NO_REGISTER_GLOBALS', 1);
define('THIS_SCRIPT', 'searchresults');
chdir('/www/buforo.com/htdocs/gsearch/');

// ################### PRE-CACHE TEMPLATES AND DATA ######################
// pre-cache templates used by all actions
$globaltemplates = array(
'google_navadsearch',
'google_siteadsearch',
'google_searchresults'
);

// ######################### REQUIRE BACK-END ############################
require_once('./global.php');

// ######################## START MAIN SCRIPT ############################
$navbits = array();
$navbits[$parent] = 'Search Results';
$navbits = construct_navbits($navbits);
eval('$navbar = "' . fetch_template('navbar') . '";');
eval('print_output("' . fetch_template('google_searchresults') . '");');


but, the error now is the following:

Warning: require_once(./global.php) [function.require-once]: failed to open stream: No such file or directory in /www/buforo.com/htdocs/gsearch/searchresults.php on line 19

Fatal error: require_once() [function.require]: Failed opening required './global.php' (include_path='./:/usr/local/php5/lib/php') in /www/buforo.com/htdocs/gsearch/searchresults.php on line 19

davidw
07-08-2008, 10:41 AM
the chdir is to your forums, not to your search (that way you can use your vbulletin's functions).
Try using this: chdir('/www/buforo.com/htdocs/');

jlew24asu
07-08-2008, 11:02 AM
That would explain a bit.
It needs to be more like /your/server/www/forums/

The forums root example is where to upload the file to.



The chdir in the searchresults.php file should be the path as in the above response to jlew24asu
The admincp path should be http://www.yoursite.com/forums/searchresults.php (something like that).

gotcha. but I did that. I entered in my full unix path and still no dice.

this is the entire line...

chdir(/editforprivacy/www/misc/chicagophotoshop/public_html/forums/)

am I missing something in between the (...) ??

LAJAURIA
07-08-2008, 12:12 PM
the chdir is to your forums, not to your search (that way you can use your vbulletin's functions).
Try using this: chdir('/www/buforo.com/htdocs/');


yes!!!

now it works..!!


thanks a lot for your help....


now I'm proud of clicking on INSTALLED..





a $$$ question: what about AdSense?? does this hack work showing payed advertisments of Google???

I've made some searchings, and it never shows "Sponsored Links" ...

davidw
07-08-2008, 12:28 PM
gotcha. but I did that. I entered in my full unix path and still no dice.

this is the entire line...

chdir(/editforprivacy/www/misc/chicagophotoshop/public_html/forums/)

am I missing something in between the (...) ??
Yes, you are missing two ' in there
chdir('/editforprivacy/www/misc/chicagophotoshop/public_html/forums/');

yes!!!

now it works..!!


thanks a lot for your help....


now I'm proud of clicking on INSTALLED..





a $$$ question: what about AdSense?? does this hack work showing payed advertisments of Google???

I've made some searchings, and it never shows "Sponsored Links" ...This shows sponsored links based on how you set it up in the adsense page. However, you still get paid based on your site's click-throughs. Check your adsense account for this.

jlew24asu
07-08-2008, 12:53 PM
Yes, you are missing two ' in there
chdir('/editforprivacy/www/misc/chicagophotoshop/public_html/forums/');



getting closer!! :D now I get this...

davidw
07-08-2008, 01:19 PM
Now all you have to do is put your full partner-pub number in the admincp options. This is what gives you the layout for the iframe results. :)

jlew24asu
07-08-2008, 01:31 PM
It Works!!!!!

THANK YOU DAVID

jlew24asu
07-08-2008, 01:43 PM
since I'm on a roll, is there a way I can add this outside of my navbar. maybe under it, in plain view?

davidw
07-09-2008, 10:57 AM
$google_siteadsearch is already set up for something like that - you can put that most places. You can also take the contents of that template and plug them wherever you need to and modify them where appropriate if need be.

jlew24asu
07-09-2008, 11:44 AM
$google_siteadsearch is already set up for something like that - you can put that most places. You can also take the contents of that template and plug them wherever you need to and modify them where appropriate if need be.

easier said then done ;)


:erm:

davidw
07-09-2008, 11:58 AM
How big, what size, location, etc. did you have in mind?

TsirhCitna
07-13-2008, 12:33 AM
I get this error from Google on my searchresults in the iframe:

Error Bad Request

Your client has issued a malformed or illegal request.

davidw
07-13-2008, 02:30 AM
Example: partner-pub-0123456789012345:lnucfbm5dtp
Something like this is what you need in your admincp options.

jlew24asu
07-15-2008, 11:46 AM
edit

jlew24asu
07-15-2008, 11:47 AM
How big, what size, location, etc. did you have in mind?

same size as it is now. just below the navbar. :):cool: :up:

davidw
07-15-2008, 12:28 PM
Do you just want a small search box with a go button? Also, do you want it any specific location? (left side/right side?)

jlew24asu
07-15-2008, 01:38 PM
Do you just want a small search box with a go button? Also, do you want it any specific location? (left side/right side?)

small search box with go button, yes. I believe it should say google search inside the box. left side will work.

:up:

davidw
07-15-2008, 02:32 PM
let me see what I can do (when I get a chance).

djbaxter
07-15-2008, 02:37 PM
I've done an overhaul on this and you will need to resetup your adsense for search account for this to work. If you aren't happy with that, please use the 3.6 version of this, which works fine for 3.7 from what I've been told.

When you resetup your adsense, you will get a new pub ID - this one includes your previous pub and tacks on your GALT (which is set up when you resetup your adsense account).

Example: partner-pub-0123456789012345:lnucfbm5dtp

You will need this for step 3. If you do not have this, you will see an error.

I'm not sure I understand this. First, why is this required? Second, how do I do it, since I have an existing AdSense publisher account and don't want to have to change it for all my sites.

davidw
07-15-2008, 03:46 PM
If your account looks similar to the example - then no worries :)
Example: partner-pub-0123456789012345:lnucfbm5dtp

If you need to do that, just go log into your Google adsense account - adsense for search it should prompt you.

The reason why it is required is because if you do not have the extended information (after the colon : ) then you will get a Bad Request error message from Google. This is only for the latest version - if yours works fine, then don't worry about it.

davidw
07-15-2008, 06:44 PM
small search box with go button, yes. I believe it should say google search inside the box. left side will work.

:up:

I've got a prototype working - but for some reason it is NOT showing the Google wording inside as it should. Try this one out and let me know - put $google_anywhere where you want it. I've got it working on my forumhome (left side). It is possible it is because the script is already being called in the navbar - that I've not tested.

jlew24asu
07-15-2008, 07:02 PM
nice, thanks. I'll try it out. do I need to remove the original?

where exactly do I put $google_anywhere

find...

add below/after....

davidw
07-15-2008, 07:25 PM
No, just import and overwrite.

You can put it where you like.

I added mine to my forumhome template just below the <!-- Main --> area.

jlew24asu
07-15-2008, 07:37 PM
hmmm. ok that worked. but it doesnt say google search anywhere. (thanks again for the quick response on my requests)

edit: it now says Google custom search in the box. (didnt at first)

I like yours better though from your site. you have a custom field above the box that says google search.

davidw
07-15-2008, 11:04 PM
I can't really control the javascript as it comes from Google, but if you are getting it to work - Great!

I like yours better though from your site. you have a custom field above the box that says google search.From which do you see this?

jlew24asu
07-15-2008, 11:16 PM
I can't really control the javascript as it comes from Google, but if you are getting it to work - Great!

yup. good work!


From which do you see this?

on Christianboards.org on the upper left. although I'm guessing that isnt this hack...

davidw
07-16-2008, 12:04 AM
can you post a screenshot :) - I can probably help you out either way - if it is on the home page this it is this hack (its the Step 5 above)

jlew24asu
07-16-2008, 12:33 AM
can you post a screenshot :) - I can probably help you out either way - if it is on the home page this it is this hack (its the Step 5 above)

oooo its (step5) for vbadvanced. got it. I'll be installing this again on another bpard im making as we speak. i'll let you know how that goes. thanks for your help!!!

davidw
07-16-2008, 12:41 AM
No problem :)

jlew24asu
07-18-2008, 09:08 PM
ok david. I followed the instructions but its not showing up on my CPMS homepage

davidw
07-18-2008, 11:06 PM
What version of vbadvanced is that?

jlew24asu
07-18-2008, 11:38 PM
v3.0.1

this is for a forum I just created

www.sundeviltalk.com

davidw
07-19-2008, 12:19 AM
Did you disable your current search for the home page and enable the new one you created (set active). The one I see goes to search.php page rather than searchresults.php.

jlew24asu
07-19-2008, 12:58 AM
Did you disable your current search for the home page and enable the new one you created (set active). The one I see goes to search.php page rather than searchresults.php.

how do I do that? :)

davidw
07-19-2008, 11:46 AM
Assuming you have created the module in the last step above, to disable the old,
vBa CMPS => Edit Modules => [Search Forums] Click Go next to Edit Module
Under Main Options
Active => Set to No
Click Save

Then go back, and make sure the other Google Search module is set to active.

Also, check your Quick Permissions Editor (and look under Modules) - Find your Google Search and make sure everyone you want to be able to view it can.

jlew24asu
07-19-2008, 12:20 PM
ah. ok. done! thanks again. you are very helpful

jlew24asu
07-19-2008, 12:43 PM
how anyone would not want this on their site is beyond me

davidw
07-19-2008, 12:59 PM
Thanks :)
Btw, if you want me to look at your CMPS setup, PM me enough info to get me access to the CMPS in the admin and I'll look at it when I get a chance. I may sit down this week and totally rewrite the instructions.

jlew24asu
07-20-2008, 02:00 AM
actually something is wrong. when doing a search it comes up www.yoursite/forums/seachresults.php (etc etc)

did I not edit the php correctly?

davidw
07-20-2008, 11:59 AM
That is an admincp option (last option). Your forum's path.
or
That is Module Wrapper Template Options (last step above)
Form Code Replace default code with ...
(you've got to put your site in there)

jlew24asu
07-20-2008, 05:04 PM
getting closer :) now I get

Not Found
The requested URL /asu_forum/searchresults.php was not found on this server.

but it is there!

MadK
07-20-2008, 09:24 PM
I have about 7 queries done today, but my Google Adsense Search report shows $0.00.

Is everything alright with the way I setup the custom search? All were from different IPs.

Is it a problem if my searchresults.php is hosted in the root folder (www.mafia-mp.com) and my forum is hosted on /forum/ ? The search results show up properly.

davidw
07-21-2008, 11:16 AM
getting closer :) now I get

Not Found
The requested URL /asu_forum/searchresults.php was not found on this server.

but it is there!It needs to be the full URL
http://www. ... /asu_forum/searchresults.php

I have about 7 queries done today, but my Google Adsense Search report shows $0.00.

Is everything alright with the way I setup the custom search? All were from different IPs.

Is it a problem if my searchresults.php is hosted in the root folder (www.mafia-mp.com) and my forum is hosted on /forum/ ? The search results show up properly.
I am not sure how long it takes to show up, but as long as you have your full partner-pub- number and there are no errors and the user does the full click-through by Google's standards, you will/should get what credits that are appropriate. I know I did a couple tests a while back and one showed up, and one didn't - it was for a couple pennies, but it still worked. If there are no errors, I would have to say that there is a small waiting period (days probably). But I've not really looked on that side of things. I do not get that much traffic, but I have still earned a few dollars in the past couple months.

jlew24asu
07-21-2008, 11:36 AM
It needs to be the full URL
http://www. ... /asu_forum/searchresults.php



ok, so where am I going wrong? I have the full URL in admincp, and in the code in the CMPS module. :(

djbaxter
07-21-2008, 11:37 AM
I have about 7 queries done today, but my Google Adsense Search report shows $0.00.

Is everything alright with the way I setup the custom search? All were from different IPs.

Is it a problem if my searchresults.php is hosted in the root folder (www.mafia-mp.com) and my forum is hosted on /forum/ ? The search results show up properly.

First, your AdSense stats aren't updated immediately.

Second, you don't get paid per query. You get paid when someone clicks on one of the advertising links appearing in the search results.

davidw
07-21-2008, 01:00 PM
ok, so where am I going wrong? I have the full URL in admincp, and in the code in the CMPS module. :(Your searchresults.php file is located
Here: http://www. ... /searchresults.php
not here: http://www. ... /asu_forum/searchresults.php

MadK
07-21-2008, 01:01 PM
First, your AdSense stats aren't updated immediately.

Second, you don't get paid per query. You get paid when someone clicks on one of the advertising links appearing in the search results.

I know my AdSense stats are not updated immediately, and I thank you for clearing that up. My thanks go to davidw, too! :)

jlew24asu
07-21-2008, 01:36 PM
Your searchresults.php file is located
Here: http://www. ... /searchresults.php
not here: http://www. ... /asu_forum/searchresults.php

as always, you come through. thank you for your patience with me :) all is working now!

davidw
07-21-2008, 01:53 PM
No problem

MissKalunji
07-21-2008, 06:08 PM
Thanks david you saved me the time to do it all by myself.
*thumbs up*

davidw
07-21-2008, 06:53 PM
Glad it worked out for you :)

MadK
07-21-2008, 07:30 PM
davidw, could you tell me how you made it for Google and your own site results to show up. I have tried to modify it in Google Custom Search site, but it shows Google results and my forum results at the end (page 10)

Here's what I tried:

Search the entire web but emphasize included sites.

In the sites section, I added forum.+++++-mp.com, +++++-mp.com, wiki.+++++-mp.com

jlew24asu
07-21-2008, 08:50 PM
I have about 7 queries done today, but my Google Adsense Search report shows $0.00.

Is everything alright with the way I setup the custom search? All were from different IPs.

Is it a problem if my searchresults.php is hosted in the root folder (www.mafia-mp.com) and my forum is hosted on /forum/ ? The search results show up properly.

how much clicks came from those searches? this has happened to be before as well. I dont think you are doing anything wrong. it has something to do with google on how they run things. (thats my guess)

davidw
07-21-2008, 11:28 PM
davidw, could you tell me how you made it for Google and your own site results to show up. I have tried to modify it in Google Custom Search site, but it shows Google results and my forum results at the end (page 10)Using your sites, this is what I did. I went to the Adsense setup and put in your sites along with Google (for my account, I used my website). See screenshot.

Caddyman
07-22-2008, 11:05 AM
ok im installed on talkdelaware.com

edit the path in searchresults.php
added the right pub id in ACP
all good

now

if i search anything on the navbar dropdown, it brings me to my vB page for no results
this page http://www.talkdelaware.com/search.php?do=process
says this Please specify some words or valid user names to search on. There were no matches for those that you specified.

if i search from your box that i added on that page i then get the google results in a iframe like i should.

why is this? sorry if asked before :(

davidw
07-22-2008, 12:12 PM
Make sure your entry in the admincp options says this:
http://www.talkdelaware.com/searchresults.php

Caddyman
07-22-2008, 12:16 PM
yup, that is right in the ACP :(

davidw
07-22-2008, 12:43 PM
Do you have a test account I can use to look at it? PM me the info if you have one.

MadK
07-22-2008, 02:04 PM
Using your sites, this is what I did. I went to the Adsense setup and put in your sites along with Google (for my account, I used my website). See screenshot.

This is what I've done; however, my forum results are in the end. Not first, like I expected them to be.

davidw
07-22-2008, 02:47 PM
Have you tried reversing the order of the sites? It's possible Google just works that way.

tpearl5
07-22-2008, 04:39 PM
Ah, I had already done something similar to this but not as integrated. I will check this out.

MadK
07-22-2008, 05:11 PM
Have you tried reversing the order of the sites? It's possible Google just works that way.

Nope! :(

davidw
07-22-2008, 06:44 PM
Do you have a test account I can look at?

gwerzal
07-30-2008, 12:34 AM
Sorry if its a stupid question but how do you resetup your adsense for search?

Do you mean set up another acount?

Will you get in trouble with google if you have 2 acounts?

Cheers

Ben

Videx
07-30-2008, 12:38 AM
Sorry if its a stupid question but how do you resetup your adsense for search?

Do you mean set up another acount?No. Just log in to adsense and go to Adsense Setup>Adsense for Search. Presumably you could set up a thousand of these if you wanted.

davidw
07-30-2008, 12:42 AM
Exactly - it will prompt you for new user information only if you are on the old account setup, but just like Videx said.

scoles15
08-05-2008, 03:52 PM
Installed and working great:up::up: Thanks. I am using vBa 3.01 and I decided to integrate searchresults.php. No joy:(. Basically, I get about 3 warning messages that say the 3 array_merges in vba_cmps_include_template.php $phasegroups, $specialtemplates, and $globaltemplates are not valid arrays. Of course they are and the integration seems to work for any other page I have used. Any ideas??

BTW, I did add the three variables mentioned in the instructions.

Thanks

davidw
08-05-2008, 05:24 PM
Do you have a test account I can use with a location to where this is occurring? When do you see the warning (at what point - after you click Go?)

scoles15
08-05-2008, 10:56 PM
It is after you press Go and when it goes to searchresults.php Just in case, I wasn't clear. It works fine, except admincp->vBa CMPS->Integration. I just put it back that way so you can see the failure. I am not using vBa Module for the search form.

www.ncwoodworker.net I'll send account info in a few minutes via PM. I'll make you an Admin so you play with the vBa CMPS settings and/or plugin settings

zelnik
08-08-2008, 09:49 AM
Hi hoping you can help me, Have installed the addon and everything is setup in the admincp

When i click search or if i try and access searchresults.php by itself I get the following error:

Content Encoding Error


The page you are trying to view cannot be shown because it uses an invalid or unsupported form of compression.

The page you are trying to view cannot be

shown because it uses an invalid or unsupported form of compression.


* Please contact the web site owners to inform them of this problem

I have tried uploading a fresh unedited file to see if at least that error would stop but I get the same..

Please help!

davidw
08-08-2008, 10:57 AM
Part of the reason is the unedited file. The file must be edited.

Step 1:
Edit chdir('/path/to/your/forums/'); in searchresults.php - put the correct value then upload to your forum's root.

If you have to, check with other applications or with your server to find out what the correct value should be - an error message will sometimes show you the correct value.

Also, make sure your adsense partner code looks like this partner-pub-0123456789012345:lnucfbm5dtp

If you want, PM me the site where this is happening and a test login for looking at it.

zelnik
08-08-2008, 04:05 PM
Thank you David everything working just great now.

You were correct it was a path issue and had to ask my host for the full path as when you ftp in it doesn't show you!

Thanks once again!

davidw
08-08-2008, 04:50 PM
Your welcome - glad I could help :)

GavM
08-13-2008, 09:45 PM
Can someone help me here? I'm not sure how to resetup my account to get the extra bit of code on the end?

Step by step instructions would be greatly appreciated :D!!!

davidw
08-13-2008, 09:56 PM
Go to http://www.google.com/adsense/ and login
Click on the Adsense Setup tab
Click on AdSense for Search Improved! link
Fill this out how you want and at the end you will get your new code.

davidw
08-18-2008, 12:25 AM
Did that help?

smirkley
08-27-2008, 03:10 AM
One heck ofa hack! kudos!

And thanks.

Two questions,...

1 - is there a way to make the google search result popup in a new window when you click on one of the results in the listing? I am just trying to keep my members with my site still there, and not redirected away, know what I mean?

2 - and this may be a bug or install issue. But concerning step 4 and integrating the google search on the advanced search page. The google box shows up, but without the google custom search watermark inside the search box. Also, I noticed that I get a mouseover from an alt text in the whole google search block, that says nohilite.
Step 4 looked easy enough to do, but I fear I musta missed something somewhere as these items are anomolies from your images you posted in this topic here.

Thanks in advance.

davidw
08-27-2008, 11:00 AM
1 - The page stays within your site (that's the reason for the iframe) - if for some reason you are being taken to google's site, show me where this is happening and I will help you fix this.

2 - Some people can get the Google Custom Search image to show up while others don't. On my site, it shows up on some styles while other styles won't show it. I believe this has to do with other code running as it has no issues on my site with the default style. However, I am not 100% certain on this, just a guess. I'll look into the nohilite issues.

smirkley
08-27-2008, 05:07 PM
Thank for your reply.

1 - I need to clarify,.. The search feature and results page of google links DO IN FACT show up embedded within my site. I was basically wondering if there was a way to make a clicked-on result link on that page, pop up into a new browser window. Or is that a function of the google result page code? Right now, when one clicks on a google result link that is in fact inside my site page, the user is taken to the clicked on links site, as expected, but it loads in the same browser window and not in its own pop up browser. This may in fact be normal operation, and may not be alterable.

2 - Thanks for looking into it. I may try some fiddling on my install to see if I can find a way to make the watermark in the search box work properly too. Hopefully we can find a way. I am currently testing on VB default style, and as of today, on 3.7.3, but I do have some other modifications I am testing concurrently on the same site.

Regardless, the mod works great overall.

davidw
08-27-2008, 10:57 PM
Ahh, it might be possible to do such but my code was based on theirs and how it functioned. This is something I can look into as a javascript popup of a page shouldn't be that hard to code - call vs popup isn't that much difference. However, after tonight it will probably be next week before I can look into this as I will be out of pocket.

I am glad you appreciate this mod. I am looking into the idea of other adsense ideas in the future.

Idlehearts
09-07-2008, 11:07 AM
Google Error

Bad Request

Your client has issued a malformed or illegal request.


how to rectify this

davidw
09-07-2008, 11:27 PM
When you resetup your adsense, you will get a new pub ID - this one includes your previous pub and tacks on your GALT (which is set up when you resetup your adsense account).

Example: partner-pub-0123456789012345:lnucfbm5dtp

You will need this for step 3. If you do not have this, you will see an error.
You have seen this error. Google is looking for your information.

luket79
09-08-2008, 03:04 AM
Is the idea to have it search just your site or the whole web? The title of the search box suggests both, what should I do? Also, my template doesnt have the search dropdown box, how do I enable that?

davidw
09-08-2008, 03:13 AM
You can have it search whatever you want. When you set it up, you get the choice to search whatever you put in the box
Site 1
Site 2
Site 3
et al.

I set mine up as
my site
Google.com

But what you do is totally your choice. Which template doesn't have the search dropdown box? Navbar?

Idlehearts
09-08-2008, 06:56 AM
Google Error

Bad Request

Your client has issued a malformed or illegal request.


how to rectify this

Any help

davidw
09-08-2008, 09:17 AM
<a href="https://vborg.vbsupport.ru/showpost.php?p=1617006&postcount=149" target="_blank">https://vborg.vbsupport.ru/showp...&postcount=149</a>

dtv100
09-08-2008, 09:30 AM
any way to move google search on top of forum search ?
also those ads that show in page result are ours of someone else?

thanks for this addon .

Idlehearts
09-08-2008, 03:41 PM
I dint get what do you mean by that sentence

what google is looking out,

i entered the correct and new pub id as you're example over there

thanks

You have seen this error. Google is looking for your information.

luket79
09-08-2008, 08:56 PM
You can have it search whatever you want. When you set it up, you get the choice to search whatever you put in the box
Site 1
Site 2
Site 3
et al.

I set mine up as
my site
Google.com

But what you do is totally your choice. Which template doesn't have the search dropdown box? Navbar?

Thanks for the heads up. I didn't even think of putting google.com in the list of sites.

My url is dnlodge. The Navbar holds the search button. I've looked in the manual but it seems to have all of the necessary js called.

Thanks for any help.

davidw
09-10-2008, 08:26 PM
Sorry for the delay everyone, I've been sick - still am sick.
any way to move google search on top of forum search ?
also those ads that show in page result are ours of someone else?

thanks for this addon .I'm using the hook, but I can probably make a manual template. Those ads are from google - they are part of the adsense as I don't have a way to disable them.

I dint get what do you mean by that sentence

what google is looking out,

i entered the correct and new pub id as you're example over there

thanksYou entered the correct and new pub id and are still having a bad request? Can you PM me where this is happening?

Thanks for the heads up. I didn't even think of putting google.com in the list of sites.

My url is dnlodge. The Navbar holds the search button. I've looked in the manual but it seems to have all of the necessary js called.

Thanks for any help.Ahh, your site's Search drop down box has been altered. What you can do is create a new default style and copy the contents of the navbar to your normal style and then make whatever changes you need to. This will give you your Search drop-down. (or even easier - click revert on the navbar template - and then go back and make necessary changes).

luket79
09-10-2008, 10:52 PM
Is there a way to change the "Search Google / Search Forums Using Google" text to something else? I see it in the xml file but do I have to re-install to change that?

davidw
09-11-2008, 10:57 AM
Reuploading the product is the cleanest way to do it, but is not the only way to do it. You can also edit your google_siteadsearch template and change it there. Until I have everything phrased, these are the two ways to do it. If you change it in the template, you will have to revert the template if there are major changes to the template, which doesn't occur often.

luket79
09-11-2008, 10:09 PM
Thanks! Great MOD!

davidw
09-11-2008, 10:29 PM
Glad you like.

dtv100
09-12-2008, 12:05 AM
[QUOTE=davidw;1619390]Originally Posted by dtv100
any way to move google search on top of forum search ?
also those ads that show in page result are ours of someone else?

thanks for this addon .
I'm using the hook, but I can probably make a manual template. Those ads are from google - they are part of the adsense as I don't have a way to disable them.
QUOTE]

hope you get better soon and when you do please I would love to have a manual template
that way google search is on top and my members use it more often make my site load lower .
thanks again for reply .

davidw
09-12-2008, 12:12 AM
It will probably be towards this weekend - but shouldn't be too hard. I might even have time tomorrow if it is slow.

Pete2007
09-14-2008, 12:28 PM
resetup your adsense for search account for this to work

What will happen if I don't resetup my adsense account? And use my current account ID?

Videx
09-15-2008, 12:29 PM
What will happen if I don't resetup my adsense account? And use my current account ID?First, your nose will fall off for not taking the time to read older posts. As very clearly explained about a thousand times already, if you try to use an older style ID number you'll get errors.

Pete2007
09-15-2008, 12:57 PM
First, your nose will fall off for not taking the time to read older posts. As very clearly explained about a thousand times already, if you try to use an older style ID number you'll get errors.

I do apologise.

One last question, is this legal, and perfectly ok with google?

davidw
09-16-2008, 03:32 PM
Yes, this is perfectly legal. All I did was use google's code and modified it for integration with vBulletin. Everything goes through Google (it is set up that way). This modification only alters how it is displayed.

davidw
09-16-2008, 03:34 PM
any way to move google search on top of forum search ?I should have this done this week. I'm behind due to being sick and other issues.

davidw
09-18-2008, 05:09 PM
Find this in your navbar template:
<if condition="$show['popups']">
<!-- NAVBAR POPUP MENUS -->

<if condition="$show['searchbuttons']">
<!-- header quick search form -->
<div class="vbmenu_popup" id="navbar_search_menu" style="display:none" align="$stylevar[left]">
<table cellpadding="4" cellspacing="1" border="0">

Add after:
<tr>
<form action="{$vboptions['google_forum_path']}" id="cse-search-box" target="_top"><td class="thead">Search Site / Google</td>
</tr>
<tr>
<td class="vbmenu_option" title="nohilite">
<table border="0">
<tr>
<td nowrap="nowrap">
<div>
<input type="hidden" name="cx" value="{$vboptions['google_pub']}" />
<input type="hidden" name="cof" value="FORID:9" />
<input type="text" name="q" size="{$vboptions['google_box_width_nav']}" />
<input type="submit" name="sa" value="Go" />
</div>
</td>
</tr>
</table>
</td></form><script type="text/javascript" src="http://www.google.com/coop/cse/brand?form=cse-search-box&amp;lang=en"></script>
</tr>

Save and reload.

dtv100
09-18-2008, 06:17 PM
thank you so much .

davidw
09-18-2008, 06:44 PM
No problem.

sarum
10-11-2008, 03:44 PM
Find this in your navbar template:
<if condition="$show['popups']">
<!-- NAVBAR POPUP MENUS -->

<if condition="$show['searchbuttons']">
<!-- header quick search form -->
<div class="vbmenu_popup" id="navbar_search_menu" style="display:none" align="$stylevar[left]">
<table cellpadding="4" cellspacing="1" border="0">

Add after:
<tr>
<form action="{$vboptions['google_forum_path']}" id="cse-search-box" target="_top"><td class="thead">Search Site / Google</td>
</tr>
<tr>
<td class="vbmenu_option" title="nohilite">
<table border="0">
<tr>
<td nowrap="nowrap">
<div>
<input type="hidden" name="cx" value="{$vboptions['google_pub']}" />
<input type="hidden" name="cof" value="FORID:9" />
<input type="text" name="q" size="{$vboptions['google_box_width_nav']}" />
<input type="submit" name="sa" value="Go" />
</div>
</td>
</tr>
</table>
</td></form><script type="text/javascript" src="http://www.google.com/coop/cse/brand?form=cse-search-box&amp;lang=en"></script>
</tr>

Save and reload.

and uncheck:
vB Google Search - Navbar global_setup_complete in manage plugins

if you dont you'll end up with two google search windows

The Realist
10-12-2008, 03:17 PM
For members whom are getting search errors when it comes to this part of the instructions:

When you resetup your adsense, you will get a new pub ID - this one includes your previous pub and tacks on your GALT (which is set up when you resetup your adsense account).

Example: partner-pub-0123456789012345:lnucfbm5dtp

In order to get the new adsense code as above you need to do the following within your adsense account to get hold of the new partner code.

Do the following:

1) Login to adsense
2) Click Adsense setup
3) Click "AdSense for Search" and pick what options you need and continue clicking next.
4) At the end you will get "Submit and get code"
5) Click the submit button and look at the code.

Within the code displayed you will get your new full partner adsense code that needs to be inputed within the "vB Google Search (Adsense)" under vbullletin options.

Hope this helps.

Regards.

badheeu
10-12-2008, 11:59 PM
Thankx hack is great,

Demo (http://www.kma.mv/forum/searchresults.php?cx=partner-pub-6877369213319044%3Aibz1qu-nd05&cof=FORID%3A9&q=KMA+forum&sa=Go#917)

Best Regards
KMA FORUM (http://www.kma.mv/forum/searchresults.php?cx=partner-pub-6877369213319044%3Aibz1qu-nd05&cof=FORID%3A9&q=KMA+forum&sa=Go#917)

Wizardjv
10-16-2008, 11:26 PM
Anyway to make this search your site? I mean it seems to be searching google and not the site it is on? Or would that stop from making anything in adsense? Just curious?

davidw
10-17-2008, 12:01 AM
When you set it up, you choose where you want it to search. You can default it to Google, or you can list a set of sites (including Google). If your search terms are relevant, depending on how strong of the search terms, they will show up closer to front/top of the list - as long as your site is in the list.

netzrate
10-17-2008, 03:36 PM
great, installd and it works!!

davidw
10-20-2008, 12:51 AM
Thanks

Chunky Monkey
11-05-2008, 04:04 PM
Is this still working for everyone? I installed it, added my new partner-pub-xxxxx:xxxx id, and verified in Google Analystics that searchresults.php is receiving traffic, but AdSense is showing no impressions or clicks...

Does it matter that none of my other adsense ads have "partner-" before the "pub"?

please help.

Chunky Monkey
11-05-2008, 04:05 PM
Also, the "FORID: X" in the code AdSense tells me to add to the side is different from the "FORID: X" displayed for the search when I view the vbulletin page source. Does that matter?

davidw
11-05-2008, 10:17 PM
What you need to have entered in your admincp is this:

partner-pub-0123456789012345:lnucfbm5dtp

but it looking like yours.

I just checked my Adsense (for search) page with Google, and surprisingly, I actually made money (which I usually don't.

Today's Earnings: $0.03
View payment history
TIP

If you have any payments questions, we encourage you to check out the Payment section of our support site: Learn more...
View:

Queries Clicks CTR eCPM [?] Earnings
AdSense for Search 32 1 3.12% $0.80 $0.03
view all AdSense for Search channels ?

AdSense for Content - Get started
AdSense for Mobile Content - Get started
AdSense for Feeds - Get started
Total Earnings $0.03
Keep in mind this will NOT have any bearing with your Adsense Ads (this is search only). Your Google Adsense for Content is different - and I've not checked to see if they use the same pub IDs as I don't use Adsense for Content. This is something I will be exploring in the near future.

Chunky Monkey
11-05-2008, 11:56 PM
Thank you. Do you know if it matters whether the X in FORID: X is the same in the code your plugin produces vs the code Google Adsense for Search provides? I copied the code you provided for how to put the adsense search above the default forum search, which may be why my X is different?

davidw
11-06-2008, 02:13 AM
You should be able to ignore that. That is why there is there is
lnucfbm5dtp
at the end of
partner-pub-0123456789012345:lnucfbm5dtp
The old style used that.

demoniavbh
11-18-2008, 01:05 PM
Can something be done to have a different search results page for each style?
I have many styles in my board and I'd like to have the search results page showing accordly in each of them...
Is it possible?

thanks

davidw
11-18-2008, 03:58 PM
Is this not working for each style? The way google's search itself is displayed is static, whereas the style the results are displayed in is dynamic to your style of your site. As far as the display page itself it should change depending on whatever style the user is using. As far as the results go, unfortunately I can only see one instance of a style - and that is based on your adsense setup. That is the part located here:

partner-pub-0123456789012345:lnucfbm5dtp

I hope that helps.

demoniavbh
11-18-2008, 09:16 PM
But I want to know if it's possible to have a different pub number for each style. i don't want my page to appear as in the third attachtment, with the search background in white and all that, I want it to fit my style, and I can only do that in the adsense setup as you said.

So, could it be possible to do it but changing templates, puting the pub code in templates? Something like in your other mod, in the 3.6. It would be like a mixture of both

davidw
11-19-2008, 11:11 AM
Can you show me an example of this? If you are using the old style pub number this will not work (this is based on the new pub number - as per example).

demoniavbh
11-20-2008, 09:30 AM
Well, I have a skin that is like attachment nr 1, dark blue, and I configured my adsense search results to look like that to fit my style.

But then, when I changed skin It looks like att. nr2, horrible.

So, I'd like to know if there could be the posibility of changing the pub ID for each style, so I can have style nr1 like the first attachment and style nr 2 like in att. nr3 (here I have changed the pub code to look as I want, but style nr 1 would be messed up)...

davidw
11-20-2008, 10:56 AM
The style itself is changing; the results themselves are a direct result of your pub code. They aren't part of your style but are actually in an iframe. That information is derived from google and the display is generated by the pub code. As far as I know you can only have one variant of the pub code - the most current one.

It might be possible to "trick" Google, by using several different pub codes by going to google.com/adsense and getting all the different variations that you want and then using those, but two things you have to think of...
1) This is displaying in an iframe so an iframe's results are going to be independent regardless of what style you are using and which condition applies
2) That it could be against Google's ToS.

While an if condition (if style = x) might work, there is no guarantee.

popowich
11-20-2008, 02:07 PM
Is it possible to move the "Search Site / Google" box above "Search Forums" in the search dropdown?

I'd like to make it more likely that members and visitors use the google search.

-Raymond

symptome
11-21-2008, 11:23 AM
Hi
Nice mod ... but

I just downloaded, installed and get to run. But in the configuration of the Google PUB ID still stays the text "starting with pub-" which isn't correct, as you already mentioned here in the thread.
Perhaps you want to correct it.

But the main thing:
I get 99% of my revenue from google.
If I would be banned because something of
http://www.google.com/coop/docs/cse/tos.html?gl=CH&hl=de
wouldn't be correct, it would be a catastrophy.

First, I wanted to ask, if you did notice all the rules of google. But then I saw, that you didn't. The search field in the advanced search doesn't show the google picture which is absolutely needed, as I think.

There are possibly other things. It would be great, if you could check this.
And last: users of this google search box have to write something in their board rules (privacy). You could note that too.

;)

Marcel

davidw
11-21-2008, 12:09 PM
On your statement about the rules, your link points to rules for Google Custom Search. This modification is for Google Adsense for Search. Google Custom Search is a different type of search, of which I do not use (although another member has created a modification for: https://vborg.vbsupport.ru/showthread.php?t=162072 ).

Secondly, javascript images displayed (if any) within the search boxes come from Google, not supplied in this modification.

To add to that, all images displayed within boxes will show up depending on the javascript you have running on your site. Certain styles will prevent the image from displaying as well as certain javascript running on websites - this has already previously been addressed.

In order to use this modification, you MUST use the full

partner-pub-0123456789012345:lnucfbm5dtp

number. If you do not have it, then either
A) you are using the wrong pub number
1) the pub number you are using is outdated
2) the pub number you are using is for a different Google search/application
B) you need to set up/reset your pub number by going to http://www.google.com/adsense

On your last statement - it is assumed that anything that you type in through this modification has the same level of privacy as if you went directly to Google.

davidw
11-21-2008, 12:15 PM
still stays the text "starting with pub-" which isn't correct, as you already mentioned here in the thread.If you can point out which post states that, I will correct it.

symptome
11-21-2008, 12:27 PM
If you can point out which post states that, I will correct it.

--> 48/49 ;)

symptome
11-21-2008, 12:39 PM
On your statement about the rules, your link points to rules for Google Custom Search. This modification is for Google Adsense for Search.

When I setup adsense I have to accept exactly those rules. (???)

Also: I see the google-image (custom search) in the navbar search. But there is no google-image in the advanced search.
Everything is running fine, so it can't be something with my browser ...

davidw
11-21-2008, 12:53 PM
--> 48/49 ;)Readme.txt file fixed

When I setup adsense I have to accept exactly those rules. (???)

Also: I see the google-image (custom search) in the navbar search. But there is no google-image in the advanced search.
Everything is running fine, so it can't be something with my browser ...I read the rules when I set up adsense to make sure this [modification] would be allowed under ToS and nothing stated against it. When I looked up Custom Search (to make a modification for that) I decided against it.

For the image:
https://vborg.vbsupport.ru/showpost.php?p=1607874&postcount=144
https://vborg.vbsupport.ru/showpost.php?p=1608119&postcount=145

symptome
11-21-2008, 01:03 PM
Readme.txt file fixed
check the configuration area too:
Found on https://www.google.com/adsense/account-settings under Property Information. starts with pub-
(you must start it with pub- and then your number).


Besides:
I had to change the templates like google_navadsearch to insert the following:
<input type="hidden" name="ie" value="ISO-8859-1" />

Without it, some words with swiss special characters couldn't be searched. Perhaps you want to make this choosable too.

davidw
11-21-2008, 01:17 PM
Wierd - see my attached image (partner-pub)

davidw
11-21-2008, 01:19 PM
I had to change the templates like google_navadsearch to insert the following:
<input type="hidden" name="ie" value="ISO-8859-1" />I originally had something like this in a previous beta build - but it wasn't universal, so I had to drop this - at least until I got it working for everyone.

symptome
11-21-2008, 01:23 PM
I can absolutely understand ;)
At this point you have a posting at least, that informs about that :)

I don't understand what you mean with post 198 ...

davidw
11-21-2008, 04:06 PM
You said on post 197
under Property Information. starts with pub-
(you must start it with pub- and then your number).

Mine doesn't start with pub- ; it starts with partner-pub- (as seen in the image)

symptome
11-21-2008, 04:17 PM
Yes, and that's the fault in the actual configuration.
When I enter the settings of this mod in vb-admin-area, then you got the above text there, talking about "starting with pub" ... which is wrong ;)

davidw
11-21-2008, 05:03 PM
Are you using partner-pub (as per example) or the old style pub-#######?
Do you have this working on your site?

symptome
11-21-2008, 05:51 PM
I'm using partner-pub
and as written ... yes it's running fine.
Installed today. ;)

davidw
11-21-2008, 06:15 PM
Oh good :)

Ozidoggy
11-21-2008, 08:49 PM
Great mod - Installed and working fine :)

bL@De
11-21-2008, 09:39 PM
Absolutely awesome, thank you very much!

Is there an easy way to change the colour of the search results to blend in with the background?

davidw
11-22-2008, 12:09 AM
Glad you like.

The only way to alter the color is to change it at http://www.google.com/adsense (during the setup).

Edit: You can go back and change your options there to your liking as many times as you need.

nike.stars
11-24-2008, 06:14 PM
hi there david, very nice mod indeed, i've installed it and it's working fine, i just a have problem when i try to integrate searchresults.php with one of my vbacmps page and it give me errors like this:


Warning: array_merge() [function.array-merge]: Argument #1 is not an array in [path]/includes/vba_cmps_include_template.php on line 19

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in [path]/includes/vba_cmps_include_template.php on line 42

Warning: Invalid argument supplied for foreach() in [path]/includes/init.php(293) : eval()'d code on line 93

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in [path]/includes/vba_cmps_include_top.php on line 599

Warning: array_merge() [function.array-merge]: Argument #2 is not an array in [path]/includes/vba_cmps_include_top.php on line 599

davidw
11-25-2008, 11:26 AM
How are you trying to integrate searchresults.php with your vbacmps page?

Which version of vbadvanced are you using?

nike.stars
11-25-2008, 01:42 PM
i'm using vbacmps v3.01

in admin CP -> vba cmps -> integration -> select the file "searchresults.php" then select the page i want to integrate with.

i've always integrate any new php files with this way, have you tested that?

davidw
11-25-2008, 02:23 PM
That's not the way this modification works. That would explain the errors. Perhaps it might work that way, of which I haven't tried, but I've uploaded instructions on integration with vBAdvanced 3.0+ that does work (at least with everyone who has used it that way).

https://vborg.vbsupport.ru/attachment.php?attachmentid=81186&d=1211579592

nike.stars
11-25-2008, 02:31 PM
@david
i've read the readme, it only contains how to modify the search module to make use this mod and i've done that.

what i meant was to integrate my vbacmps "page" to your searchresult.php resulting in showing my sidebar again as it should be.

davidw
11-25-2008, 02:52 PM
So you are wanting to create a separate page from the default searchresult.php page for vBAdvanced specifically (In essence having a vBAdvanced page and a searchresults.php page)?

nike.stars
11-26-2008, 03:43 AM
not separate page, but to integrate one of my vbacmps layout page (which already has sidebar in it).

The sidebar in that page already include the search module that has been modified according to your documentation.

davidw
11-26-2008, 10:56 AM
Give me a few days (fixing to go out of town until Sunday) and I'll see what I can do.

nike.stars
11-27-2008, 02:42 AM
Give me a few days (fixing to go out of town until Sunday) and I'll see what I can do.

thank you, looking forward to it :)

q8manar
11-30-2008, 08:01 AM
I have installed it but when i ded a test
the resualt page came epmty with this error :"

Warning: chdir() [function.chdir]: No such file or directory (errno 2) in /home/estad/public_html/vb/searchresults.php on line 8

could some body till me how i can fix it ?

davidw
11-30-2008, 09:38 PM
Can you give me a link to your searchresults.php (PM if needed)?

The Realist
12-18-2008, 12:44 PM
Im getting the same error after upgrading.

The error points to line 8 of the script and that says: chdir('/path/to/your/forums/');

Does that line need editing?

Regards

popowich
12-18-2008, 12:52 PM
Sounds like you need to edit that line and make it the real path to your forum root on the server.

-Raymond

davidw
12-18-2008, 01:01 PM
Step 1:
Edit chdir('/path/to/your/forums/'); in searchresults.php - put the correct value then upload to your forum's root. Hope that helps

The Realist
12-18-2008, 01:35 PM
Thanks.

The original post should make this point clear and in my case my path was: chdir('/home/xxxxx/public_html/');

Regards

mholtum
12-28-2008, 09:56 PM
Just installed and works perfectly.. Now I am just waiting for the money to start rolling in! Thanks

davidw
12-28-2008, 10:01 PM
Awesome! Glad it's working for you.

Goomzee
01-05-2009, 07:46 AM
i did every thing step by step but it's show error see the attachment
by the way my child path is

chdir('/home/xxxx/pub_html/forums/');

or should i write

www.mknexusonline.com

davidw
01-05-2009, 11:06 AM
<a href="https://vborg.vbsupport.ru/showpost.php?p=1617006&postcount=149" target="_blank">https://vborg.vbsupport.ru/showp...&postcount=149</a>

Goomzee
01-06-2009, 03:39 AM
i did everything but it still not working and by the way reset my Pub Id and if i reset my pub ID my all earning is also reset and start again with Zero/0

mholtum
01-06-2009, 03:55 AM
i did everything but it still not working and by the way reset my Pub Id and if i reset my pub ID my all earning is also reset and start again with Zero/0It didnt for me. Simply set up the search, not the main.

2dub
01-06-2009, 03:06 PM
I have installed it but when i ded a test
the resualt page came epmty with this error :"

Warning: chdir() [function.chdir]: No such file or directory (errno 2) in /home/estad/public_html/vb/searchresults.php on line 8


could some body till me how i can fix it ?

I had the same issue...


Update...
I just deleted that entire line and it now works fine.

davidw
01-06-2009, 03:53 PM
I had the same issue...


Update...
I just deleted that entire line and it now works fine.That will work fine unless your searchresults.php file is located is a folder other than the root.

MPDev
01-08-2009, 10:46 PM
Works great. I se eyou have multiple search results templates; is there a way to give people the option of searching my site or the web and giving results based on the selection (assuming I have two ads, one with just my site listed for results and another thats for searching google?)

davidw
01-08-2009, 11:50 PM
The way Google has it set up, what you search is tied to the information after your partner-pub key. The sites you search (one site or a list of sites) is tied to only one option.

The only way around that is multiple adsense accounts for one domain (which is against ToS) or to add a second option for searching the second domain/site you wish but have that second option not associated with your adsense account.

This version (https://vborg.vbsupport.ru/showthread.php?t=155199) gave you the option of choosing your site, Google, or wherever you wanted (as many choices as you wanted) but you were also using the old account. It is possible that I could modify the older version to work with the newer version to give that option - this would incur stripping the partner-pub key of the information including and after the ":" and also the word "partner-" - if it were to work. I have not tried it, but it is a possibility.

Goomzee
01-09-2009, 04:11 AM
That will work fine unless your searchresults.php file is located is a folder other than the root.

it's really nor work plz help

davidw
01-09-2009, 10:55 AM
PM me your site that this is occuring on so I can see this and if you want me fix this, PM me appropriate access.

Saviour
01-13-2009, 12:44 PM
Working on VB 3.8, however...not without the following problems:

Had to remove the line in searchresults.php which wanted the path to the forums.
Upon performing a search for the first time (and logged in) the search results page appeared fine...except for the fact it did not show me as logged in. Logging in from the search results page and ticking the "remember me" box fixed this. However, if one clears their cache, logs into the forum and performs a search, the same thing happens.

Other than that...all appears to be fine.

"Clicks Installed"...

davidw
01-13-2009, 01:08 PM
1. If your seachresults.php file is at the root, then removing that line or commenting it out will do no harm. If it is anywhere else, you will need that line in there otherwise you will have errors.
2. I have not tested this for 3.8 as I may be looking at redoing the adsense to integrate with 3.8's adsense features.

Saviour
01-13-2009, 01:12 PM
I didn't register my AdSense with vBulletin, so I don't have that feature included with my version of vBulletin.

If you do upgrade this mod for 3.8, you may want to make two versions...one for those who have AdSense built into the core...and those who don't.


Thanks for a great mod...I couldn't get the gtsearch version of this to work correctly with 3.8. However I've had better luck with this one.

You should be proud...:D

tansu
01-14-2009, 12:46 PM
check the configuration area too:
Found on https://www.google.com/adsense/account-settings under Property Information. starts with pub-
(you must start it with pub- and then your number).


Besides:
I had to change the templates like google_navadsearch to insert the following:
<input type="hidden" name="ie" value="ISO-8859-1" />

Without it, some words with swiss special characters couldn't be searched. Perhaps you want to make this choosable too.
Hi
I have the "special characters can not be searched" problem, too.
What exactly did you do to fix this?
Can you please explain it more clearly

davidw
01-14-2009, 12:56 PM
If all you are doing is editing templates, open each of the google templates and find the last line of each <input type="hidden" and then insert <input type="hidden" name="ie" value="ISO-8859-1" /> if your issue is similar.
For example:
<input type="hidden" name="cof" value="FORID:9" />
would then look like
<input type="hidden" name="cof" value="FORID:9" />
<input type="hidden" name="ie" value="ISO-8859-1" />

luket79
01-17-2009, 10:20 PM
Seems to work fine in 3.8 right out of the box for me....

Installed.

Saviour
01-26-2009, 09:31 PM
Well...I have it working, also...and have made it W3C XHTML compliant.

The only issues I have with this mod is that if I login to the forums...and run a Google search...the search results page comes up , but it doesn't show me as being logged in. Also the Google Search box is not displayed on the search results page.

However, if I login again, from the search results page...subsequent searches do show me as logged in. As far as I can tell...it's a cookie issue, but don't know where to start in order to fix the issue.

Any help is greatly appreciated...

Saviour
01-27-2009, 03:59 AM
David...I have noticed on your site, the search box doesn't show up on the results page. However, the Google Search image is located in the same position of your site as it is on mine.

Looking into the google search results template...you have the code for the results but not the search box. Are you going to be fixing this?

I've attached an image to show you exactly where the problem is...and you may already be aware of it. However, it really needs to be fixed in order for this to be truly complete.

If you take a look at what I have circled...this is the text that goes underneath the search box...but there's no search box...and it is totally throwing the page off. The search box should be located to the top/side/bottom...depending on where you want the search box to be...but your mod does not take this into account.

I certainly hope you can have a fix for those who have your mod installed.

Thank you...

davidw
01-27-2009, 10:45 AM
Well...I have it working, also...and have made it W3C XHTML compliant.

The only issues I have with this mod is that if I login to the forums...and run a Google search...the search results page comes up , but it doesn't show me as being logged in. Also the Google Search box is not displayed on the search results page.

However, if I login again, from the search results page...subsequent searches do show me as logged in. As far as I can tell...it's a cookie issue, but don't know where to start in order to fix the issue.

Any help is greatly appreciated...I cannot recreate this issue. I've tried logging out and logging back in and just doing a search and neither have me show as logged out.

Is this temporary - your next search while you are shown as logged out (although you are logged in) - or do you have to log in again?

David...I have noticed on your site, the search box doesn't show up on the results page. However, the Google Search image is located in the same position of your site as it is on mine.

Looking into the google search results template...you have the code for the results but not the search box. Are you going to be fixing this?

I've attached an image to show you exactly where the problem is...and you may already be aware of it. However, it really needs to be fixed in order for this to be truly complete.

If you take a look at what I have circled...this is the text that goes underneath the search box...but there's no search box...and it is totally throwing the page off. The search box should be located to the top/side/bottom...depending on where you want the search box to be...but your mod does not take this into account.

I certainly hope you can have a fix for those who have your mod installed.


Thank you...The only place the search box is supposed to show up on the search results page is where you have it placed - template-wise. If you have it in the navbar, unless something on your site is preventing it, it will continue to display in the navbar (as does mine correctly). Also, there is a standalone searchbox I coded for someone on one of these pages I believe that can be placed above the searchresults if you need one there.

The results page is a two-part function. The first part is the file/template with the iFrame and the second with the results of your search in that iFrame. The results of your search are displayed via http://www.google.com/afsonline/show_afs_search.js, not my modification. The template only acts as a host and has no control over the results once submitted. This includes any ads or the Google Custom Search image. I have no control over what is displayed so therefore I have no way of fixing that. If the results passed through your [the end user's] site, then that wouldn't be an issue.

tpearl5
01-27-2009, 04:48 PM
Great thanks! The only thing I would change is the class for the table in google_search from tcat to tborder

abqtj
02-02-2009, 07:35 PM
just installed...had to re-do a few things once or twice, but now it's working fine!

Gosef
02-13-2009, 02:11 PM
thanks a lot

davidw
02-14-2009, 01:27 AM
Glad you like it - Don't forget to click install :)

carrlos
02-19-2009, 02:09 PM
For example, somewhat edited, here is mine:
chdir('/home/xxxxxxx/christianboards/forums/');
This is my /path/to/my/forums/ since searchresults.php is located at forums/searchresults.php
You will never use a file in a path (a path is a directory). In your case, try taking out searchresults.php from your path.

chdir('/home/public_html/');

It has to be the full path to your searchresults.php, but don't include the file itself. Hope that helps :)

It would be really helpful if you would fix the following:

Update "Step 1" to state the above instead of putting a "http" example and giving us a headache. I follow good instructions and shouldn't have to read the whole thread. Over half of the problems in this thread are problems as a result.
In the admincp instructions, add partner- before pub-
Also, how about zipping up those files and making one download. :rolleyes:

davidw
02-19-2009, 02:54 PM
1. Updated step 1 the http part is where to upload the searchresults.php.

Forum Root Example: http://www.yoursite.com/searchresults.php
or another
Forum Root Example: http://www.yoursite.com/forums/searchresults.php

2. Where is this not located (where should this be located)?

3. I don't see a problem with zipping up everything