prmr / Creco

Recommendation System for Consumer Products
Apache License 2.0
6 stars 2 forks source link

Broken product names when there is a comma in the name #103

Closed forgues closed 10 years ago

forgues commented 10 years ago

I tested with the "tablet" category, where almost all products have a comma in their name, e.g. Acer Iconia Tab A110 (Wi-Fi, 8GB)

As soon as I select a feature, all product names are cut off at the comma. e.g. Acer Iconia Tab A110 (Wi-Fi

Images aren't displayed anymore and the URLs are broken. I suspect this is because products are normally separated by a comma, so it doesn't expect a comma in the actual product names.

asutcl commented 10 years ago

That would be because the JS is currently set to parse with , as delimiters I think. I was looking at this this morning since the image wasn't working anymore.

In ConcreteServiceFacade a response is generated and this response appends name, url, image through commas. This should be changed and so should the response parsing.

ceipher commented 10 years ago

I will take this one. ideally it should not use any symbol as separator. Probably create JSON object would be a solution

enewe101 commented 10 years ago

Just a suggestion -- use json for ajax response bodies -- jquery is set up to auto-parse it. In the jQuery's ajax request constructor, set property data='json'.

On Wed, Apr 9, 2014 at 2:00 PM, ceipher notifications@github.com wrote:

I will take this one. ideally it should not use any symbol as separator.

— Reply to this email directly or view it on GitHubhttps://github.com/prmr/Creco/issues/103#issuecomment-39996067 .

ceipher commented 10 years ago

@MariamN did you solve this problem by commits in #108 , if so you can close this one.

MariamN commented 10 years ago

@cipher yes it is now solved. Closing this issue now.