Page 3 of 3

How do I add search results to another page?

Posted: Wed Mar 12, 2014 5:22 am
by Alex6694044

Thanks Igor,

All the LSV's are still there, but none of the shows are showing up with this new code. I tried to fix with different mappings on the main page but it still did not work.

Image

Do I need to do anything in addition to replacing this code?


How do I add search results to another page?

Posted: Wed Mar 12, 2014 6:06 am
by Igor

Alex,

Please add the next code:
pre

console.log("where string is:");
console.log(JSON.stringify(whereObject));
/pre
before code:

pre
return JSON.stringify(whereObject);
/pre
Run your application and you will get "where" string from console.

Try to understand what is wrong with it.

It should be something like this:
pre
code
{"_id": {$in: ["52fe1b5fe4b0a25c11c899df", "52fe1b6fe4b0a25c11c899e0"]} }
/code
/pre
If you have a similar string - please be sure ids in this string are exists in database.

If it doesn't helps please share your DB with us and write your "where" string.


How do I add search results to another page?

Posted: Wed Mar 12, 2014 6:31 am
by Alex6694044

The console output is:
precode

stored show is = 30715
where string is:
{"_id":{"$in":["17544","30715"]}}

/code/pre

I know these id's exist in the TVrage.com database/API (I am not using my own database). If I do an individual request it works:

http://services.tvrage.com/myfeeds/sh...


How do I add search results to another page?

Posted: Wed Mar 12, 2014 4:19 pm
by Nikita

Hello,

If you use third-party service (not appery.io DB), then this approach will not work. If you want to return values from an array, then you should contact the support of that service


How do I add search results to another page?

Posted: Wed Mar 12, 2014 11:39 pm
by Alex6694044

Yeah, it seems that was the major issue all along. I decided to upload the shows and id's to an the appery.io DB. I guess I will just manually update the appery.io periodically.

Thank you guys for all the help. Problem solved after changing from using the TVRage API.

Image