Thread: Sphinx Search
View Single Post
  #11  
Old 11-04-2007, 11:39 PM
weeno weeno is offline
 
Join Date: Jan 2002
Posts: 61
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks for everyone involved. I appreciate the info. Especially, eoc_Jason. Those scripts saved me a lot of time.

I had to recreate much of the final sphinx.php file from the original file and the followup posts. So I thought I'd post my final edit so people can build on it.

I took the sphinx.php file from orban
https://vborg.vbsupport.ru/showpost....&postcount=387

Applied these changes:

sort_search_items changes from the bottom of the post by eoc_Jason

Fixed a Problem with asserts in sphinxapi.php

Added only the 64-bit Unpack fix detailed here. If you aren't on the 64-bit system, you prob can remove this function. I didn't add/change the rest of ALanJay's changes as I wasn't sure what they were for.

One problem for was the Coventry variable that seems to be causing causing errors:

Quote:
Warning: in_array() [function.in-array]: Wrong datatype for second argument in /includes/sphinx.php on line 125
that didn't seem to affect the search results. NOTE: I added error_reporting(0) as did mute at the beginning to simply surpress these errors as I didn't find another solution. If anyone has a solution for this, let me know. If you are testing this script out, you should remove that line to make sure it works before you surpress errors.

I didn't use

this code by mlx because I wasn't sure exactly what was added.

sphinxapi.php ignoring max matches limit set in sphinx.conf fix - again, wasn't sure if I needed to use it at the time.

config

my config is PHP 5.2.4 for php servers. Centos 5 64-bit for mysql. vbulletin 3.6.7.

arn
Attached Files
File Type: php sphinx _weeno.php (7.8 KB, 36 views)
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01278 seconds
  • Memory Usage 1,786KB
  • Queries Executed 12 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_quote
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_attachment
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

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

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete