| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
Improved Search Function | ||||
|
|
Thread Tools | Search this Thread |
#131
|
|||||||||
|
|||||||||
A couple errors in your code.
Lines 211, 212, 229 (you have [color] tags) that break the page. Plus it still will not pull up Product SKUs (productcode).
__________________
Best Regards, Sam Solace - Pres/CEO Century Performance Center, Inc. http://www.centuryperformance.com (3) sites using X-Cart 5.3.5.5 X-Payments Enterprise 3.1.4 |
|||||||||
#132
|
|||||||
|
|||||||
Ok I removed the color Tag my bad I corrected this earlier but for some reason it did not update.
I also Tested the code out and had problems, fixed the problems somone please give me some feedback. Also If you want SKU you need to add a check box or hidden input tag with the name "by_proudctcode" and give it any value and this will enable this feature. I will be adding code to allow Simple Search on the home page to have all the features of advanced search (minus categories and manufacutrers, this could be added but I dont need it for the simple search) -------------------------------------------- I Updated my post again with the code for search_results.tpl and code to improve the simple search on the home page. Hope thier are no bugs works good for me.
__________________
\"Then again it could all be horse crap\" by some old Guy. 4.013 |
|||||||
#133
|
|||||||
|
|||||||
Can you please put in on your code where exactly the file located? just for a newbie.
Also, SKU in advance page doesn't work (working fine in simple search). Can you please give a rough 'how to'? here is my code: Code:
Still doesn't work. Thanks in advance!
__________________
X-Cart version 4.x (Most likely will be the latest version) |
|||||||
#134
|
|||||||||
|
|||||||||
hi there,
i got two questions. 1. any imporvements for 4.0.14 2. my store is based on Turkish Language. As Turkish use special charset like İĞц°Şц┤ when a customer search most of time search doesnt gets anything. it depens on if the word is writen with capital letters. for example : our product is İzopermo when the customer search for "izopermo" nothing found! but when search with "İzopermo" capital first search founds the product. i hope i am clear with english. any1 help? thnx
__________________
// x-cart 4.1.9 X-CART CSS SKIN XC SEO IP Addresses in Users Online for all users Color coded order status |
|||||||||
#135
|
|||||||
|
|||||||
This does sound like a BUGGER of a problem.
I wounder if you can use a regular expression to convert things??? If their is a logical convertion methode I am almost certain regex are perfect for just this type of task. Or is their just a better way to handle the special character to begin with. Where everything is stored as "izopermo" then when smarty read/parses the text it converts this "i" to "İzopermo" for display This does not suprize me though I am curious doesn't Russian have special characters? and well does the search engine work in their own language??? On second thought Isn't İ an ASCII code???? Why wouldn't this be recognizeable Im getting outa my league now.
__________________
\"Then again it could all be horse crap\" by some old Guy. 4.013 |
|||||||
#136
|
|||||||
|
|||||||
Oh No! Changed mind
This mod works.
However, if you want to change back to the original, the search for SKU in the advanced part is broken. Yes I made backups of all 3 files. The customer decided that this wasn't what they wanted, I replaced the backups over the modified. And everything else works except the SKU line in the advanced. now this is in the admin area too. and that is where they need it the most. any ideas like in the next 5 minutes???
__________________
Xcart Gold 4.0.13 OS: Linux Apache version: 1.3.33 (Unix) PHP version: 4.3.11 MySQL version: 4.0.22-standard |
|||||||
#137
|
|||||||
|
|||||||
Sound wierd. Sounds like you did not Restore the original files. Or you thought you restored a file and you restored the wrong one or something.
I would find the original files from a fresh install or freshly decompressed file. Use these and you should be fine. Check out My Mod Post on Page 9. I have had several people tell me that this works just fine. I have zero problems with it if you want I can PM you my Copies of these files. I made some minor changes to this post just now. I set it up to display the search results as x-carts default methode rather than the search by term methode it was setup for. Scott
__________________
\"Then again it could all be horse crap\" by some old Guy. 4.013 |
|||||||
#138
|
|||||||
|
|||||||
I got it working the old way again! :)
I restored the files from my last back up. However, I missed one file. xcart/include/search.php -- the most important one. I went crosseyed over this. Anyway, I did install this mod for another client and they love it. It works just fine. Thanks to ALL who contributed to this. Thank you so much Tuner for making it VERY clear and easy to make the modifications!!
__________________
Xcart Gold 4.0.13 OS: Linux Apache version: 1.3.33 (Unix) PHP version: 4.3.11 MySQL version: 4.0.22-standard |
|||||||
#139
|
|||||||
|
|||||||
Maybe Somone Can Help me hear. (sorry for the double post in wish list) I can delete it???
I think I got a hack that might work but could be slow. This would apply to the search modification that searches for products that contain any word in a search phrase. Currently x-cart only shows resluts that match ALL of the Words in your Search phrase. (the mod under my Name Page 9 its defualt settings are to work like the normal x-cart search if you scroll 1/3 the way down you will see some commented out code follow the instruction to allow this mod to search by term rather than by phrase) Not sure how to code this as of yet but hear is the concept. Simply: (use the seach mod and change commenting for term match) 1. Take the array of search results that are going to be displayed. 2. Add another element to the array so if the array is just ProductID then make it ProductID, Relevance. 3.Now Loop threw each ProductID For every Word that is found: Increment Relevance by 1.001 for the first time each word is found and increment Relevance by .001 for each additional match of that word. So if one searches for "Ferrari 333 SP" A. I have a product that has 3 occurances of "ferrari" and 2 occurances of "333" its relevancy score will be 2.005 B. I have a product that has 1 occurance "of ferrari" and 1 occurance of "333" and 1 occurance of "SP" its relevancy score will be 3.003 C. I have a product that has 4 occurances "of ferrari" and 3 occurances of "333" and 3 occurances of "SP" its relevancy score will be 3.010 D.I have a product that has 15 occurances of "ferrari" its relevancy score will be 1.015 Then If you sort by relevancy the results will be ordered as follows. Products that Match all terms are listed first and those results will automaticly be orderd by the reoccurance of those matching terms. (aka add 1 for each term that is matched and .001 for the total occuraces of all matched terms.) If their are products where their is over 999 reoccurances of a Term this methode starts to fail( simply adding a decimal point will fix it up to 9,999 occurances) Probably dont need more than 99 but was playingit safe. Should not be to hard to modify the existing code to do this. If you do it right you just modify the current code that finds each term to update the Relevancy. Then you just add one Sort routine to sort the results by relevance. Its a thought??? Maybe its easy to say hard to do???
__________________
\"Then again it could all be horse crap\" by some old Guy. 4.013 |
|||||||
#140
|
|||||||
|
|||||||
Sounds like it could work
Tuner that sounds like it could work.
I have a script that can search a phrase and return all the items that relate to the individual words of the string, but it cant handle sku's. X-Cart really needs to work on a better search engine. let me know if you find a solution to this. wmccoy@colonialmedical.com
__________________
William McCoy Online Manager Colonial Medical Version 4.0.13 |
|||||||
|
|||
X-Cart forums © 2001-2020
|