shout ban help
Code (php)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<?php
if(isset($_SESSION['id'])){
echo '<form method="post" action="?p=shout">
Bericht: <input type="text" name="message" /><input type="submit" value="Versturen" name="submit" /><br /><br />
</form>';
}
if(isset($_SESSION['id']) && $checkFetch['sbanned_until'] != '0000-00-00 00:00:00' and $checkFetch['sbanned_until'] >= date('Y-m-d H:i:s')){
echo '<div style="float: right;"><font color="red">Je hebt een shout ban!</font></div><br />';
}
if(!isset($_SESSION['id'])){
?>
if(isset($_SESSION['id'])){
echo '<form method="post" action="?p=shout">
Bericht: <input type="text" name="message" /><input type="submit" value="Versturen" name="submit" /><br /><br />
</form>';
}
if(isset($_SESSION['id']) && $checkFetch['sbanned_until'] != '0000-00-00 00:00:00' and $checkFetch['sbanned_until'] >= date('Y-m-d H:i:s')){
echo '<div style="float: right;"><font color="red">Je hebt een shout ban!</font></div><br />';
}
if(!isset($_SESSION['id'])){
?>
Maar ze kunnen toch shouten omdat dat shout gedeelte blijft staan wie weet hoe dat weg gaat als iemand een shout ban heeft`
Ga eens debuggen, en echo eens de variabelen $_SESSION['id'] en $checkFetch['sbanned_until']
hoe doe je dat ?
Meer woorden ga ik niet meer vuil maken. Als je niet weet hoe je een variabele echo'ed, dan kan ik niet anders zeggen dan je door te verwijzen naar W3Schools, PHPtuts.nl en php.net/echo.
Gewijzigd op 25/11/2011 17:59:10 door - Ariën -
Ik kan wel php maar dat gebruik ik nooit maare het werkt ook niet :(
Code (php)
1
2
3
4
5
6
7
8
9
10
11
12
13
2
3
4
5
6
7
8
9
10
11
12
13
<?php
if(isset($_SESSION['id']))
{
if($checkFetch['sbanned_until'] >= date('Y-m-d H:i:s'))
{
echo '<div style="float: right;"><font color="red">Je hebt een shout ban!</font></div><br />';
}
else
{
echo '<form method="post" action="?p=shout">Bericht: <input type="text" name="message" /><input type="submit" value="Versturen" name="submit" /><br /><br /></form>';
}
}
?>
if(isset($_SESSION['id']))
{
if($checkFetch['sbanned_until'] >= date('Y-m-d H:i:s'))
{
echo '<div style="float: right;"><font color="red">Je hebt een shout ban!</font></div><br />';
}
else
{
echo '<form method="post" action="?p=shout">Bericht: <input type="text" name="message" /><input type="submit" value="Versturen" name="submit" /><br /><br /></form>';
}
}
?>
Toevoeging op 25/11/2011 19:31:21:
Je bericht is geplaatst!
werkt niet jammer
Toevoeging op 25/11/2011 19:32:19:
EDIT heb ff iets aangepast in id werkt nu
SLOTJE
Toevoeging op 25/11/2011 19:33:45:
werkt weer niet krijg ik :
Parse error: syntax error, unexpected '}' in /home/u657104357/public_html/pages/home.php on line 77
Gewijzigd op 25/11/2011 19:37:47 door Eddy B
Code (php)
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
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
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
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
<br />
<?php
$sQuery = mysql_query("SELECT * FROM shout ORDER BY id DESC LIMIT 25");
$i = 1;
while($sFetch = mysql_fetch_assoc($sQuery)){
$aQuery = mysql_query("SELECT * FROM users WHERE id = '" . mysql_real_escape_string($sFetch['author']) . "'") or die(mysql_error());
$aFetch = mysql_fetch_assoc($aQuery);
?>
<div class="shout" id="shout_<?php echo $i; ?>" style="height: 48px; <?php if($i != 1){ ?>display: none;<?php } ?> border: 1px #00000 solid; background: url(img/shoutbar.png) repeat-x #FFFFFF;">
<table cellspacing="0" cellpadding="0" width="100%">
<tr>
<td style="width: 40px; padding-top: 6px; padding-left: 5px;">
<a target="_blank" href="http://zymoc.t15.org/site.php?name=<?php echo $aFetch['username']; ?>&p=start">
<img alt="Avatar" src="<?php if(@file_exists('img/avatars/'.$aFetch['username'].'.'.$aFetch['avatar_type'])){ echo 'img/avatars/'.$aFetch['username'].'.'.$aFetch['avatar_type']; }else{ echo 'img/noavatar.jpg'; } ?>" style="width: 45px; height: 40px;"/><br />
</a>
</td>
<td style="padding-left: 7px;">
<a target="_blank" href="http://zymoc.t15.org/site.php?name=<?php echo $aFetch['username']; ?>&p=start"><?php echo $aFetch['username']; ?></a>: <?php echo ubb(stripslashes($sFetch['message'])); ?>
<?php
if($team == 1){
?>
<span style="float: right;"><a href="?p=adminpanel&deleteshout=<?php echo $sFetch['id']; ?>"><img src="img/delete.gif" /></a></span>
<?php
}
?>
</td>
</tr>
</table>
</div>
<?php
$i++;
}
?>
<?php
if(isset($_SESSION['id'])){
echo '<form method="post" action="?p=shout">
Bericht:
<input type="text" name="message" /><input type="submit"
value="Versturen" name="submit" /><br /><br />
</form>';
}
if(isset($_SESSION['id']) && $checkFetch['sbanned_until'] != '0000-00-00 00:00:00' and $checkFetch['sbanned_until'] >= date('Y-m-d H:i:s')){
echo '<div style="float: right;"><font color="red">Je hebt een shout ban!</font></div><br />';
}
if(!isset($_SESSION['id'])){
?>
<h1>Maak hier gratis en gemakkelijk je eigen website!</h1>
<table style="border: 0; margin: 0px auto;">
<tr>
<td style="width: 300px;">
<p>Maak gemakelijk een gratis site aan .
Er zijn geen bugs! </p>
</td>
</tr>
</table>
<?php
}else{
$uQuery = mysql_query("SELECT * FROM users WHERE id = '" . mysql_real_escape_string($_SESSION['id']) . "'") or die(mysql_error());
$uFetch = mysql_fetch_assoc($uQuery);
$bQuery = mysql_query("SELECT * FROM forumreactions WHERE author = '" . mysql_real_escape_string($_SESSION['id']) . "' AND NOT type = 4") or die(mysql_error());
$pQuery = mysql_query("SELECT * FROM pages WHERE author = '" . mysql_real_escape_string($_SESSION['id']) . "' AND title = 'start'") or die(mysql_error());
$pFetch = mysql_fetch_assoc($pQuery);
?>
<br /><br />
<div style="background: url(img/home_mystats.png) repeat-x; border: 2px solid #EEE; padding: 6px; font-size: 13px;">
Welkom , <a href="http://zymoc.t15.org/site.php?name=<?php echo $uFetch['username']; ?>&p=start"><?php echo $uFetch['username']; ?></a>! Je hebt <img src="img/coins.png" /> <?php echo $uFetch['credits']; ?> zyms en een zyma van <?php echo $uFetch['karma']; ?>.<br />
Je hebt <?php echo mysql_num_rows(mysql_query("SELECT * FROM forumreactions WHERE author='".mysql_real_escape_string($_SESSION['id'])."'")); ?> forumberichten, <?php echo mysql_num_rows(mysql_query("SELECT * FROM topics WHERE author='".mysql_real_escape_string($_SESSION['id'])."'")); ?> topics en <?php echo mysql_num_rows(mysql_query("SELECT * FROM shout WHERE author='".mysql_real_escape_string($_SESSION['id'])."'")); ?> shouts geplaatst.
</div>
<br /><br />
<?php
?>
</div>
<table style="border: 0;">
<tr>
<!-- first collumn -->
<td style="vertical-align: top; width: 200px;">
<div style="border: 1px dotted #CCCCCC; width: 200px; background: url(img/homegradient.png) #FFFFFF repeat-x; padding: 8px;">
<center>
<span style="font-size: 16.5px;"><a href="http://zymoc.t15.org/site.php?name=<?php echo $uFetch['username']; ?>&p=start"><?php echo $uFetch['username']; ?></span>
<br /><br />
<img src="<?php if(@file_exists('img/avatars/'.$uFetch['username'].'.'.$uFetch['avatar_type'])){ echo 'img/avatars/'.$uFetch['username'].'.'.$uFetch['avatar_type']; }else{ echo 'img/noavatar.jpg'; } ?>" style="width: 100px; height: 100px;"/></a><br />
</a>
</center>
</div>
<br />
<div style="border: 1px dotted #00000; width: 200px; background: url(img/homegradient.png) repeat-x #FFFFFF; padding: 8px;">
<strong style="font-size: 14px;">Algemeen</strong><br /><br />
<li><a href="index.php?p=credits"><span>Credits</span></a></li>
<li><a href="index.php?p=chat"><span>Chat</span></a></li>
<li><a href="index.php?p=myaccount"><span>Avatar Veranderen</span></a></li>
</div>
<br />
<div style="border: 1px dotted #00000; width: 200px; background: url(img/smallergradient.png) repeat-x #FFFFFF; padding: 8px;">
<strong>twitter</strong>
<script src="http://widgets.twimg.com/j/2/widget.js"></script>
<script>
new TWTR.Widget({
version: 2,
type: 'profile',
rpp: 4,
interval: 30000,
width: 200,
height: 300,
theme: {
shell: {
background: '#333333',
color: '#ffffff'
},
tweets: {
background: '#000000',
color: '#ffffff',
links: '#4aed05'
}
},
features: {
scrollbar: false,
loop: false,
live: false,
behavior: 'all'
}
}).render().setUser('zymoc').start();
</script>
</div>
<br />
<div style="border: 1px dotted #00000; width: 200px; background: url(img/smallergradient.png) repeat-x #FFFFFF; padding: 8px;">
<?php
$oQuery = mysql_query("SELECT * FROM users WHERE DATE_SUB(NOW(),INTERVAL 5 MINUTE) <= last_online") or die(mysql_error());
?>
<strong>Er zijn <?php echo mysql_num_rows($oQuery); ?> leden online</strong><br /><br />
» <a href="http://zymoc.t15.org/" style="font-style: italic; color: #969696;"><img src="img/robot.png" /> Zymoc</a><br />
<?php
while($oFetch = mysql_fetch_assoc($oQuery)){
echo '» ' . $oFetch['username'] . '';
if($team == 1)
{
$page = $oFetch['page'];
if($page == '/' or $page == '/index.php' or $page == '/index.php?p=home'){ $page1 = 'Homepage'; }elseif($page == '/favicon.ico'){ $page1 = 'In editor'; }else{ $page1 = $page; }
echo ' (<a href="' . htmlspecialchars($page) . '">' . ucfirst(htmlspecialchars(str_replace('/index.php?p=', '', $page1))) . '</a>)';
}
echo '<br />';
}
?>
</div>
</td>
<td style="width: 10px;"></td>
<td style="vertical-align: top; width: 450px;">
<div style="background: url(img/latesttopics.png) repeat-x #000000; border: 2px solid #FCF2C7; padding: 8px;">
<strong style="font-size: 13px;"><img src="img/comments.png" width="16" height="16" /> Laatste posts</strong><br /><br />
<table style="border: 0;">
<?php
$tQuery = mysql_query("SELECT * FROM topics WHERE last_reaction <= NOW() AND NOT type = 4 AND NOT catid = 1 ORDER BY last_reaction DESC LIMIT 15") or die(mysql_error());
while($tFetch = mysql_fetch_assoc($tQuery)){
?>
<tr>
<td style="width: 200px;">
<a href="?p=forum&showtopic=<?php echo $tFetch['id']; ?>"><img src="img/<?php if($tFetch['type'] == 1){ echo 'topic.png'; }elseif($tFetch['type'] == 2){ echo 'lock.gif'; }elseif($tFetch['type'] == 3){ echo 'sticky.png'; } ?>" /> <?php echo stripslashes($tFetch['title']); ?></a>
</td>
<td>
<?php echo datenl($tFetch['last_reaction']); ?>
</td>
</tr>
<?php
}
?>
</table>
</div>
<br />
<div style="background: url(img/latestnews.png) repeat-x #FFFFFF; border: 2px solid #d0eeff; padding: 10px;">
<strong style="font-size: 13px;"><img src="img/newspaper.png" width="16" height="16" /> Laatste nieuws</strong><br /><br />
<a href="?p=forum&cat=1">» Meer nieuws</a><br /><br />
<table style="border: 0;">
<?php
$nQuery = mysql_query("SELECT * FROM topics WHERE last_reaction <= NOW() AND NOT type = 4 AND catid = 1 ORDER BY last_reaction DESC LIMIT 7") or die(mysql_error());
while($nFetch = mysql_fetch_assoc($nQuery)){
?>
<tr>
<td style="width: 200px;">
<a href="?p=forum&showtopic=<?php echo $nFetch['id']; ?>"><img src="img/information.png" /> <?php echo stripslashes($nFetch['title']); ?></a>
</td>
<td>
<?php echo datenl($nFetch['last_reaction']); ?>
</td>
</tr>
<?php
}
?>
</table>
</div>
</td>
<!-- spacer -->
<td style="width: 10px;"></td>
<!-- third collumn -->
<td style="border: 0; vertical-align: top;">
<div style="border: 1px dotted #CCCCCC; width: 200px; background: url(img/smallergradient.png) repeat-x #FFFFFF; padding: 8px;">
<strong style="font-size: 13px;"><img src="img/group.png" width="16" height="16" />Dit zijn de nieuwe leden</strong><br /><br />
<?php
$nQuery = mysql_query("SELECT * FROM users WHERE NOT type = 4 ORDER BY id DESC LIMIT 5");
while($nFetch = mysql_fetch_assoc($nQuery)){
?>
» <a href="http://zymoc.t15.org/site.php?name=<?php echo $nFetch['username']; ?>&p=start"><?php echo $nFetch['username']; ?></a><br />
<?php
}
?>
</div>
</td>
</tr>
</table>
</table>
<?php
}
?>
<?php
$sQuery = mysql_query("SELECT * FROM shout ORDER BY id DESC LIMIT 25");
$i = 1;
while($sFetch = mysql_fetch_assoc($sQuery)){
$aQuery = mysql_query("SELECT * FROM users WHERE id = '" . mysql_real_escape_string($sFetch['author']) . "'") or die(mysql_error());
$aFetch = mysql_fetch_assoc($aQuery);
?>
<div class="shout" id="shout_<?php echo $i; ?>" style="height: 48px; <?php if($i != 1){ ?>display: none;<?php } ?> border: 1px #00000 solid; background: url(img/shoutbar.png) repeat-x #FFFFFF;">
<table cellspacing="0" cellpadding="0" width="100%">
<tr>
<td style="width: 40px; padding-top: 6px; padding-left: 5px;">
<a target="_blank" href="http://zymoc.t15.org/site.php?name=<?php echo $aFetch['username']; ?>&p=start">
<img alt="Avatar" src="<?php if(@file_exists('img/avatars/'.$aFetch['username'].'.'.$aFetch['avatar_type'])){ echo 'img/avatars/'.$aFetch['username'].'.'.$aFetch['avatar_type']; }else{ echo 'img/noavatar.jpg'; } ?>" style="width: 45px; height: 40px;"/><br />
</a>
</td>
<td style="padding-left: 7px;">
<a target="_blank" href="http://zymoc.t15.org/site.php?name=<?php echo $aFetch['username']; ?>&p=start"><?php echo $aFetch['username']; ?></a>: <?php echo ubb(stripslashes($sFetch['message'])); ?>
<?php
if($team == 1){
?>
<span style="float: right;"><a href="?p=adminpanel&deleteshout=<?php echo $sFetch['id']; ?>"><img src="img/delete.gif" /></a></span>
<?php
}
?>
</td>
</tr>
</table>
</div>
<?php
$i++;
}
?>
<?php
if(isset($_SESSION['id'])){
echo '<form method="post" action="?p=shout">
Bericht:
<input type="text" name="message" /><input type="submit"
value="Versturen" name="submit" /><br /><br />
</form>';
}
if(isset($_SESSION['id']) && $checkFetch['sbanned_until'] != '0000-00-00 00:00:00' and $checkFetch['sbanned_until'] >= date('Y-m-d H:i:s')){
echo '<div style="float: right;"><font color="red">Je hebt een shout ban!</font></div><br />';
}
if(!isset($_SESSION['id'])){
?>
<h1>Maak hier gratis en gemakkelijk je eigen website!</h1>
<table style="border: 0; margin: 0px auto;">
<tr>
<td style="width: 300px;">
<p>Maak gemakelijk een gratis site aan .
Er zijn geen bugs! </p>
</td>
</tr>
</table>
<?php
}else{
$uQuery = mysql_query("SELECT * FROM users WHERE id = '" . mysql_real_escape_string($_SESSION['id']) . "'") or die(mysql_error());
$uFetch = mysql_fetch_assoc($uQuery);
$bQuery = mysql_query("SELECT * FROM forumreactions WHERE author = '" . mysql_real_escape_string($_SESSION['id']) . "' AND NOT type = 4") or die(mysql_error());
$pQuery = mysql_query("SELECT * FROM pages WHERE author = '" . mysql_real_escape_string($_SESSION['id']) . "' AND title = 'start'") or die(mysql_error());
$pFetch = mysql_fetch_assoc($pQuery);
?>
<br /><br />
<div style="background: url(img/home_mystats.png) repeat-x; border: 2px solid #EEE; padding: 6px; font-size: 13px;">
Welkom , <a href="http://zymoc.t15.org/site.php?name=<?php echo $uFetch['username']; ?>&p=start"><?php echo $uFetch['username']; ?></a>! Je hebt <img src="img/coins.png" /> <?php echo $uFetch['credits']; ?> zyms en een zyma van <?php echo $uFetch['karma']; ?>.<br />
Je hebt <?php echo mysql_num_rows(mysql_query("SELECT * FROM forumreactions WHERE author='".mysql_real_escape_string($_SESSION['id'])."'")); ?> forumberichten, <?php echo mysql_num_rows(mysql_query("SELECT * FROM topics WHERE author='".mysql_real_escape_string($_SESSION['id'])."'")); ?> topics en <?php echo mysql_num_rows(mysql_query("SELECT * FROM shout WHERE author='".mysql_real_escape_string($_SESSION['id'])."'")); ?> shouts geplaatst.
</div>
<br /><br />
<?php
?>
</div>
<table style="border: 0;">
<tr>
<!-- first collumn -->
<td style="vertical-align: top; width: 200px;">
<div style="border: 1px dotted #CCCCCC; width: 200px; background: url(img/homegradient.png) #FFFFFF repeat-x; padding: 8px;">
<center>
<span style="font-size: 16.5px;"><a href="http://zymoc.t15.org/site.php?name=<?php echo $uFetch['username']; ?>&p=start"><?php echo $uFetch['username']; ?></span>
<br /><br />
<img src="<?php if(@file_exists('img/avatars/'.$uFetch['username'].'.'.$uFetch['avatar_type'])){ echo 'img/avatars/'.$uFetch['username'].'.'.$uFetch['avatar_type']; }else{ echo 'img/noavatar.jpg'; } ?>" style="width: 100px; height: 100px;"/></a><br />
</a>
</center>
</div>
<br />
<div style="border: 1px dotted #00000; width: 200px; background: url(img/homegradient.png) repeat-x #FFFFFF; padding: 8px;">
<strong style="font-size: 14px;">Algemeen</strong><br /><br />
<li><a href="index.php?p=credits"><span>Credits</span></a></li>
<li><a href="index.php?p=chat"><span>Chat</span></a></li>
<li><a href="index.php?p=myaccount"><span>Avatar Veranderen</span></a></li>
</div>
<br />
<div style="border: 1px dotted #00000; width: 200px; background: url(img/smallergradient.png) repeat-x #FFFFFF; padding: 8px;">
<strong>twitter</strong>
<script src="http://widgets.twimg.com/j/2/widget.js"></script>
<script>
new TWTR.Widget({
version: 2,
type: 'profile',
rpp: 4,
interval: 30000,
width: 200,
height: 300,
theme: {
shell: {
background: '#333333',
color: '#ffffff'
},
tweets: {
background: '#000000',
color: '#ffffff',
links: '#4aed05'
}
},
features: {
scrollbar: false,
loop: false,
live: false,
behavior: 'all'
}
}).render().setUser('zymoc').start();
</script>
</div>
<br />
<div style="border: 1px dotted #00000; width: 200px; background: url(img/smallergradient.png) repeat-x #FFFFFF; padding: 8px;">
<?php
$oQuery = mysql_query("SELECT * FROM users WHERE DATE_SUB(NOW(),INTERVAL 5 MINUTE) <= last_online") or die(mysql_error());
?>
<strong>Er zijn <?php echo mysql_num_rows($oQuery); ?> leden online</strong><br /><br />
» <a href="http://zymoc.t15.org/" style="font-style: italic; color: #969696;"><img src="img/robot.png" /> Zymoc</a><br />
<?php
while($oFetch = mysql_fetch_assoc($oQuery)){
echo '» ' . $oFetch['username'] . '';
if($team == 1)
{
$page = $oFetch['page'];
if($page == '/' or $page == '/index.php' or $page == '/index.php?p=home'){ $page1 = 'Homepage'; }elseif($page == '/favicon.ico'){ $page1 = 'In editor'; }else{ $page1 = $page; }
echo ' (<a href="' . htmlspecialchars($page) . '">' . ucfirst(htmlspecialchars(str_replace('/index.php?p=', '', $page1))) . '</a>)';
}
echo '<br />';
}
?>
</div>
</td>
<td style="width: 10px;"></td>
<td style="vertical-align: top; width: 450px;">
<div style="background: url(img/latesttopics.png) repeat-x #000000; border: 2px solid #FCF2C7; padding: 8px;">
<strong style="font-size: 13px;"><img src="img/comments.png" width="16" height="16" /> Laatste posts</strong><br /><br />
<table style="border: 0;">
<?php
$tQuery = mysql_query("SELECT * FROM topics WHERE last_reaction <= NOW() AND NOT type = 4 AND NOT catid = 1 ORDER BY last_reaction DESC LIMIT 15") or die(mysql_error());
while($tFetch = mysql_fetch_assoc($tQuery)){
?>
<tr>
<td style="width: 200px;">
<a href="?p=forum&showtopic=<?php echo $tFetch['id']; ?>"><img src="img/<?php if($tFetch['type'] == 1){ echo 'topic.png'; }elseif($tFetch['type'] == 2){ echo 'lock.gif'; }elseif($tFetch['type'] == 3){ echo 'sticky.png'; } ?>" /> <?php echo stripslashes($tFetch['title']); ?></a>
</td>
<td>
<?php echo datenl($tFetch['last_reaction']); ?>
</td>
</tr>
<?php
}
?>
</table>
</div>
<br />
<div style="background: url(img/latestnews.png) repeat-x #FFFFFF; border: 2px solid #d0eeff; padding: 10px;">
<strong style="font-size: 13px;"><img src="img/newspaper.png" width="16" height="16" /> Laatste nieuws</strong><br /><br />
<a href="?p=forum&cat=1">» Meer nieuws</a><br /><br />
<table style="border: 0;">
<?php
$nQuery = mysql_query("SELECT * FROM topics WHERE last_reaction <= NOW() AND NOT type = 4 AND catid = 1 ORDER BY last_reaction DESC LIMIT 7") or die(mysql_error());
while($nFetch = mysql_fetch_assoc($nQuery)){
?>
<tr>
<td style="width: 200px;">
<a href="?p=forum&showtopic=<?php echo $nFetch['id']; ?>"><img src="img/information.png" /> <?php echo stripslashes($nFetch['title']); ?></a>
</td>
<td>
<?php echo datenl($nFetch['last_reaction']); ?>
</td>
</tr>
<?php
}
?>
</table>
</div>
</td>
<!-- spacer -->
<td style="width: 10px;"></td>
<!-- third collumn -->
<td style="border: 0; vertical-align: top;">
<div style="border: 1px dotted #CCCCCC; width: 200px; background: url(img/smallergradient.png) repeat-x #FFFFFF; padding: 8px;">
<strong style="font-size: 13px;"><img src="img/group.png" width="16" height="16" />Dit zijn de nieuwe leden</strong><br /><br />
<?php
$nQuery = mysql_query("SELECT * FROM users WHERE NOT type = 4 ORDER BY id DESC LIMIT 5");
while($nFetch = mysql_fetch_assoc($nQuery)){
?>
» <a href="http://zymoc.t15.org/site.php?name=<?php echo $nFetch['username']; ?>&p=start"><?php echo $nFetch['username']; ?></a><br />
<?php
}
?>
</div>
</td>
</tr>
</table>
</table>
<?php
}
?>
Toevoeging op 25/11/2011 19:39:46:
eit : alles
Hoe wat en waar? Als ik jouw was zou ik eerst je code eens verbeteren, want is is best wel bagger. Ga eens gewoon goed inspringen.
**** op 25/11/2011 19:19:29:
Ik kan wel php maar dat gebruik ik nooit maare het werkt ook niet :(
Beetje tegenstrijdig...
Gewijzigd op 22/12/2018 22:34:32 door - Ariën -
Er lopen namelijk netjes rode lijnen door het gedeelte waar de "{" en "}" voor gelden.
maar daar staat {else} dan kan ik toch niet else} maken ennne ik heb notepad plus plus
Als dit er staat: {else}, dan klopt het niet.
idd dat wist ik ook al
Als je nou orde in je code schept, dan kan je zulke fouten ook in één klap zien.
wil gewoon antwoord hoe dit maakt me xml fouten doe ik nog wel we zijn toch in onderhoud
Denk logisch na... denk logisch na, en probeer eens wat.
Gewijzigd op 25/11/2011 20:33:35 door - Ariën -
**** op 25/11/2011 20:28:55:
wil gewoon antwoord hoe dit maakt me xml fouten doe ik nog wel we zijn toch in onderhoud
En ik wil gewoon een Ferrari.... Je mag er zelf ook wel wat voor doen.
Echt Nederlands is het citaat volgens mij niet, maar dat sluit wel aan bij je manier van scripten ;-)
Gewijzigd op 22/12/2018 22:34:50 door - Ariën -
neergezet blijft de error
Obelix en Idefix op 25/11/2011 21:24:34:
Ik moet opeens denken aan dit liedje :-)En ik wil gewoon een Ferrari.... Je mag er zelf ook wel wat voor doen.
http://www.youtube.com/watch?v=QX8cNd_Yc3Q
Gewijzigd op 25/11/2011 21:33:07 door - Ariën -
ja, dus, waarom moet dit dan in een topic? We hebben PM's voor Privé Berichten.