I am doing:
var url = '@Url.Action("Attachments", "Transactions")';
url += '/?id=' + 3201;
$("#attachments").load(url);
However, on load it doesn't do anything. Am i missing something?
I essentially want to call something similar to:
@{Html.RenderAction("Attachments", "Transactions", new { id = 3301 });}
I get the following error on console:
http://server:54137/Transactions/@Url.Action(%22Attachments%22,
.load()- Load data from the server and place the returned HTML into the matched element api.jquery.com/loadconsole.log(url);statement immediately aftervar url = ...and check what it returns.console.log(url);and it printed -/Transactions/Attachments/?id=3201. So please check the other parts of your code.url += '?id=' + 3201;(no forward slash)