//front:
data = {"id":1,"name":"someName"}; //....
apiUrl = "/users/"+data.id;
sendAjax(apiUrl, data);
//back:
UsersController {
function actionUpdate($id) {
//load POST
}
}
$latests = Project::find()->where(['status' => 1])->orderBy(['id' => SORT_DESC])->limit(10)->all();