My plan was to make my tables responsive using the FooTable jQuery plugin, but I am struggling with integrating it into my website. Here is the CSS code I have:
<link href="FooTable-2/css/footable.core.css?v=2-0-1" rel="stylesheet" type="text/css"/>
<link href="FooTable-2/css/footable.metro.css" rel="stylesheet" type="text/css"/>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js" type="text/javascript"></script>
<script src="FooTable-2/js/footable.js?v=2-0-1" type="text/javascript"></script>
<script src="FooTable-2/js/footable.sort.js?v=2-0-1" type="text/javascript"></script>
<script src="FooTable-2/js/footable.filter.js?v=2-0-1" type="text/javascript"></script>
<script src="FooTable-2/js/footable.paginate.js?v=2-0-1" type="text/javascript"></script>
<script src="build/javascripts/application.js" type="text/javascript"></script>
Here is the JS code:
<script type="text/javascript">
$(function () {
$('.footable').footable();
});
</script>
And here is the HTML code where the table should be displayed:
<table class="footable">
<thead>
<tr>
<th></th>
<th data-hide="phone,tablet">Nummer</th>
<th>Vorname</th>
<th>Nachname</th>
<th>Adresse</th>
<th data-hide="phone,tablet">Telefon</th>
<th>E-Mail</th>
<th data-hide="phone,tablet">Geburtstag</th>
<th>Kundentyp</th>
</tr>
</thead>
<tbody>
The error message I am getting is:
$('.footable').footable();
Uncaught TypeError: Object [object Object] has no method 'footable'
Any ideas on how I can resolve this issue?