function change_rankAction() { $profile_id = AF::get($_POST, 'profile_id', 0); $change = AF::get($_POST, 'change', 0); if ($change == "up") { $change = -1; } else { $change = +1; } $model = new ProfileGateway(); $model->fillFromArray($_POST); $model->changeRank($change); unset($model); Message::echoJsonRedirect("/lj3/profiles/update/id=" . $profile_id); }