i really don't understand how to handle with post data from ajax request. This is my javascript:
$.ajax({
type: "POST",
url: Routing.generate('save'),
contentType: 'application/json; charset=UTF-8',
data: {
title: title,
description: description,
questions: questions,
}
});
The only way to get the data inside my controller action is this:
$content = $request->getContent()
$content is a url parameter string. Why don't i get the data normally with:
$request->get('title')
What is the correct way to handle the post data with jquery ajax methd?
Thank you very much.
EDIT
So, i found out the following issue:
In my current project the request looks like this:

$.ajax({
type: "POST",
url: Routing.generate('poll_save'),
data: {
title: title
}
})
The data is requested via Request Payload but i don't know why.
In a clean project the request looks like this:

$.ajax({
type: "POST",
url: '{{path('_demo')}}',
data: {
title: 'title',
description: 'description',
questions: 'questions',
pollid: 1
}
})
Anything in my project is going wrong. Do you have an idea why the data is requested via Request Payload?