in contao gibt es das modultyp auflistung. folgendes standardtemplate zeigt die inhalte des gewählten datensatzes aus einer datenbank:
<div class="<?php echo $this->class; ?> listing block"<?php echo $this->cssID; ?><?php if ($this->style): ?> style="<?php echo $this->style; ?>"<?php endif; ?>>
<?php if ($this->headline): ?>
<<?php echo $this->hl; ?>><?php echo $this->headline; ?></<?php echo $this->hl; ?>>
<?php endif; ?>
<table class="single_record">
<tbody>
<?php foreach ($this->record as $col): ?>
<tr class="<?php echo $col['class']; ?>">
<td class="label"><?php echo $col['label']; ?></td>
<td class="value"><?php echo $col['content']; ?></td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
<!-- indexer::stop -->
<p class="back"><a href="<?php echo $this->referer; ?>" title="<?php echo $this->back; ?>"><?php echo $this->back; ?></a></p>
<!-- indexer::continue -->
</div>
ich würde das jetzt gerne erweitern, so dass ich mit
<?php
$loesch = mysql_query("DELETE FROM snaps_customer_gr WHERE id = 'AKTUELLER_DATENSATZ'");
?>
genau diesen datensatz lösche.
Nur schaffe ich es mal wieder nicht AKTUELLER_DATENSATZ
mit der id des aufgerufenen datensatzes zu ersetzen, kann mir da jemand helfen?
Grüße
Oly
NACHTRAG: Das Thema hat sich erledigt - ich habe eine Lösung gefunden. Danke
Lesezeichen