61 lines
		
	
	
		
			1.5 KiB
		
	
	
	
		
			HTML
		
	
	
	
	
	
			
		
		
	
	
			61 lines
		
	
	
		
			1.5 KiB
		
	
	
	
		
			HTML
		
	
	
	
	
	
<h1>Meine Hunde</h1>
 | 
						|
 | 
						|
 | 
						|
<figure>
 | 
						|
    <table class="table">
 | 
						|
        <thead>
 | 
						|
            <tr>
 | 
						|
                <th>
 | 
						|
                    Foto
 | 
						|
                </th>
 | 
						|
                <th>
 | 
						|
                    Name
 | 
						|
                </th>
 | 
						|
                <th>
 | 
						|
                    Geburstag
 | 
						|
                </th>
 | 
						|
 | 
						|
                <th>
 | 
						|
                    Aktiv
 | 
						|
                </th>
 | 
						|
 | 
						|
                <th>
 | 
						|
                    Bearbeiten
 | 
						|
                </th>
 | 
						|
                <th>
 | 
						|
                    Löschen
 | 
						|
                </th>
 | 
						|
            </tr>
 | 
						|
        </thead>
 | 
						|
        <tbody>
 | 
						|
            <?php foreach ($doggos as $dog) : ?>
 | 
						|
 | 
						|
            <tr>
 | 
						|
                <td>
 | 
						|
                    <img src="<?= $dog['photo'] ?>/50x50/forcesize">
 | 
						|
                </td>
 | 
						|
 | 
						|
                <td>
 | 
						|
                    <?= escape($dog['name']); ?>
 | 
						|
                </td>
 | 
						|
 | 
						|
                <td>
 | 
						|
                    <?= escape($dog['birthday']); ?>
 | 
						|
                </td>
 | 
						|
 | 
						|
                <td>
 | 
						|
                    <?= escape($dog['active'])?'Ja':'Nein'; ?>
 | 
						|
                </td>
 | 
						|
 | 
						|
                <td>
 | 
						|
                    <button hx-get="/dogs/edit/<?= $dog['id'] ?>" hx-push-url="/dogs/edit/<?= $dog['id'] ?>" hx-target="#main" >Bearbeiten</button>
 | 
						|
                </td>
 | 
						|
                <td>
 | 
						|
                    <button hx-get="/dogs/delete/<?= $dog['id'] ?>" hx-target="#main" hx-confirm="Bist du sicher, dass du <?= escape($dog['name']); ?> löschen willst">Löschen</button>
 | 
						|
                </td>
 | 
						|
            </tr>
 | 
						|
 | 
						|
            <?php endforeach; ?>
 | 
						|
        </tbody>
 | 
						|
    </table>
 | 
						|
</figure> |