"The boy is next to the dog."
Translation:Drengen er ved hunden.
Yes. "Næste" implies a sequence of objects or events. "Next" and "næste" probably have the same origin, but the use of "næste" as "next to" in Danish got lost many centuries ago.
By the way, the suggested translation is a bit weird. Everyone would say "Drengen er ved siden af hunden." The suggested translation would be more appropriate for "The boy is by the dog".
It's the same as the difference between "by" and "to". "Til" indicates movement from one place to another. "Ved" is static. Drengen gik hen til døren. Nu står han ved døren.
So is med and mad pronounced the same? Do you just distinguish the two with context and spelling?
No, they have different vowel sounds. "Med" has the e-sound from "ending". The vowel sound from "mad" does not exist in English but it's the standard Danish a-sound.
The synthetic voice isn't great, but the a in mad sounds somewhere between an a and an e to me. I found this video really useful: https://www.youtube.com/watch?v=uvCIdu0BAoo&index=27&list=PLqsA5kK1_Ui-AfqX0alux2XQTd0VeMjOu
Also, even if you can't tell the difference between the vowels, "med" is usually just pronounced "mæ'" - especially when it's not the last word in the sentence. "Mad" always has the "d" at the end pronounced (except - for completeness' sake - in a few regional dialects).