This is because of the conflict of class.
Classes can be applied to n number of html elements to maintain some commoness in css. But, for a click event it is always wise to use Identifiers(id).
So in the div tags apart from class add separate id to each and then go like below:-
<div class="row">
<div class="col-xs-5">
<div class="Tile" id="FQR"><h1 class="text-center">FQR</h1></div>
</div>
<div class="col-xs-5">
<div class="Tile" id="MQR"><h1 class="text-center">MQR</h1> </div>
</div>
</div>
You can't use '@Url.Action("SomeAction", "SomeController")' in js file, because this is ASP.NET MVC helper, if you put your code to the view everything will work.
You can hard code the url also. Like below:-
$(document).ready(function () {
$("#MQR/FQR").click(function () {
$.ajax({
url: "/Create/Task",
type: 'POST',
success: function () {
alert("success");
},
error: function () {
alert('error');
}
});
});
});
Please post back your queries if any.
Thanks