Mein Export to Excel-Schaltfläche nicht angezeigt, auch nachdem ich diesen Code oben verwendet. Ich habe keine Ahnung, was mit dem Code passiert. Jemand mit mehr Erfahrung bitte hilf mir. Ich habe meine Referenz von https://datatables.net/extensions/buttons/examples/initialisation/export.htmlExport nach Excel-Schaltfläche nicht angezeigt
<table id="example" class="display nowrap" cellspacing="0" width="100%">
<thead>
<tr>
<th>Name</th>
<th>Position</th>
<th>Office</th>
<th>Age</th>
<th>Start date</th>
<th>Salary</th>
</tr>
</thead>
<tbody>
<tr>
<td>Tiger Nixon</td>
<td>System Architect</td>
<td>Edinburgh</td>
<td>61</td>
<td>2011/04/25</td>
<td>$320,800</td>
</tr>
<tr>
<td>Garrett Winters</td>
<td>Accountant</td>
<td>Tokyo</td>
<td>63</td>
<td>2011/07/25</td>
<td>$170,750</td>
</tr>
<tr>
<td>Ashton Cox</td>
<td>Junior Technical Author</td>
<td>San Francisco</td>
<td>66</td>
<td>2009/01/12</td>
<td>$86,000</td>
</tr>
</tbody>
</table>
<script>
$(document).ready(function() {
$('#example').DataTable({
dom: 'Bfrtip',
buttons: [
'excel'
]
});
});
</script>
Hier ist die Ausgabe der Konsole:
1) Müssen wir wirklich alle Zeilen in Ihrem Beispiel sehen? Halte es auf ein Minimum! 2) Öffnen Sie die Entwicklerkonsole Ihres Browsers, führen Sie Ihren Code aus und lassen Sie uns, wenn Sie irgendwelche Konsolenfehler haben. 3) Fügen Sie diese zu Ihrer Frage hinzu. –
@LeeTaylor Es tut mir leid Sir, es ist mein erstes Mal .. Ich habe meine Frage aktualisiert BTW Danke für Ihre Tipps – coposaja