Hey guys, trying to put a map on my dynamic single item page which changes for every property listed.
This is my code so far but not working. Any help would be greatly appreciated!
I have read the api and also the other posts here and still stuck. Please help as I want to get this site out asap!
Hi,
Code looks OK… any console errors?
Can you please make sure your getting an item with longitude and latitude from the DB?
Can you try logging the ‘currentItem’ ?
error sys [Warning] Wix code SDK Warning: The longitude parameter that is passed to the location method cannot be set to null or undefined. (wixcode-worker.js, line 1)
I have it as a number in above DB, is that right?
I’m sorry cn u give an example to do console logs on my code? i have read the article but cant figure it out. Thanks!
So the problem, according to your console, is that you’re not giving longitude.
Note that in your DB, only the second record has longitude and latitude.
Please fix the data and try again.
I have the same issue here: [Warning] Wix code SDK Warning: The latitude parameter that is passed to the location method cannot be set to null or undefined. And I checked the field keys all match.
thanks for your reply! The command “location” is still undefined, says WIX. Is location also an entry within your database?
And how did you customize your html code? Because i believe that this is where the problem lies for me.