Search function broken in product page only

This is an odd one that apparently has been plaguing our site for some time, but I haven’t had the time to investigate until today.

Our search function (eqtuning.com) on our main page functions fine. In collections, the search bar also functions as normal.

When viewing a specific product, and attempting to search for another product, I receive an error “Parameter Missing or Invalid: Required parameter missing or invalid: items”

Doing some quick “inspect” searching using google, reveals that the search form is actually not using search, but cart add:


Everywhere else in our site, the correct form action “/search” is used. I have tried looking in the product.liquid file for this issue, but it remains hidden.

The only thing that I can think of is POSSIBLY an application we have enabled called “Infinite Options”, where in the theme.liquid file there is a script function:


Any clues/help/advice would be appreciated.

@Cliffp - you are right, search has been replaced with cart, it has to be some javascript issue, please delete externally added app or code and test again, if works then that app or code is the culprit

Thank you for the confirmation. Unfortunately, on a production site I can’t just delete any externally added application or code and re-test, out of fear that it will bring down the site. My JS knowledge is even less than HTML, so I will need to do some serious digging to determine what the issue could be caused by. I do see some JS that persisted while the apps that it calls for no longer exists, which is a separate issue. I’ll have to sort that out after I take care of the larger search issue.

Problem found, and I’m waiting on the developer for a solution. Almost the very last line of our theme.liquid file had a line of code referring to a javascript file, which breaks the search function in the product pages only.

@Cliffp - great, you can modify it or remove it,