-
Notifications
You must be signed in to change notification settings - Fork 114
Expand file tree
/
Copy pathpersonalize.php
More file actions
163 lines (152 loc) · 5.79 KB
/
personalize.php
File metadata and controls
163 lines (152 loc) · 5.79 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
<?php
require_once __DIR__.'/header.php';
?>
<!-- Start Header -->
<?php
include 'top_menu.php';
?>
<!-- End Header -->
<!-- Top Breadcrumb Start -->
<div id="breadcrumb">
<ul>
<li><img src="img/icons/icon_breadcrumb.png" alt="Location" /></li>
<li><strong>Location:</strong></li>
<li class="current">Configure Settings</li>
</ul>
</div>
<!-- Top Breadcrumb End -->
<!-- Right Side/Main Content Start -->
<div id="rightside">
<div class="contentcontainer lg left">
<div class="headings alt">
<h2>Personalize </h2>
</div>
<div class="contentbox">
<a name="columns"></a>
<h2>Show/Hide Columns</h2><br />
<form method="post" action="update_column.php">
<?php
foreach($result as $row) {
echo '<h3>' . $row['displayName'] . ":" . '</h3>' .
'On<input type="radio" ' . ($row['configValue']?'checked':'') . ' name="' . str_replace(' ','',$row['id']) . '" value="1">' .
'Off<input type="radio" ' . (!$row['configValue']?'checked':'') . ' name="' . str_replace(' ','',$row['id']) . '" value="0"><br>' .
'<br>';
} ?>
<input type="submit" class="btn" value="Save" />
</form>
<hr />
<a name="header"></a>
<h2>Taplist Header</h2><br><br>
<?php
$sql="SELECT configValue FROM config WHERE configName ='".ConfigNames::HeaderText."'";
$result=mysql_query($sql);
$headerText=mysql_fetch_array($result);
?>
<p><b>Text to Display:</b></p>
<form method="post" action="update_header_text.php">
<input type="text" class="largebox" value="<?php echo $headerText['configValue']; ?>" name="header_text">  
<input type="submit" class="btn" name="Submit" value="Submit">
</form><br><br>
<?php
$sql="SELECT configValue FROM config WHERE configName ='".ConfigNames::HeaderTextTruncLen."'";
$result=mysql_query($sql);
$headerTextTruncLen=mysql_fetch_array($result);
?>
<p><b>Truncate To:</b> (# characters)</p>
<form method="post" action="update_header_text_trunclen.php">
<input type="text" class="smallbox" value="<?php echo $headerTextTruncLen['configValue']; ?>" name="header_text_trunclen">  
<input type="submit" class="btn" name="Submit" value="Submit">
</form>
<hr />
<a name="untappd"></a>
<h2>Untappd Settings</h2>
<?php
$sql="SELECT configValue FROM config WHERE configName ='".ConfigNames::ClientID."'";
$result=mysql_query($sql);
$Client_ID=mysql_fetch_array($result);
?>
<p><b>Untappd ClientID:</b> </p>
<form method="post" action="update_clientid.php">
<input type="text" class="largebox" value="<?php echo $Client_ID['configValue']; ?>" name="ClientID">  
<input type="submit" class="btn" name="Submit" value="Submit">
</form>
<?php
$sql="SELECT configValue FROM config WHERE configName ='".ConfigNames::ClientSecret."'";
$result=mysql_query($sql);
$Client_Secret=mysql_fetch_array($result);
?>
<p><b>Untappd Client Secret:</b> </p>
<form method="post" action="update_clientsecret.php">
<input type="text" class="largebox" value="<?php echo $Client_Secret['configValue']; ?>" name="ClientSecret">  
<input type="submit" class="btn" name="Submit" value="Submit">
</form>
<?php
$sql="SELECT configValue FROM config WHERE configName ='".ConfigNames::BreweryID."'";
$result=mysql_query($sql);
$BreweryID=mysql_fetch_array($result);
?>
<p><b>Untappd Brewery ID:</b> </p>
<form method="post" action="update_breweryid.php">
<input type="text" class="largebox" value="<?php echo $BreweryID['configValue']; ?>" name="BreweryID">  
<input type="submit" class="btn" name="Submit" value="Submit">
</form>
<hr />
<a name="logo"></a>
<h2>Taplist Logo</h2>
<p>This logo appears on the taplist.</p>
<b>Current image:</b><br /><br />
<img src="../img/logo.png<?php echo "?" . time(); ?>" height="100" alt="Brewery Logo" style="border-style: solid; border-width: 2px; border-color: #d6264f;" />
<form enctype="multipart/form-data" action="update_logo.php" method="POST"><br />
<input name="uploaded" type="file" accept="image/gif, image/jpg, image/png"/>
<input type="submit" class="btn" value="Upload" />
</form>
<hr />
<a name="logo"></a>
<h2>Admin Logo</h2>
<p>This logo appears on the admin panel.</p>
<b>Current image:</b><br /><br />
<img src="img/logo.png<?php echo "?" . time(); ?>" height="100" alt="Brewery Logo" style="border-style: solid; border-width: 2px; border-color: #d6264f;" />
<form enctype="multipart/form-data" action="updateAdminLogo.php" method="POST"><br />
<input name="uploaded" type="file" accept="image/gif, image/jpg, image/png"/>
<input type="submit" class="btn" value="Upload" />
</form>
<hr />
<a name="background"></a>
<h2>Background Image</h2>
<p>This background appears on the taplist.</p>
<b>Current image:</b><br /><br />
<img src="../img/background.jpg<?php echo "?" . time(); ?>" width="200" alt="Background" style="border-style: solid; border-width: 2px; border-color: #d6264f;" />
<form enctype="multipart/form-data" action="update_background.php" method="POST">
<input name="uploaded" type="file" accept="image/gif, image/jpg, image/png"/>
<input type="submit" class="btn" value="Upload" /><br /><br />
</form>
<form action="restore_background.php" method="POST">
<input type="submit" class="btn" value="Restore Default Background" />
</form>
</div>
</div>
<!-- Start Footer -->
<?php
include 'footer.php';
?>
<!-- End Footer -->
</div>
<!-- Right Side/Main Content End -->
<!-- Start Left Bar Menu -->
<?php
include 'left_bar.php';
?>
<!-- End Left Bar Menu -->
<!-- Start Js -->
<?php
include 'scripts.php';
?>
<!-- End Js -->
<!--[if IE 6]>
<script type='text/javascript' src='scripts/png_fix.js'></script>
<script type='text/javascript'>
DD_belatedPNG.fix('img, .notifycount, .selected');
</script>
<![endif]-->
</body>
</html>