Load data from internal/external source to fill form fields

Comparing #8 with #9

Content

[...]
use yii\helpers\Html;
use yii\web\Response;

public function actionGetLocationAddress($id) {
Yii::$app->response->format = Response::FORMAT_JSON;
        //echo JSON data for Get request to read
 
        //always want to encode user input
 
echo Locations::find()->where('id = :id', [':id' => $id])->one();
}
```
Since the function is camelCased you should note that it needs to accessed like.
userlocations/get-location-address
[...]