How To Get Latitude And Longitude Value From An Address

hello guys, is there some sort of getLatitude or getLongitude function in yii i want to get the latitude and logitude value from an address to represent it on a google map, kindly help me if any one know about this… thanks in advance :)

It’s as simple as making a curl request to,+United+States

capture the output, json_decode it and find the lat/lng of the location.

i guess there should be a function for this in yii because i have seen a jquery code which is just using .lat() and .lng() for getting latitude and longitude here it is: