Good morning, I have a nav-tabs
done in Bootstrap, which in one of its elements creates a data table in an empty div. I need to change the tab in nav-tab
, that div is empty, but I can not recognize any function added to those buttons. Here is the fragment that corresponds to nav-tab
:
<ul class="nav nav-tabs">
<li><a href="#crInforme" data-toggle="tab" onclick="limpiar()";>Crear Informe</a></li>
<li><a href="#listado" data-toggle="tab">Lista de informes</a></li>
</ul>
As you can see, I have put an event onclick
on one of the tabs, so that when I change, a simple function that I have in a js file is executed:
function limpiar(){
$('#info').html(''); }
With this I only pretend that changing the tab will clean that div, but I can not get it to work.