I've created a div inside a web page that needs to be filled through the jquery
load
function.
<div id="foo">
</div>
This is the call that should fill the div (the call is triggered by some other client side event):
$("#foo").load("/someControllerName/someActionName" + " #foo");
The someActionName
method :
public MvcHtmlString someActionName()
{
//some other irrelevant code
MvcHtmlString returnString = new MvcHtmlString("@Html.ActionLink(" + someFileName + ", \"Download\", new { request = \"" + sameFileId + "\"})");
}
I'm having trouble at actually filling the foo
div with the content of the MvcHtmlString
returned by someActionName
, at the point where the both someFileName
and sameFileId
have valid values. What am I doing wrong? Is what I'm trying to achieve even possible?
Thanks!