'How to change Google embedded map location by clicking a link?

I have a Google map embed on my website using iframe. I want a way to simply change the map location by just clicking a link with the new location. What would be the best way to go about this?

I saw a post that doesn't what I think I want but it's using buttons and only the lat and long of the location. I would like to use link instead and onclick, the embedded iframe src will be replaced with the link.

e.g.

<a href="https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d3970.8538282671702!2d-0.18627538437966853!3d5.588610634872513!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0xfdf9af427d8e49f%3A0xabf4a7f91a3e2449!2s37%20Military%20Teaching%20Hospital!5e0!3m2!1sen!2sgh!4v1653343391596!5m2!1sen!2sgh" onClick('change iframe src');>Map 2</a>

OnClick, iframe src should change;

<iframe src="https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d3970.8758862686095!2d-0.18530028523393915!3d5.58535699595063!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0xfdf9af4620ee00b%3A0x7c232f1b19c4023c!2sAdinkra+Heights!5e0!3m2!1sen!2sgh!4v1522148522919" width="100%" height="100%" frameborder="0" style="border:0" allowfullscreen=""></iframe>


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source