Subversion-Projekte lars-tiefland.content-management

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
1 lars 1
<?
2
	require_once "connect2.php";
3
	session_start();
4
	if (!$language) {$language="DE";}
5
 
6
	if ($template_ID)
7
	{
8
		$query="
9
			delete
10
				templates_to_".$Typ.".*
11
			FROM
12
				templates_to_".$Typ.",
13
				templates
14
			WHERE
15
				templates_to_".$Typ.".templates_ID = templates.ID
16
			and
17
				templates.shops_ID = $shops_ID
18
			and
19
				templates_to_".$Typ.".".$Typ."_ID = $ID
20
			";
21
		$result = mysql_query ($query) or die (mysql_errno().": ".mysql_error()."<hr>".$query);
22
 
23
		if ($template_ID > 0)
24
		{
25
			$query="insert into templates_to_".$Typ." values ($template_ID, $ID)";
26
			$result = mysql_query ($query) or die (mysql_errno().": ".mysql_error()."<hr>".$query);
27
		}
28
	}
29
?>
30
<html>
31
<head>
32
<title>Template Control</title>
33
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
34
<meta name="author" content="Webagentur Niewerth - www.weban.de">
35
<meta name="revisit-after" content="30 days">
36
<meta name="language" content="deutsch, de">
37
<meta name="distribution" content="global">
38
<meta name="robots" content="all">
39
<link rel=stylesheet type="text/css" href="redaktion.css">
40
<style type="text/css">
41
body
42
{
43
	font-family: Arial, Helvetica, sans-serif; font-size: 10pt;
44
<? if ($webs[font_color_seite])		{ ?>color:				#<? echo $webs[font_color_rechts] ?>;<? } ?>
45
<? if ($webs[bgcolor_seite])		{ ?>background-color:	#<? echo $webs[bgcolor_rechts] ?>;<? } ?>
46
}
47
 
48
.links
49
{
50
font-size: 10pt;
51
<? if ($webs[font_color_links])		{ ?>color:				#<? echo $webs[font_color_links] ?>;<? } ?>
52
<? if ($webs[bgcolor_links])		{ ?>background-color:	#<? echo $webs[bgcolor_links] ?>;<? } ?>
53
}
54
 
55
.rechts
56
{
57
font-size: 10pt;
58
<? if ($webs[font_color_rechts])	{ ?>color:				#<? echo $webs[font_color_rechts] ?>;<? } ?>
59
<? if ($webs[bgcolor_rechts])		{ ?>background-color:	#<? echo $webs[bgcolor_rechts] ?>;<? } ?>
60
}
61
 
62
A:link {font-family: Arial, Helvetica, sans-serif; font-size: 10pt; color: #<? echo $webs[font_color_rechts] ?>}
63
A:visited {font-family: Arial, Helvetica, sans-serif; font-size: 10pt; color: #<? echo $webs[font_color_rechts] ?>}
64
A:active {font-family: Arial, Helvetica, sans-serif; font-size: 10pt; color: #<? echo $webs[font_color_rechts] ?>}
65
A:hover {font-family: Arial, Helvetica, sans-serif; font-size: 10pt; color: #<? echo $webs[font_color_rechts] ?>}
66
<MM:EndLock></style>
67
</head>
68
 
69
<body leftmargin="0" topmargin="0">
70
<form action="<?=$self;?>">
71
<?
72
	$query="
73
		SELECT
74
			templates_to_".$Typ.".templates_ID as a
75
		FROM
76
			templates_to_".$Typ.",
77
			templates
78
		WHERE
79
			templates_to_".$Typ.".templates_ID = templates.ID
80
		and
81
			templates.shops_ID = $shops_ID
82
		and
83
			templates_to_".$Typ.".".$Typ."_ID = $ID
84
		";
85
	$result = mysql_query ($query) or die (mysql_errno().": ".mysql_error()."<hr>".$query);
86
	$selected=mysql_fetch_array($result);
87
	$selected=$selected[a];
88
 
89
	$query="SELECT * FROM templates WHERE shops_ID = $shops_ID and Typ='".$Typ."'";
90
	$result = mysql_query ($query) or die (mysql_errno().": ".mysql_error()."<hr>".$query);
91
	while($zeile=mysql_fetch_array($result))
92
	{
93
?>
94
<input type=radio name=template_ID value=<?=$zeile[ID];?><? if ($zeile[ID] == $selected) { ?> checked<? } ?> onClick="this.blur();this.focus();" onChange="this.form.submit()"><? echo $zeile[Name] ?><br>
95
<?
96
	}
97
?>
98
<input type=radio name=template_ID value=-1 onClick="this.blur();this.focus();" onChange="this.form.submit()">löschen
99
<input type=hidden name=Typ value="<?=$Typ;?>">
100
<input type=hidden name=shops_ID value="<?=$shops_ID;?>">
101
<input type=hidden name=ID value="<?=$ID;?>">
102
</form>
103
</body>
104
</html>
105