I've taken the code from the bootstrap site to come up with the following function which needs to auto open a selected modal if the int: ModalId is not 0. In Vis studio there is a syntax error red line under the ')' before .modal, and in the chrome debugger it says 'uncaught type error, $(...).modal is not a function'. What am I doing wrong please?
$(document).ready(function() {
if (@Model.ModalId != 0) {
$('#accepted_'+@Model.ModalId).modal('show');
}
});