-
Notifications
You must be signed in to change notification settings - Fork 13
/
irc.php
71 lines (51 loc) · 1.93 KB
/
irc.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
<?php
require 'lib/function.php';
$windowtitle = "$boardname - IRC Chat";
require 'lib/layout.php';
$servers[1] = "irc.badnik.zone";
$servers[2] = "irc.rustedlogic.net";
$servers[3] = "irc.tcrf.net";
if ($server > count($servers) || $server <= -1) $server = 0;
print "$header<br>";
print " $tblstart<tr>
$tccellh><b>Hold up, it's ". '$' ."YEAR.</b></td></tr>
<tr>$tccell1>Maybe you want to head straight for our <a href='/thread.php?id=17948'>Discord</a>?
$tblend";
print "<br><br>$tblstart<tr>
$tccellh><b>IRC Chat - BadnikZONE, #tcrf, #x</b></td></tr>
<tr>$tccell1>Server List: ";
foreach ($servers as $num => $name) {
if ($num != 1) print " | ";
if ($server == $num) print "<u>";
print "<a href=irc.php?server=". $num .">". $name ."</a>";
if ($server == $num) print "</u>";
if ($num == 1) print " (preferred)";
}
print " <tr>$tccell2>";
if ($server) {
$badchars = array("~", "&", "@", "?", "!", ".", ",", "=", "+", "%", "*");
$name = str_replace(" ", "", $loguser[name]);
$name = str_replace($badchars, "_", $name);
if (!$name) {
$name = "J-Guest";
$guestmsg = "<br>Welcome, guest. When you connect to the IRC network, please use the command <tt>/nick NICKNAME</tt>.<br> <br>";
}
print "
<iframe src=\"https://kiwiirc.com/client/". $servers[$server] ."/?nick=". $name ."|?#tcrf,#x\" style=\"border:0;width:100%;height:500px;\"></iframe>";
} else {
print " <br>Please choose a server to connect to.<br> ";
}
print "$tblend
<br>$tblstart<tr>
$tccellh><b>Quick Help</b></td></tr>
<tr>$tccell1l>Commands:
<br><tt>/nick [name]</tt> - changes your name
<br><tt>/me [action]</tt> - does an action (try it)
<br><tt>/msg [name] [message]</tt> - send a private message to another user
<br><tt>/join [#channel]</tt> - joins a channel
<br><tt>/part [#channel]</tt> - leaves a channel
<br><tt>/quit [message]</tt> - obvious
$tblend
$footer";
printtimedif($startingtime);
?>