Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialDavid Wright
1,970 PointsIssues with setting Google Maps markers using JQuery
im stuck on this question and i dont know what to do to make it right, PLEASE HELP.
In app.js, on line 20, initialize a new marker with the 'map' set to 'theMap' and the 'position' set to 'addressLocation'
the line of code i have is: var marker = new google.maps.Marker({map: theMap, posotion: addressLocation});
why isnt this working? i cant figure it out.
Thanks
Gabriel Macedo
2,655 Pointsworked^
3 Answers
Mathew Silva
5,241 Pointsvar marker = new google.maps.Marker({map: theMap, position: addressLocation}); should work.
Check your spelling of position inside the ()
Luc Dejardin
3,072 PointsNo, it don't work either, dono why.
John Glynn
8,239 PointsDid you make sure it was in the app.js tab? That's what threw me off, the above code worked for me.
Luc Dejardin
3,072 PointsYes, it was probably a bug cuz it ended by working with the same code.
trishagawley
10,483 PointsHow did you finally get this to work? I have the same code... tried yesterday and am now trying it again today.
var marker = new google.maps.Marker({map: theMap, position: addressLocation});
Gagandeep Virk
19,741 PointsHi All, I am having little problem in the adding static maps code challenge of question 4, I don't know what I am doing wrong? Can someone help me please? The question is Set the query parameter of "size" to 400 by 300 and my answer is &size=400×300"
John Coughlan
9,414 PointsHi there, I used a very similar bit of code to yours, but used the letter 'x' between the numbers: &size=400x300"
It worked for me so hopefully that helps!
Rand Seay
13,975 PointsRand Seay
13,975 PointsDavid, in your original post, the word "position" is spelled incorrectly. You have "posotion". This worked for me: