Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Ajax Search Suggest


geozerocool

Recommended Posts

hi

http://addons.oscommerce.com/info/6522 i installed this modification the last one marcelon brazil << his adddition

and everything ok but

when i enter some keywords i get results there and results ar ok but comes out the alert box with message

Error accessing the server!

 

function displayError(message)
{
 // display error message, with more technical details if debugMode is true
 alert("Error accessing the server! "+
	(debugMode ? "\n" + message : ""));
}

Code looks like this

what's the problem ? :)

Link to comment
Share on other sites

sharma.atul85

Hi i Just now deleted this part and it works fine :D

function displayError(message)
{
 // display error message, with more technical details if debugMode is true
 alert("Error accessing the server! "+
	(debugMode ? "\n" + message : ""));
}

Link to comment
Share on other sites

I was/am (?) experiencing this problem also.

 

What I suggest you do is type this into your URL bar of your browser:

 

http://YOURDOMAIN.COM/STORE_LOCATION/suggest.php

 

If your store is in the root, then you won't need the STORE_LOCATION.

 

This should basically list ALL you products as an XML document. However, when I did it for the first time, it gave me an error:

XML Parsing Error: not well-formed

 

In Firefox at least, a line will be drawn under the text and if you follow that line to the end, it will show you where the error is. In my case, I had used an "&" in a title which was causing the error. (I THINK!). Watch for other special characters also - * # % @ etc.

 

Once I replaced the "&" with "and" the XML displayed fine and the error appears to have disappeared.

 

Please report back if that solves your problems also. I would like to know that my store is fixed also! (I am not a PHP programmer, but this looks like it has worked for me!)

 

Cheers!

 

Sylvester99

Link to comment
Share on other sites

  • 1 year later...

@Sylvester99:

Your solution did not work for me.

 

 

 

I had to change de file: includes/boxes/search.php

 

find arround line 634:

// BOF Search Suggest V2 Marcelon Brazil
//  updateKeywordValue(document.getElementById("tr0"));
 updateKeywordValue(document.getElementById("keyword"));
// EOF Search Suggest V2 Marcelon Brazil

 

And change it to:

// BOF Search Suggest V2 Marcelon Brazil
 updateKeywordValue(document.getElementById("tr0"));
//  updateKeywordValue(document.getElementById("keyword"));
// EOF Search Suggest V2 Marcelon Brazil

 

This worked for me.

I just don't know why it has been changed by Marcelon Brazil for V2

 

I hope this can help.

Link to comment
Share on other sites

  • 1 month later...

Hi,

 

Did anyone manage to get this probelm resolved?

 

Kind Regards,

 

Paul.

 

 

 

 

 

 

@Sylvester99:

Your solution did not work for me.

 

 

 

I had to change de file: includes/boxes/search.php

 

find arround line 634:

// BOF Search Suggest V2 Marcelon Brazil
//  updateKeywordValue(document.getElementById("tr0"));
 updateKeywordValue(document.getElementById("keyword"));
// EOF Search Suggest V2 Marcelon Brazil

 

And change it to:

// BOF Search Suggest V2 Marcelon Brazil
 updateKeywordValue(document.getElementById("tr0"));
//  updateKeywordValue(document.getElementById("keyword"));
// EOF Search Suggest V2 Marcelon Brazil

 

This worked for me.

I just don't know why it has been changed by Marcelon Brazil for V2

 

I hope this can help.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...