Author Topic: [MOD] Search Statistics v1.2  (Read 160131 times)

0 Members and 1 Guest are viewing this topic.

Offline tytanic11

  • Pre-Newbie
  • Posts: 4
    • View Profile
Re: [MOD] Search Statistics v1.2
« Reply #90 on: June 25, 2007, 12:29:40 AM »
Working great on 1.7.4; exactly what my site needed.. thanks !

Offline Buggy Driver

  • Newbie
  • *
  • Posts: 22
    • View Profile
Re: [MOD] Search Statistics v1.2
« Reply #91 on: June 26, 2007, 12:38:01 AM »
I cant open the image so I hope this is it

In search_stats.php

Look for
Code: [Select]
foreach ($lang['search_stats_order_options'] as $key => $val) {
$sort_dropdown .= "<INPUT type=\"radio\" name=\"order\" value=\"$key\"";
if ($order == $key) {
    $sort_dropdown .= " checked";
}
$sort_dropdown .= ">".$val."\n";
}

change to
Code: [Select]
/*
foreach ($lang['search_stats_order_options'] as $key => $val) {
$sort_dropdown .= "<INPUT type=\"radio\" name=\"order\" value=\"$key\"";
if ($order == $key) {
    $sort_dropdown .= " checked";
}
$sort_dropdown .= ">".$val."\n";
}
*/

$sort_dropdown .="\n<select name=\"order\" class=\"setperpageselect\">\n";
foreach ($lang['search_stats_order_options'] as $key => $val) {
  $sort_dropdown .= "<option value=\"$key\"";
  if ($order == $key) {
    $sort_dropdown .= " selected=\"selected\"";
  }
  $sort_dropdown .= ">".$val."</option>\n";
}
$sort_dropdown .= "</select>\n";
« Last Edit: June 29, 2007, 08:55:16 AM by Buggy Driver »

Offline Buggy Driver

  • Newbie
  • *
  • Posts: 22
    • View Profile
Re: [MOD] Search Statistics v1.2
« Reply #92 on: June 26, 2007, 08:45:12 PM »
} is missing

Dorn that’s the second time this happens

empty search words
Strange  I tested this en I don’t get an empty string in the stats even tested a space

Did you follow the instructions correctly?  Is it possible to post your search.php?


Offline knsin0

  • Jr. Member
  • **
  • Posts: 76
    • View Profile
Re: [MOD] Search Statistics v1.2
« Reply #93 on: June 29, 2007, 01:38:10 AM »
Nice mod, im using 1.7.4 buggy, i followed your instructions and the search_stats.php seems to work ok, but in the search form i get this error when i try to search something:
Code: [Select]
Notice: Use of undefined constant SEARCH_STATS_TABLE - assumed 'SEARCH_STATS_TABLE' in C:\AppServ\www\search.php on line 93

Notice: Use of undefined constant SEARCH_STATS_TABLE - assumed 'SEARCH_STATS_TABLE' in C:\AppServ\www\search.php on line 98

How can i fix that?¿  What im doing wrong?¿  :?

Offline Buggy Driver

  • Newbie
  • *
  • Posts: 22
    • View Profile
Re: [MOD] Search Statistics v1.2
« Reply #94 on: June 29, 2007, 09:35:28 AM »
It is like the notice says
undefined constant

the constant is defined in
Step 2.
Open /includes/constants.php
At the end of the file, just before closing ?> add this:
Code: [Select]
define('SEARCH_STATS_TABLE', $table_prefix.'search_stats');
if this is OK and you still got the notice remove the MOD  (reinstall the backup files) and start over.

Offline Buggy Driver

  • Newbie
  • *
  • Posts: 22
    • View Profile
Re: [MOD] Search Statistics v1.2
« Reply #95 on: July 01, 2007, 07:25:49 PM »
missing items in list

In search_stats.php look for
Code: [Select]
$count = ($words > $phrases) ? $words : $phrases;

change to
Code: [Select]
// $count = ($words > $phrases) ? $words : $phrases;
$count = $words + $phrases; 

Offline mawenzi

  • Moderator
  • 4images Guru
  • *****
  • Posts: 4.500
    • View Profile
Re: [MOD] Search Statistics v1.2
« Reply #96 on: July 01, 2007, 09:07:33 PM »
@ivan,

... solche Suchwörter in der Liste wie "cÄ'te" oder mit ähnlichen Hyroglyphen werden durch Searchboots erzeugt ...
... sie entstehen aus Suchwörtern deiner Website mit Umlauten und Sonderzeichen ...
... es sind ja in der Regel engl. sprachige Boots, die Umlaute und Sonderzeichen nicht kennen ...
... folgt solch ein Boot nun einem Suchwortlink mit Umlaut, so transformiert er dieses Suchwort bzw. die Umlaute/Sonderzeichen ...
... mit diesem transformiertem Suchwort geht er in deine Suche und legt es auch so in der Datenbank ab ...
... so ... und da ist es nun, das eigenartige Wort und erscheint nun in der Auflistung deiner Search Statistik ...

... und wie kann man das verhindern / umgehen / ändern ... ?

1. man verwendet keine Suchwörter mit Umlauten / Sonderzeichen ...
2. wenn doch, dann muss man regelmäßig die Datenbank etwas aufräumen und diese Suchwörter aus der Tabelle löschen ...
3.  mehr fällt mir momentan dazu nicht ein ...

... in meiner Suchwortauflistung sieht es genauso aus und regele die Problematik entspr. Punkt 2. ... ;)
Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...

Offline Buggy Driver

  • Newbie
  • *
  • Posts: 22
    • View Profile
Re: [MOD] Search Statistics v1.2
« Reply #97 on: July 01, 2007, 09:46:52 PM »
i have trouble with this code
// $count = ($words > $phrases) ? $words : $phrases;
$count = $words + $phrases; 

problem with paging > comes error 404

Strange it works for me I to had missing items in the list

as you wrote
problem with browser

image one 2007-07-01_201736.gif > database keyword in search_stats table is okay
image two 2007-07-01_202141.gif > this view in opera
image three 2007-07-01_202234.gif > this view in firefox

i have with all browser the same problems.

I think you misunderstood my PM

By the way
2007-07-01_1.gif  the item has a count of 14

in your img 2007-07-01_201736.gif you point out items that have a cont of 1 and 4 (it’s the wrong item)



in your 2007-07-01_1.gif the status bar points out the correct search phrase

when I take my Dutch browser the status bar gifs me the wrong  search phrase



my German reading is bad  as for I can understand mawenzi post its something of English search bots   so a language thing

Offline Buggy Driver

  • Newbie
  • *
  • Posts: 22
    • View Profile
Re: [MOD] Search Statistics v1.2
« Reply #98 on: July 03, 2007, 01:27:01 PM »
I took an other look ad the missing items and I am still convinced it has to be

Code: [Select]
// $count = ($words > $phrases) ? $words : $phrases;
$count = $words + $phrases;


the calculation of the page are wrong otherwise
$count = ($words > $phrases) ? $words : $phrases;


found 32 words and 6 phrases
these or clamed to be shown on 7 pages

5 items on every page - - > 7 pages  that is only 35 items total 
I wil be missing 3 items

$count = $words + $phrases;


found 32 words and 6 phrases
these or shown on 8 pages

5 items on every page - - > 8 pages  that is 40 items total 
last page only contains 3 items (there isn’t any more to show)

can someone else test this and let us know what the result is?


Offline mawenzi

  • Moderator
  • 4images Guru
  • *****
  • Posts: 4.500
    • View Profile
Re: [MOD] Search Statistics v1.2
« Reply #99 on: July 03, 2007, 02:27:27 PM »
@ Buggy Driver

... your new code for $count is 100% correct ...  8O
... and why ...
... in the search_stats_table are shown words and ( not or ) phrases by a count of "per page" ...
... I changed my count-code in your way and tested it ... 100% correct ...

... thanks Buggy Driver for your hint ...  :mrgreen:
Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...

Offline Fragezeichen

  • Jr. Member
  • **
  • Posts: 58
    • View Profile
Re: [MOD] Search Statistics v1.2
« Reply #100 on: July 20, 2007, 11:02:02 PM »
 Hat jemand die Files zum Download?
Ich glaube mal das die Seach.php und Seach_stats.php nicht ales sein können.

How could I found the Files-Upload?
Only two updatet Php files for Version 1.7.4 could not be all,isn´t it?

Please

Offline sami1255

  • Newbie
  • *
  • Posts: 31
    • View Profile
Re: [MOD] Search Statistics v1.2
« Reply #101 on: July 25, 2007, 01:07:32 AM »
I dont understand this either.. the word file has sub-steps as well..  please clearify..  :?: :?: :?:

Offline Buggy Driver

  • Newbie
  • *
  • Posts: 22
    • View Profile

Offline Martin2006-B-2

  • Newbie
  • *
  • Posts: 10
    • View Profile
    • Berlin Fotos und Bilder - fotos-berlin24.de
Re: [MOD] Search Statistics v1.2
« Reply #103 on: January 29, 2008, 04:14:59 PM »
This is a GREAT Mod! Thanks to all!
Berlin Fotos und Bilder - fotos-berlin24.de


Offline RoadDogg

  • Sr. Member
  • ****
  • Posts: 488
    • View Profile
    • Düsipixel
Re: [MOD] Search Statistics v1.2
« Reply #104 on: March 28, 2008, 12:07:19 AM »
After updating gallery to v1.7.6 and updating this Mod {words} and {phrases} are no longer working:

$lang['search_stats_paging'] = "Found {words} words(s) and {phrases}

Has anybody an idea? I compared all files with the old ones but I cannot find how to get these variables working.
For support requests please don´t forget link to your Gallery/to phpinfo.php
Code: [Select]
<?
phpinfo()
?>
safe_mode must turned OFF
Please check Error Messages