<div class="col-lg-12">
    <div class="ibox float-e-margins">
        <div class="ibox-title">
            <h5>Prefix buttons overzicht</h5>
            <div class="ibox-tools">
                <a class="collapse-link">
                    <i class="fa fa-chevron-up"></i>
                </a>
                <a href="streams.php?i=toevoegen">  <i class="fa fa-plus"></i></a>
                <a class="dropdown-toggle" data-toggle="dropdown" href="#">
                    <i class="fa fa-wrench"></i>
                </a>
                <ul class="dropdown-menu dropdown-user">
                    <li><a href="#">Alle alarmen verwijderen</a></li>
                </ul>
                <a class="close-link">
                    <i class="fa fa-times"></i>
                </a>
            </div>
        </div>
        <div class="ibox-content">
            <table class="table table-striped">
                <thead>
                    <tr>
                        <th>Button#</th>
                        <th>Naam</th>
                        <th>StreamUrl</th>
                        <th>Acties</th>
                    </tr>
                </thead>
                <tbody>
                    <?php
                    	if($stmt = $mysqli -> prepare("SELECT id, buttonid, name, streamurl, streamport, streamip FROM PresetRadioStream WHERE uid=?")){
                        	$stmt -> bind_param('i', $userid);
                        	$stmt -> execute();
                        	$stmt -> bind_result($id, $buttonid, $name, $streamurl, $streamport, $streamip);
                        	while($result = $stmt -> fetch()){
                                print '
                                 <tr>
                    	            <td>'.$buttonid.'</td>
                    	            <td>'.$name.'</td>
                    	            <td>'.$streamip.':'.$streamport.''.$streamurl.'</td>
                    	            <td style="width: 100px !important" class="text-center valign-middle" >
    					                <a href="streams.php?i=wijzigen&id='.$id.'"><button class="btn btn-xs btn-primary"><i class="fa fa-pencil"></i></button></a>
    				                </td>
                    	        </tr>                         ';
                        	};
                        	$stmt -> close();
                        }
                    ?>
                </tbody>
            </table>
        </div>
    </div>
</div>