当我尝试让我的actionlink调用colorbox打开时,它会一直返回“colorbox不是函数”
@Html.DropDownList("JobTypeId", String.Empty) | @Ajax.ActionLink("Add Job Type", "AddJobType",
new AjaxOptions
{
UpdateTargetId = "inline_form",
InsertionMode = InsertionMode.Replace,
HttpMethod = "GET",
OnSuccess = "openbox();"
})
//在标题
中 <script src="@Url.Content("~/Scripts/jquery.colorbox-min.js")" type="text/javascript"></script>
<script type="text/javascript">
function openbox() {
$.colorbox({ width: "50%", inline: true, href: "#inline_form" });
}
</script>