All pastes #965996 Raw Edit

Etwas

public text v1 · immutable
·published 2008-04-01 12:11 UTC
rendered paste body
<?php 
#   Copyright by: listenyou

defined ('main') or die ( 'no direct access' );
defined ('admin') or die ( 'only admin access' );

$design = new design ( 'Admins Area', 'Admins Area', 2 );
$design->header();
  
//Eintragen
if (isset($_POST['submit'])) {
	$txt = escape($_POST['txt'],'textarea');
	db_query("INSERT INTO prefix_musiktippbox (txt) VALUES ('$txt')");
}

//DAs TEmplate
$tpl = new tpl('musiktipp', 1);

//Löschen
if ($_GET['delete'] == 1 ) {
	db_query('DELETE FROM `prefix_musiktippbox`');
}

$tpl->out(0);
	
//Ausgabe 
$txt = @db_result(db_query("SELECT txt FROM prefix_musiktippbox"),0);
$tpl->set_out('txt', bbcode($txt), 1);
 
$design->footer();
?>