vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.7 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=228)
-   -   Integration with vBulletin - vB Google Search Cloud - SEO (https://vborg.vbsupport.ru/showthread.php?t=178714)

vmacedonia 05-21-2008 09:47 PM

Why most searched text isn't made with bigger font size, all the text phrases are the same?

Is this line in the PHP file have anything to do with the problem?

Code:

$datas[kw]=iconv("utf-8","Windows-1251",$datas[kw]);

NeutralizeR 05-21-2008 09:49 PM

Quote:

Originally Posted by vmacedonia (Post 1527336)
Why most searched text isn't made with bigger font size, all the text phrases are the same?

Is this line in the PHP file have anything to do with the problem?

Code:

$datas[kw]=iconv("utf-8","Windows-1251",$datas[kw]);

No.

Check your google_searches table. Check the hit counts there...

vmacedonia 05-21-2008 10:32 PM

I have added that code before the line:

Code:

if ($a > 0.8)
like in version 1.0.1.

Is this correct for the new version or the code must be on another place?

NeutralizeR 05-21-2008 11:18 PM

Quote:

Originally Posted by vmacedonia (Post 1527371)
I have added that code before the line:

Code:

if ($a > 0.8)
like in version 1.0.1.

Is this correct for the new version or the code must be on another place?

It's correct.

RobParker 05-25-2008 02:12 PM

Installed fine, only problem I've having is if the word you search for is too long it messes up the width of my style. Is there a way to fix the width easily to force the text to shrink if it doesn't fit in the column?

NeutralizeR 05-25-2008 06:28 PM

Quote:

Originally Posted by RobParker (Post 1530960)
Installed fine, only problem I've having is if the word you search for is too long it messes up the width of my style. Is there a way to fix the width easily to force the text to shrink if it doesn't fit in the column?

Try this in searchcloud template:
http://www.blooberry.com/indexdot/cs...t/wordwrap.htm

Amenadiel 05-28-2008 01:21 AM

I suggest a little fix.

I was receiving this weird SQL error on my mail (it's VB's way to alert me when something goes wrong)

Code:

Database error in vBulletin 3.7.0:

Invalid SQL:
INSERT into vb_google_searches VALUES ('pavilion tx1332 drivers xp                                                                                                                                                                \"megaupload.com/\"|\"badongo.com/file/\"|\"rapidshare.com/files\"|\"mediafire.com/?\"|\"gigasize.com/get.php\"|\"seriesyonkis.com/\"','http://www.chw.net/foro/showthread.php?t=150369\',1);

MySQL Error  : Duplicate entry 'pavilion tx1332 drivers xp                                      ' for key 1
Error Number  : 1062
Request Date  : Tuesday, May 27th 2008 @ 04:10:48 PM
Error Date    : Tuesday, May 27th 2008 @ 04:10:48 PM
Script        : http://www.chw.net/foro/aqui-tienen-los-driver-del-tx1330la-t150369.html
Referrer      : http://www.google.es/custom?cx=005259712913702778262:h0v4n2t74pm&cof=GFNT%3A%23444444%3BGALT%3A%23444444%3BCX%3ADaleYa%252Ecom%3BVLC%3A%23663399%3BDIV%3A%23336699%3BFORID%3A0%3BT%3A%236600FF%3BALC%3A%23330000%3BLC%3A%23330000%3BGIMP%3A%23444444%3BBGC%3A%23DFE5FC%3BAH%3Aleft&q=pavilion+tx1332+drivers+xp++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++"megaupload.com/"|"badongo.com/file/"|"rapidshare.com/files"|"mediafire.com/?"|"gigasize.com/get.php"|"seriesyonkis.com/"&btnG=B%C3%BAsqueda&cx=005259712913702778262%3Ah0v4n2t74pm
IP Address    : 190.198.248.43
Username      : Unregistered
Classname    : vB_Database_MySQLi
MySQL Version :

After a bit of tinkering, I found out that the field kw on the vb_google_searches table is 255 chars long, so two strings of, let's say, 260 chars, whose 255 first chars are identical, would trigger a duplicate key error. ?Why? Because the search_cloud script will check for a 260 chars $search variable without finding coincidences.

Ok, perhaps I'm not explaining myself enough, but if you guys get this error, I solved it cropping the $search variable to 254 chars.

In search_cloud.php find
Code:

$this->_logHit(strtolower($search),$pageURL);
add BEFORE
Code:

$search=substr($search,0,254);
and that's it

NeutralizeR 05-28-2008 11:23 AM

Quote:

Originally Posted by Amenadiel (Post 1533628)
I suggest a little fix.

I was receiving this weird SQL error on my mail (it's VB's way to alert me when something goes wrong)

Code:

Database error in vBulletin 3.7.0:

Invalid SQL:
INSERT into vb_google_searches VALUES ('pavilion tx1332 drivers xp                                                                                                                                                                \"megaupload.com/\"|\"badongo.com/file/\"|\"rapidshare.com/files\"|\"mediafire.com/?\"|\"gigasize.com/get.php\"|\"seriesyonkis.com/\"','http://www.chw.net/foro/showthread.php?t=150369\',1);

MySQL Error  : Duplicate entry 'pavilion tx1332 drivers xp                                      ' for key 1
Error Number  : 1062
Request Date  : Tuesday, May 27th 2008 @ 04:10:48 PM
Error Date    : Tuesday, May 27th 2008 @ 04:10:48 PM
Script        : http://www.chw.net/foro/aqui-tienen-los-driver-del-tx1330la-t150369.html
Referrer      : http://www.google.es/custom?cx=005259712913702778262:h0v4n2t74pm&cof=GFNT%3A%23444444%3BGALT%3A%23444444%3BCX%3ADaleYa%252Ecom%3BVLC%3A%23663399%3BDIV%3A%23336699%3BFORID%3A0%3BT%3A%236600FF%3BALC%3A%23330000%3BLC%3A%23330000%3BGIMP%3A%23444444%3BBGC%3A%23DFE5FC%3BAH%3Aleft&q=pavilion+tx1332+drivers+xp++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++"megaupload.com/"|"badongo.com/file/"|"rapidshare.com/files"|"mediafire.com/?"|"gigasize.com/get.php"|"seriesyonkis.com/"&btnG=B%C3%BAsqueda&cx=005259712913702778262%3Ah0v4n2t74pm
IP Address    : 190.198.248.43
Username      : Unregistered
Classname    : vB_Database_MySQLi
MySQL Version :

After a bit of tinkering, I found out that the field kw on the vb_google_searches table is 255 chars long, so two strings of, let's say, 260 chars, whose 255 first chars are identical, would trigger a duplicate key error. ?Why? Because the search_cloud script will check for a 260 chars $search variable without finding coincidences.

Ok, perhaps I'm not explaining myself enough, but if you guys get this error, I solved it cropping the $search variable to 254 chars.

In search_cloud.php find
Code:

$this->_logHit(strtolower($search),$pageURL);
add BEFORE
Code:

$search=substr($search,0,254);
and that's it

Yes, i'd add that search limiting in the next version. Thanks.

ade5675 05-31-2008 03:59 AM

I don't know where all the errors and questions are coming from. This hack is great.

It works in 3.6.8
Thanks for this, NeutralizeR :up:

INSTALLED!!

saotome 06-02-2008 05:52 AM

installed, reserved. thanks


All times are GMT. The time now is 10:21 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01355 seconds
  • Memory Usage 1,759KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (10)bbcode_code_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (2)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete