• My account
    • (X)Sign in

      I am a returning customer at TYPO3 Multishop

      Enter your username and password here in order to log in on the website:

      Forgot your password?

      Not yet customer of TYPO3 Multishop?

      • Order history
      • Automatic generated e-mail history
      • Track your Order
      New at TYPO3 Multishop
You are here:

Help by translating Multishop in your local language

On the following page you can help by translating Multishop in your local language:

https://translation.typo3.org/projects/TYPO3.ext.multishop/

Spanish:

https://translation.typo3.org/es/TYPO3.ext.multishop/pi1/locallang.xlf

The following language are already translated by our supporters:

  • Dutch
  • German
  • French

AJAX Search returns no data - no search at all


Author Message
mellowMarco
Marco
Multishop newbie
Topic creator
registered since: 24.07.2011
Posts: 1
Hi Bas,

great looking product and at first glance quite ligthweight but capable (compared to Magento)!

Sorry, but I have a problem that is not very easy to figure out. The search is not workin at all. With or without AJAX there are no results.
AJAX gets me no error but an empty result (as it should be some JSON string, right?)

If you could point me into the right direction how the search works basically - would be much appreciates. We might have the first Multishop in New Zealand then! icon_smile.gif

cheers,
Marco
Written on: 07. 08. 2011 [08:22]
bas
Bas van Beek
Multishop guru
registered since: 12.05.2010
Posts: 644
Hi Marco,

Thanks for your compliment, we really appreciate that.

Could you try to install version 1.0.21 and add a TYPO3 Mutishop content element with the Search enabled as type (in the first tab) and in the Search tab enable: Ultrasearch.

Please let us know if that works.


Written on: 10. 08. 2011 [16:09]
Ryche
Richard
Multishop newbie
registered since: 21.08.2011
Posts: 2
Hi,

Working on the same project as Marco. I independently had the same issue. I decided to find out the hard way if the setup is missing any variables and where, and instead found a bug in the search.

In mslib_fe.php -> getProductsPageSet line 1419 the line
PHP
$str="select count(1) as total,IF(s.status, s.specials_new_products_price, p.products_price) as final_price ".$from_clause.$where_clause;

is missing a group by clause. This causes the query to fail, so no totals rows are returned, and so the test on exit for the search in products_search at line 168
PHP
if ($pageset['total_rows'] > 0)

fails, so the system thinks it didn't find any products.

To be honest I'm not quite sure why there are two queries there, or what the significance of the first query is. I note there are a few commented out lines beforehand so I imagine this bug is relatively new.

If I'm wrong about this being a bug I apologise, I'm relatively new. I still haven't checked if this fixes the issue for ultrasearch as well, will be doing that now and will post the result.

Thanks
Written on: 21. 08. 2011 [22:28]
findera
Bellof
Multishop experienced
registered since: 26.07.2011
Posts: 13
For there are just other if clauses inside the total_rows command, and no single command, I just commented this out and it works now.

But I've got another problem: When searching a term with : in it(eg. a time), I still get no results. Any ideas?
Written on: 22. 08. 2011 [07:38]
bas
Bas van Beek
Multishop guru
registered since: 12.05.2010
Posts: 644
The first query is for quickly scanning how many rows there are and for speed we dont use any order by. The 2nd query is the real query that fetch the page resultset and is limited by pagination.

I recommend you to install the latest version (1.0.24) as we fixed some issues with this method.

The search method explodes all words (delimited by space) and checks if there is a word shorter than 2 chars. If so the traditional search is being done (using LIKE). If all words are longer than 2 chars a fullsearch is being done (using MySQL match function), which is much faster than LIKE on large catalogs.

"Ryche" wrote:

Hi,

Working on the same project as Marco. I independently had the same issue. I decided to find out the hard way if the setup is missing any variables and where, and instead found a bug in the search.

In mslib_fe.php -> getProductsPageSet line 1419 the line
PHP
$str="select count(1) as total,IF(s.status, s.specials_new_products_price, p.products_price) as final_price ".$from_clause.$where_clause;

is missing a group by clause. This causes the query to fail, so no totals rows are returned, and so the test on exit for the search in products_search at line 168
PHP
if ($pageset['total_rows'] > 0)

fails, so the system thinks it didn't find any products.

To be honest I'm not quite sure why there are two queries there, or what the significance of the first query is. I note there are a few commented out lines beforehand so I imagine this bug is relatively new.

If I'm wrong about this being a bug I apologise, I'm relatively new. I still haven't checked if this fixes the issue for ultrasearch as well, will be doing that now and will post the result.

Thanks
Written on: 23. 08. 2011 [07:33]