You also have to use data-target = “#identifier” instead of href = “#” along with the attribute data-toggle. These are used when the browser does not support JavaScript. Consider the following lines of code in which we have done this: