Compare commits

...

No commits in common. 'znc-1.8.2' and 'e4aef30eb510e8926068e43711e6c4aa65fc5dc2' have entirely different histories.

@ -3,57 +3,19 @@ zncstrap
A simple ZNC Web Interface theme build with Twitter Bootstrap Framework.
Modified by casper@LunarBNC for 1.8.2
Some things were added and mainly all pages needed i18n inclusion as well.
This 'dev' (development) branch is mainly for ZNC v.1.7-git or later.
If there are any issues, feel free to contact me at ircs://irc.lunarirc.net:6697/LunarBNC
### Update
If you want to make a donation to LunarBNC, please use the following PayPal link;
https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=NV76KTTXLLDVC
June 11th 2015: Work is in progress. Some bits might not run smoothly (broken) on ZNC v.1.7-git as of now. Hang in there.
### Original source
https://github.com/FirrreHQ/zncstrap
### To-Do
No updates for over 5 years and firrre stopped hosting as far as I know
- The user setings page is way too long. Find a way to make it short yet organized
- Clean out the codes and align accordingly
- Swap to a switch-like checkbox
- Test Google Charts to output traffic data, visually
- Tables should be made more responsive, able to view on smaller devices
### Screenshot
Please see [Screenshot](./screenshot.png 'screenshot')
### Installing zncstrap
Step 1 - Get a latest version of zncstrap. Branches are split in the versions that it should work with. The "main" branch should be on the latest version, but no guarantees.
Step 2 - We strongly advice you to make backups of your current ZNC setup (config files and folders, just to be on the safe-side) before you proceed to install zncstrap theme. Once you have your backups stored elsewhere, you can proceed to remove the default theme(s) webskins and modules folder.
You can do so by pointing to /home/username/znc/share/znc, or generally $datadir/share/znc. If you have installed ZNC through a software package manager such as: Advanced Packaging Tool (Apt) or Yellowdog Updater, Modified (yum). You will need to navigate to /usr/local/share/znc/ or /usr/share/znc as the webskins static files resides there (file directries may vary). If all else fails, try using the 'whereis' tool on Linux. You can do so by executing the following command in your terminal / console: whereis znc
Step 3 - Navigate to the above mentioned directory and delete/move the 'modules' & 'webskins' directories, not doing this can cause odd results.
Step 4 - Once it has completely removed, you can now go ahead and upload all zncstrap files that you have downloaded from the GitHub repository.
> ~/zncstrap/webskins <-> $datadir/share/znc/webskins
> ~/zncstrap/modules <-> $datadir/share/znc/modules
Once completed, you're good to go! - Login to your web-interface http://ip:port or http://domain.tld:port via any of your preferred web browsers.
### FAQ
**Q: Why can't zncstrap work alongside the default ZNC themes itself?**
A: Mainly because the different HTML tags and attributes used in zncstrap, as part of Twitter Bootstrap specifically in "~/znc/share/znc/modules/webadmin/tmpl" (e.g http://git.io/qj8MKg to http://git.io/SofsZg). If it had been left un-edited, it will not be visually pleasing and would be looking all off-margin. As the CSS bits are different and varies. Hence why the default ZNC themes should be removed as it will no longer serve any good when zncstrap is installed.
**Q: I installed zncstrap, but it is off-margin and un-styled!**
A: You should overwrite everything from '~/zncstrap/modules' to "~/share/znc/modules" or "/usr/local/share/znc/modules" on your machine.
### Technologies & Scripts
- Twitter Bootstrap version 3
- jQuery
- Bootstrap JavaScript tools
- Bootswatch Themes
- Divshot Bootstrap Themes
- Google Charts
### More information and screenshots
Website: https://firrre.com/zncstrap

@ -1,8 +1,6 @@
<? I18N znc-blockuser ?>
<input type="hidden" name="embed_blockuser_presented" value="1"/>
<input type="hidden" name="embed_blockuser_old" value="<? VAR Blocked ?>"/>
<div class="switch">
<input type="checkbox" name="embed_blockuser_block" id="opt_embed_blockuser_block" value="1" class="cmn-toggle cmn-toggle-round-flat"<? IF Blocked ?> checked="checked"<? ENDIF ?><? IF Self ?> disabled="disabled"<? ENDIF ?> />
<label for="opt_embed_blockuser_block"></label>
</div>
</div>

@ -1,21 +1,19 @@
<? I18N znc-cert ?>
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
<div class="panel panel-default">
<div class="panel-heading"><? FORMAT "Certificate" ?></div>
<div class="panel-heading">Certificate</div>
<div class="panel-body">
<? IF Cert ?>
<? SETBLOCK DELLINK ?><a href="<? VAR URIPrefix TOP ?><? VAR ModPath ?>delete"><? FORMAT "here" "TRANSLATORS: this text is inserted into `click here` in the other string"?></a><? ENDSETBLOCK ?>
<div class="alert alert-success"><? FORMAT "You already have a certificate set, use the form below to overwrite the current certificate. Alternatively click {1} to delete your certificate." "DELLINK ESC=" "TRANSLATORS: {1} is `here`, translateable in the other string" ?></div>
<div class="alert alert-success">You already have a certificate set, use the form below to overwrite the current certificate. Alternatively click <a href="<? VAR URIPrefix TOP ?><? VAR ModPath ?>delete">here</a> to <a href="<? VAR URIPrefix TOP ?><? VAR ModPath ?>delete">delete</a> your certificate.</div>
<? ELSE ?>
<div class="alert alert-danger"><? FORMAT "You do not have a certificate yet." ?></div>
<div class="alert alert-danger">You do not have a cert.</div>
<? ENDIF ?>
<form class="form-horizontal" method="post" action="<? VAR URIPrefix TOP ?><? VAR ModPath ?>update">
<? INC _csrf_check.tmpl ?>
<div class="form-group">
<label for="inputPEM" class="col-sm-2 control-label"><? FORMAT "PEM File:" ?></label>
<label for="inputPEM" class="col-sm-2 control-label">PEM File: </label>
<div class="col-sm-10">
<textarea class="form-control" rows="5" name="cert"></textarea>
</div>
@ -23,9 +21,9 @@
</div>
<div class="panel-footer text-right">
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" name="add" value="<? FORMAT "Update" ?>" />
<input class="btn btn-success" type="submit" name="add" value="Update" />
</div>
</form>
</form>
</div>
</div>

@ -1,21 +1,20 @@
<? I18N znc-certauth ?>
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
<div class="panel panel-default">
<div class="panel-heading"><? FORMAT "Add a key" ?></div>
<div class="panel-heading">Certauth &mdash; Add A Note</div>
<div class="panel-body">
<form class="form-horizontal" method="post" action="<? VAR URIPrefix TOP ?><? VAR ModPath ?>add">
<? INC _csrf_check.tmpl ?>
<div class="form-group">
<label for="inputKey" class="col-sm-2 control-label"><? FORMAT "Key:" ?></label>
<label for="inputKey" class="col-sm-2 control-label">Key:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputKey" name="key" size="40">
</div>
</div>
<? IF !KeyLoop ?>
<p class="text-center"><? FORMAT "You have no keys." ?></p>
<p class="text-center">You have no keys.</p>
<? ELSE ?>
<br />
@ -23,14 +22,14 @@
<table class="table table-bordered table-hover">
<thead>
<tr>
<td></td>
<td><? FORMAT CTX="web" "Key" ?></td>
<td>Action</td>
<td>Key</td>
</tr>
</thead>
<tbody>
<? LOOP KeyLoop ?>
<tr>
<td><a href="<? VAR ModPath ?>delete?key=<? VAR Key ESC=URL,HTML ?>" class="btn btn-danger btn-xs"><? FORMAT "del" ?></a></td>
<td><a href="<? VAR ModPath ?>delete?key=<? VAR Key ESC=URL,HTML ?>" class="btn btn-danger btn-xs">Delete</a></td>
<td><? VAR Key ?></td>
</tr>
<? ENDLOOP ?>
@ -41,7 +40,7 @@
<div class="panel-footer text-right">
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" name="add" value="<? FORMAT "Add Key" ?>" />
<input class="btn btn-success" type="submit" name="add" value="Add Key" />
</div>
</form>
</div>

@ -1,9 +1,8 @@
<? I18N znc-lastseen ?>
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
<div class="panel panel-default">
<div class="panel-heading"><? FORMAT "Last Seen" ?></div>
<div class="panel-heading">Last Seen</div>
<div class="panel-body">
<div class="row">
<div class="col-md-4 col-md-offset-8">
@ -21,10 +20,10 @@
<table class="table table-bordered table-hover table-striped table-list-search">
<thead>
<tr>
<td><? FORMAT "User" ?></td>
<td><? FORMAT "Last Seen" ?></td>
<? REM ?><td><? FORMAT "Info" ?></td><? ENDREM ?>
<? IF WebAdminLoaded ?><td><? FORMAT "Action" ?></td><? ENDIF ?>
<td>User</td>
<td>Last Seen</td>
<td>Info</td>
<? IF WebAdminLoaded ?><td>Action</td><? ENDIF ?>
</tr>
</thead>
<tbody>
@ -32,12 +31,12 @@
<tr>
<td><? VAR Username ?></td>
<td><? VAR LastSeen DEFAULT="- unknown -" ?></td>
<? REM ?><td><? VAR Info ?> <? VAR Ident ?></td><? ENDREM ?>
<td><? VAR Info ?> <? VAR Ident ?></td>
<? IF WebAdminLoaded TOP ?>
<td>
<a href="<? VAR URIPrefix TOP ?>/mods/global/webadmin/edituser?user=<?VAR Username ESC=URL?>" class="btn btn-primary btn-xs"><? FORMAT "Edit" ?></a>
<a href="<? VAR URIPrefix TOP ?>/mods/global/webadmin/edituser?user=<?VAR Username ESC=URL?>" class="btn btn-primary btn-xs">Edit</a>
<? IF !IsSelf ?>
<a href="<? VAR URIPrefix TOP ?>/mods/global/webadmin/deluser?user=<?VAR Username ESC=URL?>" class="btn btn-danger btn-xs"><? FORMAT "Delete" ?></a>
<a href="<? VAR URIPrefix TOP ?>/mods/global/webadmin/deluser?user=<?VAR Username ESC=URL?>" class="btn btn-danger btn-xs">Delete</a>
<? ENDIF ?>
</td>
<? ENDIF ?>

@ -1,6 +1,5 @@
<? I18N znc-lastseen ?>
<div class="form-group">
<div class="col-sm-10">
<input type="text" class="form-control" id="inputLastseen" name="<? FORMAT "Last login time:" ?>" value="<? VAR LastSeen DEFAULT="- unknown -" ?>" disabled>
<input type="text" class="form-control" id="inputLastseen" name="seen" value="<? VAR LastSeen DEFAULT="No Data..." ?>" disabled>
</div>
</div>

@ -1,4 +1,3 @@
<? I18N znc-listsockets ?>
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
@ -8,14 +7,14 @@
<table class="table table-bordered table-hover">
<thead>
<tr>
<td><? FORMAT "Name" ?></td>
<td><? FORMAT "Created" ?></td>
<td><? FORMAT "State" ?></td>
<td><? FORMAT "SSL" ?></td>
<td><? FORMAT "Local" ?></td>
<td><? FORMAT "Remote" ?></td>
<td><? FORMAT "Data In" ?></td>
<td><? FORMAT "Data Out" ?></td>
<td>Name</td>
<td>Created</td>
<td>State</td>
<td>SSL</td>
<td>Local</td>
<td>Remote</td>
<td>Data In</td>
<td>Data Out</td>
</tr>
</thead>
<tbody>

@ -1,37 +1,36 @@
<? I18N znc-notes ?>
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
<div class="panel panel-default">
<div class="panel-heading"><? FORMAT "Add A Note" ?></div>
<div class="panel-heading">Notes &middot; Add A Note</div>
<div class="panel-body">
<form class="form-horizontal" method="post" action="<? VAR URIPrefix TOP ?><? VAR ModPath ?>addnote">
<? INC _csrf_check.tmpl ?>
<div class="form-group">
<label for="inputKey" class="col-sm-2 control-label"><? FORMAT "Key:" ?></label>
<label for="inputKey" class="col-sm-2 control-label">Key:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputKey" name="key" size="8">
</div>
</div>
<div class="form-group">
<label for="inputNote" class="col-sm-2 control-label"><? FORMAT "Note:" ?></label>
<label for="inputNote" class="col-sm-2 control-label">Note:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputNote" name="note" size="40">
</div>
</div>
<? IF !NotesLoop ?>
<div class="alert alert-warning"><? FORMAT "You have no notes to display." ?></div>
<div class="alert alert-warning">You have no notes to display.</div>
<? ELSE ?>
<table class="table table-bordered table-hover">
<thead>
<tr>
<td><? FORMAT "Key" ?></td>
<td><? FORMAT "Note" ?></td>
<td></td>
<td>Key</td>
<td>Note</td>
<td>Action</td>
</tr>
</thead>
<tbody>
@ -39,7 +38,7 @@
<tr>
<td><? VAR Key ?></td>
<td><? VAR Note ?></td>
<td><a href="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>delnote?key=<? VAR Key ESC=URL,HTML ?>" class="btn btn-danger btn-xs"><? FORMAT "[del]" ?></a></td>
<td><a href="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>delnote?key=<? VAR Key ESC=URL,HTML ?>" class="btn btn-danger btn-xs">Delete</a></td>
</tr>
<? ENDLOOP ?>
</tbody>
@ -49,7 +48,7 @@
<div class="panel-footer text-right">
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" name="add" value="<? FORMAT "Add Note" ?>" />
<input class="btn btn-success" type="submit" name="add" value="Add Note" />
</div>
</form>
</div>

@ -1,24 +1,23 @@
<? I18N znc-perform ?>
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
<div class="panel panel-default">
<div class="panel-heading"><? FORMAT "Perform" ?></div>
<div class="panel-heading">Perform &middot; Add a Command</div>
<div class="panel-body">
<form method="post" action="<? VAR URIPrefix TOP ?><? VAR ModPath ?>">
<? INC _csrf_check.tmpl ?>
<div class="form-group">
<label for="inputperformCommands" class="col-sm-2 control-label"><? FORMAT "Perform commands:" ?></label>
<label for="inputperformCommands" class="col-sm-2 control-label">Commands:</label>
<div class="col-sm-10">
<textarea type="text" class="form-control" id="inputperformCommands" name="perform" cols="70" rows="5" class="monospace"><? LOOP PerformLoop ?><? VAR Perform ?><? ENDLOOP ?></textarea>
<div class="alert alert-info help-block"><? FORMAT "Commands sent to the IRC server on connect, one per line." ?></div>
<div class="alert alert-info help-block">Commands sent to the IRC server on connect, one per line.</div>
</div>
</div>
</div>
<div class="panel-footer text-right">
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" name="save" value="<? FORMAT "Save" ?>" />
<input class="btn btn-success" type="submit" name="save" value="Save" />
</div>
</form>
</div>

@ -0,0 +1,60 @@
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
<div class="panel panel-default">
<div class="panel-heading">Q Network Module</div>
<div class="panel-body">
<form class="form-horizontal" action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>" method="post">
<? INC _csrf_check.tmpl ?>
<div class="form-group">
<label for="inputStatusPrefix" class="col-sm-2 control-label">Username:</label>
<div class="col-sm-10">
<input type="text" class="form-control" name="user" value="<? VAR Username ?>" class="half" maxlength="128" placeholder="Please enter a username" />
</div>
</div>
<div class="form-group">
<label for="inputStatusPrefix" class="col-sm-2 control-label">Password:</label>
<div class="col-sm-10">
<input type="text" class="form-control" type="password" name="password" class="half" placeholder="Please enter a password" autocomplete="off" />
</div>
</div>
<div class="row">
<div class="col-md-6 col-md-offset-3">
<table class="table table-bordered table-hover table-striped">
<thead>
<tr>
<td>Status</td>
<td>Settings</td>
</tr>
</thead>
<tbody>
<? LOOP OptionLoop ?>
<tr>
<td>
<div class="switch" title="<? VAR Tooltip ?>">
<input type="checkbox" name="<? VAR Name ?>" id="opt_<? VAR Name ?>" value="1" class="cmn-toggle cmn-toggle-round-flat"<? IF Checked ?> checked="checked"<? ENDIF ?><? IF Disabled ?>disabled="disabled"<? ENDIF ?>"/>
<label for="opt_<? VAR Name ?>"></label>
</div>
</td>
<td>
<? VAR DisplayName ?>
</td>
</tr>
<? ENDLOOP ?>
</tbody>
</table>
</div>
</div>
</div>
<div class="panel-footer text-right">
<input type="hidden" name="submitted" value="1" />
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" value="Save" />
</div>
</form>
</div>
</div>
<? INC Footer.tmpl ?>

@ -1,77 +1,140 @@
<? I18N znc-sasl ?>
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
<div class="panel panel-default">
<div class="panel-heading"><? FORMAT "SASL" ?></div>
<form class="form-horizontal" action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>" method="post">
<div class="panel-body">
<div class="panel-heading">Simple Authentication and Security Layer (SASL)</div>
<div class="panel-body">
<form class="form-horizontal" action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>" method="post">
<? INC _csrf_check.tmpl ?>
<div class="form-group">
<label for="inputSASLUsername" class="col-sm-2 control-label"><? FORMAT "Username:" ?></label>
<div class="form-group">
<label for="inputSASLUsername" class="col-sm-2 control-label">Username:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputSASLUsername" name="username" maxlength="128" placeholder="<? FORMAT "Please enter a username." ?>">
<input type="text" class="form-control" id="inputSASLUsername" name="username" maxlength="128" placeholder="Enter a Username">
</div>
</div>
</div>
<div class="form-group">
<label for="inputSASLPassword" class="col-sm-2 control-label"><? FORMAT "Password:" ?></label>
<div class="form-group">
<label for="inputSASLPassword" class="col-sm-2 control-label">Password:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputSASLPassword" name="username" placeholder="<? FORMAT "Please enter a password." ?>" autocomplete="off">
<input type="text" class="form-control" id="inputSASLPassword" name="username" placeholder="Enter a Password" autocomplete="off">
</div>
</div>
</div>
<div class="form-group">
<label for="inputSASLUsername" class="col-sm-2 control-label"><? FORMAT "Options" ?></label>
<div class="form-group">
<label for="inputSASLUsername" class="col-sm-2 control-label">Connect:</label>
<div class="col-sm-10">
<div class="switch">
<input type="checkbox" name="require_auth" id="opt_require_auth" class="cmn-toggle cmn-toggle-round-flat" value="1"<? IF RequireAuth ?> checked="checked"<? ENDIF ?> />
<label for="opt_require_auth"></label>
<span class="help-block"><? FORMAT "Connect only if SASL authentication succeeds." ?></span>
<span class="help-block">Connect only if SASL authentication succeeds. Require authentication</span>
</div>
</div>
</div>
<div class="form-group">
<label for="inputMechanismsDescription" class="col-sm-2 control-label"><? FORMAT "Mechanisms" ?></label>
<div class="col-sm-10">
<table class="data">
<thead>
<tr>
<th><? FORMAT "Name" ?></th>
<th><? FORMAT "Description" ?></th>
</tr>
</thead>
<tbody>
<? LOOP MechanismLoop SORTASC=Name ?>
<tr class="<? IF __EVEN__ ?>evenrow<? ELSE ?>oddrow<? ENDIF ?>">
<td><? VAR Name ?></td>
<td><? VAR Description ?></td>
</tr>
<? ENDLOOP ?>
</tbody>
</table>
</div>
<label for="inputMechanisms" class="col-sm-2 control-label"><? FORMAT "Selected mechanisms and their order:" ?></label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputMechanisms" name="mechanisms" value="<? VAR Mechanisms ?>">
<script>
$("#inputMechanisms").selectize({
plugins: ["drag_drop"],
delimiter: " ",
options: [<? LOOP MechanismLoop SORTASC=Name ?>{value:"<? VAR Name ?>",text:"<? VAR Name ?>"},<? ENDLOOP ?>],
});
</script>
</div>
</div>
<div class="panel-footer text-right">
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" name="save" value="<? FORMAT "Save" ?>" />
</div>
</form>
</div>
<div class="panel-footer text-right">
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" name="save" value="Save" />
</div>
</form>
</div>
</div>
<? INC Footer.tmpl ?>
<!--
<div class="section">
<h3></h3>
<div class="sectionbg">
<div class="sectionbody">
<div class="subsection">
<div class="inputlabel">Username:</div>
<input type="text" name="username" value="<? VAR Username ?>" class="half" maxlength="128"
title="Please enter a username." />
</div>
<div class="subsection">
<div class="inputlabel">Password:</div>
<input type="password" name="password" class="half"
title="Please enter a password." autocomplete="off" />
</div>
</div>
</div>
<h3>Options</h3>
<div class="sectionbg">
<div class="sectionbody lotsofcheckboxes">
<span class="checkboxandlabel" title="Connect only if SASL authentication succeeds.">
<input type="checkbox" name="require_auth" id="opt_require_auth" value="1"<? IF RequireAuth ?> checked="checked"<? ENDIF ?> />
<label for="opt_require_auth">Require authentication</label>
</span>
<div style="clear:both;"></div>
</div>
</div>
</div>
<div class="section">
<h3>Mechanisms</h3>
<div class="sectionbg">
<div class="sectionbody">
<div class="subsection">
<table class="data">
<thead>
<tr>
<td>Name</td>
<td>Description</td>
</tr>
</thead>
<tbody>
<? LOOP MechanismLoop SORTASC=Name ?>
<tr class="<? IF __EVEN__ ?>evenrow<? ELSE ?>oddrow<? ENDIF ?>">
<td><? VAR Name ?></td>
<td><? VAR Description ?></td>
</tr>
<? ENDLOOP ?>
</tbody>
</table>
</div>
<div class="subsection">
<div class="inputlabel">Selected mechanisms and their order:</div>
<input type="text" name="mechanisms" id="mechanisms" value="<? VAR Mechanisms ?>" class="half"/>
<script>
$("#mechanisms").selectize({
plugins: ["drag_drop"],
delimiter: " ",
options: [<? LOOP MechanismLoop SORTASC=Name ?>{value:"<? VAR Name ?>",text:"<? VAR Name ?>"},<? ENDLOOP ?>],
});
</script>
</div>
</div>
</div>
</div>
<div style="clear:both;"></div>
<div class="submitline">
<input type="hidden" name="submitted" value="1" />
<input type="submit" value="Save" />
</div>
</form>
-->

@ -3,7 +3,7 @@
<div class="container col-md-10 col-md-offset-1">
<div class="panel panel-default">
<div class="panel-heading"><? FORMAT "Send a raw IRC line" ?></div>
<div class="panel-heading">Send RAW &middot; Send a raw IRC line</div>
<div class="panel-body">
<form class="form-horizontal" method="post" action="<? VAR URIPrefix TOP ?><? VAR ModPath ?>">
<? INC _csrf_check.tmpl ?>
@ -11,12 +11,12 @@
<div class="form-group">
<label for="inputUser" class="col-sm-2 control-label">User:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="user" disabled="disabled" title="<? FORMAT "To change user, click to Network selector" ?>"/>
<input type="text" class="form-control" id="user" disabled="disabled" title="To change user, click to Network selector"/>
</div>
</div>
<div class="form-group">
<label for="inputUserNetwork" class="col-sm-2 control-label"><? FORMAT "User/Network:" ?></label>
<label for="inputUserNetwork" class="col-sm-2 control-label">User/Network:</label>
<div class="col-sm-10">
<select class="form-control" name="network" id="selectnetwork" onchange="javascript:updateUser()">
<? LOOP UserLoop ?>
@ -31,17 +31,17 @@
</div>
<div class="form-group">
<label for="inputSendto" class="col-sm-2 control-label"><? FORMAT "Send to:" ?></label>
<label for="inputSendto" class="col-sm-2 control-label">Send to:</label>
<div class="col-sm-10">
<select class="form-control" name="send_to">
<option value="client"<? IF to_client ?> selected="yes"<? ENDIF ?>><? FORMAT "Client" ?></option>
<option value="server"<? IF to_server ?> selected="yes"<? ENDIF ?>><? FORMAT "Server" ?></option>
<option value="client"<? IF to_client ?> selected="yes"<? ENDIF ?>>Client</option>
<option value="server"<? IF to_server ?> selected="yes"<? ENDIF ?>>Server</option>
</select>
</div>
</div>
<div class="form-group">
<label for="inputLine" class="col-sm-2 control-label"><? FORMAT "Line:" ?></label>
<label for="inputLine" class="col-sm-2 control-label">Line:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputLine" name="line" value="<? VAR line ?>">
</div>
@ -50,7 +50,7 @@
<div class="panel-footer text-right">
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" value="<? FORMAT "Send" ?>" />
<input class="btn btn-success" type="submit" value="Send" />
</div>
</form>
</div>

@ -9,8 +9,8 @@
<table class="table table-bordered table-hover">
<thead>
<tr>
<td><? FORMAT "Name" ?></td>
<td><? FORMAT "Sticky" ?></td>
<td>Channel Name</td>
<td>Enable / Disable</td>
</tr>
</thead>
<tbody>
@ -31,7 +31,7 @@
<div class="panel-footer text-right">
<input class="btn btn-danger" type="reset" value="Reset">
<input type="hidden" name="submitted" value="1" />
<input class="btn btn-success" type="submit" value="<? FORMAT "Save" ?>" />
<input class="btn btn-success" type="submit" value="Save" />
</div>
</form>
</div>

@ -1,6 +1,6 @@
<hr>
<div class="form-group">
<label for="inputenableDisable" class="col-sm-2 control-label"><? FORMAT "Channel is sticky" ?></label>
<label for="inputenableDisable" class="col-sm-2 control-label">Channel is sticky:</label>
<div class="col-sm-10">
<div class="checkboxSwitch">
<input type="hidden" name="embed_stickychan_presented" value="1">

@ -11,91 +11,6 @@ function floodprotection_change() {
}
}
function make_sortable_table(table) {
if (table.rows.length >= 1) { // Ensure that the table at least contains a row for the headings
var headings = table.rows[0].getElementsByTagName("th");
for (var i = 0; i < headings.length; i++) {
// This function acts to scope the i variable, so we can pass it off
// as the column_index, otherwise column_index would just be the max
// value of i, every single time.
(function (i) {
var heading = headings[i];
if (!heading.classList.contains("ignore-sort")) {
heading.addEventListener("click", function () { // Bind a click event to the heading
sort_table(this, i, table, headings);
});
}
})(i);
}
}
}
function sort_table(clicked_column, column_index, table, headings) {
for (var i = 0; i < headings.length; i++) {
if (headings[i] != clicked_column) {
headings[i].classList.remove("sorted");
headings[i].classList.remove("reverse-sorted");
}
}
var reverse = false;
clicked_column.classList.toggle("reverse");
if (clicked_column.classList.contains("sorted")) {
reverse = true;
clicked_column.classList.remove("sorted");
clicked_column.classList.add("reverse-sorted");
} else {
clicked_column.classList.remove("reverse-sorted");
clicked_column.classList.add("sorted");
}
// This array will contain tuples in the form [(value, row)] where value
// is extracted from the column to be sorted by
var rows_and_sortable_value = [];
for (var i = 1, row; row = table.rows[i]; i++) {
for (var j = 0, col; col = row.cells[j]; j++) {
// If we're at the column index we want to sort by
if (j === column_index) {
var cell = row.getElementsByTagName("td")[j];
var value = cell.innerHTML;
rows_and_sortable_value.push([value, row]);
}
}
}
rows_and_sortable_value.sort(function (a, b) {
// If both values are integers, sort by that else as strings
if (isInt(a[0]) && isInt(b[0])) {
return a[0] - b[0];
} else {
return b[0].localeCompare(a[0]);
}
});
if (reverse) {
rows_and_sortable_value.reverse();
}
var parent = table.rows[1].parentNode;
for (var i = 0; i < rows_and_sortable_value.length; i++) {
// Remove the existing entry for the row from the table
parent.removeChild(rows_and_sortable_value[i][1]);
// Insert at the first position, before the first child
parent.insertBefore(rows_and_sortable_value[i][1], parent.firstChild);
}
}
function isInt(value) {
return !isNaN(value) && (function (x) {
return (x | 0) === x;
})(parseFloat(value))
}
function make_sortable() {
var tables = document.querySelectorAll("table.sortable");
for (var i = 0; i < tables.length; i++) {
make_sortable_table(tables[i]);
}
}
function serverlist_init($) {
function serialize() {
var text = "";
@ -104,7 +19,7 @@ function serverlist_init($) {
var port = $(".servers_row_port", $(this)).val();
var ssl = $(".servers_row_ssl", $(this)).is(":checked");
var pass = $(".servers_row_pass", $(this)).val();
if (host == undefined) return;
if (host.length == 0) return;
text += host;
text += " ";
if (ssl) text += "+";
@ -161,9 +76,12 @@ function serverlist_init($) {
$("#servers_plain").hide();
$("#servers_js").show();
};
})();
}
/* Broken. Work is in progress... Hang in there cowboy/girl...
function ctcpreplies_init($) {
function serialize() {
var text = "";
@ -186,13 +104,13 @@ function ctcpreplies_init($) {
}
row.append(
$("<td/>").append($("<input/>").val(request)
.addClass("form-control ctcpreplies_row_request")
.addClass("ctcpreplies_row_request")
.attr({"type":"text","list":"ctcpreplies_list"})),
$("<td/>").append($("<input/>").val(response)
.addClass("form-control ctcpreplies_row_response")
.addClass("ctcpreplies_row_response")
.attr({"type":"text","placeholder":"Empty value means this CTCP request will be ignored"})),
$("<td/>").append($("<input/>").val("X")
.addClass("btn btn-danger").val("X").css({width: '40px'}).click(delete_row))
$("<td/>").append($("<button/>").val("X")
.attr({"type":"button"}).addClass("btn btn-default").click(delete_row))
);
$("input", row).change(serialize);
$("#ctcpreplies_tbody").append(row);
@ -222,3 +140,4 @@ function ctcpreplies_init($) {
$("#ctcpreplies_js").show();
})();
}
*/

@ -1,138 +0,0 @@
function floodprotection_change() {
var protection = document.getElementById('floodprotection_checkbox');
var rate = document.getElementById('floodrate');
var burst = document.getElementById('floodburst');
if (protection.checked) {
rate.removeAttribute('disabled');
burst.removeAttribute('disabled');
} else {
rate.disabled = 'disabled';
burst.disabled = 'disabled';
}
}
function serverlist_init($) {
function serialize() {
var text = "";
$("#servers_tbody > tr").each(function() {
var host = $(".servers_row_host", $(this)).val();
var port = $(".servers_row_port", $(this)).val();
var ssl = $(".servers_row_ssl", $(this)).is(":checked");
var pass = $(".servers_row_pass", $(this)).val();
if (host == undefined) return;
text += host;
text += " ";
if (ssl) text += "+";
text += port;
text += " ";
text += pass;
text += "\n";
});
$("#servers_text").val(text);
}
function add_row(host, port, ssl, pass) {
var row = $("<tr/>");
function delete_row() {
row.remove();
serialize();
}
row.append(
$("<td/>").append($("<input/>").attr({"type":"text"})
.addClass("form-control servers_row_host").val(host)),
$("<td/>").append($("<input/>").attr({"type":"number"})
.addClass("form-control servers_row_port").val(port)),
$("<td/>").append($("<input/>").attr({"type":"checkbox"})
.addClass("servers_row_ssl").prop("checked", ssl)),
$("<td/>").append($("<input/>").attr({"type":"text"})
.addClass("form-control servers_row_pass").val(pass)),
$("<td/>").append($("<input/>").attr({"type":"button"})
.addClass("btn btn-danger").val("X").click(delete_row))
);
$("input", row).change(serialize);
$("#servers_tbody").append(row);
}
var servers_text = $("#servers_text").val();
// Parse it
$.each(servers_text.split("\n"), function(i, line) {
if (line.length == 0) return;
line = line.split(" ");
var host = line[0];
var port = line[1] || "6667";
var pass = line[2] || "";
var ssl;
if (port.match(/^\+/)) {
ssl = true;
port = port.substr(1);
} else {
ssl = false;
}
add_row(host, port, ssl, pass);
});
$("#servers_add").click(function() {
add_row("", 6697, true, "");
// Not serializing, because empty host doesn't emit anything anyway
});
$("#servers_plain").hide();
$("#servers_js").show();
};
function ctcpreplies_init($) {
function serialize() {
var text = "";
$("#ctcpreplies_tbody > tr").each(function() {
var request = $(".ctcpreplies_row_request", $(this)).val();
var response = $(".ctcpreplies_row_response", $(this)).val();
if (request.length == 0) return;
text += request;
text += " ";
text += response;
text += "\n";
});
$("#ctcpreplies_text").val(text);
}
function add_row(request, response) {
var row = $("<tr/>");
function delete_row() {
row.remove();
serialize();
}
row.append(
$("<td/>").append($("<input/>").attr({"type":"text"})
.addClass("form-control servers_row_host").val(host)),
$("<td/>").append($("<input/>").attr({"type":"number"})
.addClass("form-control servers_row_port").val(port)),
$("<td/>").append($("<input/>").attr({"type":"checkbox"})
.addClass("servers_row_ssl").prop("checked", ssl)),
$("<td/>").append($("<input/>").attr({"type":"button"})
.addClass("btn btn-danger").val("X").click(delete_row))
);
$("input", row).change(serialize);
$("#ctcpreplies_tbody").append(row);
}
(function() {
var replies_text = $("#ctcpreplies_text").val();
$.each(replies_text.split("\n"), function(i, line) {
if (line.length == 0) return;
var space = line.indexOf(" ");
var request;
var response;
if (space == -1) {
request = line;
response = "";
} else {
request = line.substr(0, space);
response = line.substr(space + 1);
}
add_row(request, response);
});
$("#ctcpreplies_add").click(function() {
add_row("", "");
});
$("#ctcpreplies_plain").hide();
$("#ctcpreplies_js").show();
})();
}

@ -1,4 +1,3 @@
<? I18N znc-webadmin ?>
<? INC Header.tmpl ?>
<form class="form-horizontal" role="form" action="<? IF Edit ?>editchan<? ELSE ?>addchan<? ENDIF ?>" method="post">
@ -15,8 +14,8 @@
<div class="panel with-nav-tabs panel-default">
<div class="panel-heading">
<ul class="nav nav-tabs">
<li class="active"><a href="#chaninfotab" data-toggle="tab"><? FORMAT "Channel Info" ?></a></li>
<li><a href="#flagstab" data-toggle="tab"><? FORMAT "Flags" ?></a></li>
<li class="active"><a href="#chaninfotab" data-toggle="tab">Channel Info</a></li>
<li><a href="#flagstab" data-toggle="tab">Flags</a></li>
<li><a href="#othermods" data-toggle="tab">More</a></li>
</ul>
</div>
@ -27,31 +26,31 @@
<div class="tab-pane fade in active" id="chaninfotab">
<? IF !Edit ?>
<div class="form-group">
<label for="inputlabelChanName" class="col-sm-2 control-label"><? FORMAT "Channel Name:" ?></label>
<label for="inputlabelChanName" class="col-sm-2 control-label">Channel Name:</label>
<div class="col-sm-10">
<input class="form-control" id="inputlabelChanName" type="text" name="name" value="" placeholder="<? FORMAT "The channel name." ?>">
<input class="form-control" id="inputlabelChanName" type="text" name="name" value="" placeholder="The channel name.">
</div>
</div>
<? ENDIF ?>
<div class="form-group">
<label for="inputlabelKey" class="col-sm-2 control-label"><? FORMAT "Key:" ?></label>
<label for="inputlabelKey" class="col-sm-2 control-label">Key:</label>
<div class="col-sm-10">
<input type="test" class="form-control" id="inputlabelKey" name="key" value="<? VAR Key ?>" placeholder="<? FORMAT "The password of the channel, if there is one." ?>">
<input type="test" class="form-control" id="inputlabelKey" name="key" value="<? VAR Key ?>" placeholder="The password of the channel, if there is one.">
</div>
</div>
<div class="form-group">
<label for="inputlabelBufferCount" class="col-sm-2 control-label"><? FORMAT "Buffer Size:" ?></label>
<label for="inputlabelBufferCount" class="col-sm-2 control-label">Buffer Count:</label>
<div class="col-sm-10">
<input class="form-control" id="inputlabelBufferCount" type="number" name="buffercount" value="<? VAR BufferCount ?>" size="10" min="0" placeholder="<? FORMAT "The buffer count." ?>">
<input class="form-control" id="inputlabelBufferCount" type="number" name="buffercount" value="<? VAR BufferCount ?>" size="10" min="0" placeholder="The buffer count.">
</div>
</div>
<div class="form-group">
<label for="inputDefaultModes" class="col-sm-2 control-label"><? FORMAT "Default Modes:" ?></label>
<label for="inputDefaultModes" class="col-sm-2 control-label">Default Modes:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputDefaultModes" name="defmodes" value="<? VAR DefModes ?>" size="10" placeholder="<? FORMAT "The default modes of the channel." ?>">
<input type="text" class="form-control" id="inputDefaultModes" name="defmodes" value="<? VAR DefModes ?>" size="10" placeholder="The default modes of the channel.">
</div>
</div>
</div> <!-- Channel Info -->
@ -69,7 +68,7 @@
<tbody>
<tr>
<td><div class="switch"><input type="checkbox" name="save" id="save" class="cmn-toggle cmn-toggle-round-flat" value="true"<? IF InConfig ?> checked="checked"<? ENDIF ?> /> <label for="save"></label> </div></td>
<td><? FORMAT "Save to config" ?></td>
<td>Save to config</td>
</tr>
<? LOOP OptionLoop ?>
<tr>
@ -86,7 +85,7 @@
<div class="tab-pane fade" id="othermods">
<? LOOP EmbeddedModuleLoop ?>
<? IF Embed ?>
<h3><? FORMAT "Module {1}" ModName ?></h3>
<h3>Module <? VAR ModName ?></h3>
<? INC *Embed ?>
<? ENDIF ?>
<? ENDLOOP ?>
@ -96,8 +95,8 @@
<div class="panel-footer text-right">
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success"type="submit" name="submit_return" value="<? IF Edit ?><? FORMAT "Save and return" ?><? ELSE ?><? FORMAT "Add Channel and return" ?><? ENDIF ?>" />
<input class="btn btn-default"type="submit" name="submit_continue" value="<? IF Edit ?><? FORMAT "Save and continue" ?><? ELSE ?><? FORMAT "Add Channel and continue" ?><? ENDIF ?>" />
<input class="btn btn-success"type="submit" name="submit_return" value="<? IF Edit ?>Save<? ELSE ?>Add Channel<? ENDIF ?>" />
<input class="btn btn-default"type="submit" name="submit_continue" value="<? IF Edit ?>Save and continue<? ELSE ?>Save and continue<? ENDIF ?>" />
</div>

@ -1,6 +1,4 @@
<? I18N znc-webadmin ?>
<? AddRow JSLoop HREF=/modfiles/global/webadmin/webadmin.js ?>
<? REM ?><? AddRow CSSLoop HREF=/modfiles/global/webadmin/webadmin.css ?><? ENDREM ?>
<? INC Header.tmpl ?>
<form class="form-horizontal" role="form" action="<? IF Edit ?>editnetwork<? ELSE ?>addnetwork<? ENDIF ?>" method="post">
@ -14,65 +12,58 @@
<div class="panel with-nav-tabs panel-default">
<div class="panel-heading">
<ul class="nav nav-tabs">
<li class="active"><a href="#netinfotab" data-toggle="tab"><? FORMAT "Network Info" ?></a></li>
<li><a href="#floodprotab" data-toggle="tab"><? FORMAT "Flood protection:" ?></a></li>
<li class="active"><a href="#netinfotab" data-toggle="tab">Network Info</a></li>
<li><a href="#floodprotab" data-toggle="tab">Flood Protection</a></li>
<li><a href="#charencodetab" data-toggle="tab">Character Encoding</a></li>
<li><a href="#channelstab" data-toggle="tab"><? FORMAT "Channels" ?></a></li>
<li><a href="#modulestab" data-toggle="tab"><? FORMAT "Modules" ?></a></li>
<li><a href="#channelstab" data-toggle="tab">Channels</a></li>
<li><a href="#modulestab" data-toggle="tab">Modules</a></li>
</ul>
</div>
<div class="panel-body">
<div class="tab-content">
<!-- Network Info -->
<div class="tab-pane fade in active" id="netinfotab">
<? IF Edit ?>
<? SETBLOCK ClientConnectHint_Password ?><? VAR Username ?>/<? VAR Name ?>:<? FORMAT "&lt;password&gt;" ?><? ENDSETBLOCK ?>
<? SETBLOCK ClientConnectHint_Username ?><? VAR Username ?>/<? VAR Name ?><? ENDSETBLOCK ?>
<? ELSE ?>
<? SETBLOCK ClientConnectHint_Password ?><? VAR Username ?>/<? FORMAT "&lt;network&gt;" ?>:<? FORMAT "&lt;password&gt;" ?><? ENDSETBLOCK ?>
<? SETBLOCK ClientConnectHint_Username ?><? VAR Username ?>/<? FORMAT "&lt;network&gt;" ?><? ENDSETBLOCK ?>
<? ENDIF ?>
<div class="alert alert-warning"><? FORMAT "To connect to this network from your IRC client, you can set the server password field as <code>{1}</code> or username field as <code>{2}</code>" "ClientConnectHint_Password ESC=" "ClientConnectHint_Username ESC=" ?></div>
<div class="alert alert-info"><? FORMAT "Nick, AltNick, Ident, RealName, BindHost can be left empty to use the value from the user." ?></div>
<div class="alert alert-warning">To connect to this network from your IRC client, you can set the server password field as follows: <code><? VAR Username ?>/<? IF Edit ?><? VAR Name ?><? ELSE ?>&lt;network&gt;<? ENDIF ?>:&lt;password&gt;</code> or username field as <code><? VAR Username ?>/<? IF Edit ?><? VAR Name ?><? ELSE ?>&lt;network&gt;<? ENDIF ?></code></div>
<div class="alert alert-info">Nick, AltNick, Ident, RealName, BindHost can be left empty to use the value from the user.</div>
<div class="form-group">
<label for="inputNetworkName" class="col-sm-2 control-label"><? FORMAT "Network Name:" ?></label>
<label for="inputNetworkName" class="col-sm-2 control-label">Network Name:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputNetworkName" name="name" value="<? VAR Name ?>" maxlength="20" placeholder="<? FORMAT "The name of the IRC network." ?>">
<input type="text" class="form-control" id="inputNetworkName" name="name" value="<? VAR Name ?>" maxlength="20" placeholder="The name of the IRC network">
</div>
</div>
<div class="form-group">
<label for="inputNickname" class="col-sm-2 control-label"><? FORMAT "Nickname:" ?></label>
<label for="inputNickname" class="col-sm-2 control-label">Nickname:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputNickname" name="nick" value="<? VAR Nick ?>" maxlength="30" placeholder="<? FORMAT "Your nickname on IRC." ?>">
<input type="text" class="form-control" id="inputNickname" name="nick" value="<? VAR Nick ?>" maxlength="30" placeholder="Your nickname on IRC.">
</div>
</div>
<div class="form-group">
<label for="inputAltNickname" class="col-sm-2 control-label"><? FORMAT "Alt. Nickname:" ?></label>
<label for="inputAltNickname" class="col-sm-2 control-label">Alt. Nickname:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="AltNickname" name="altnick" value="<? VAR AltNick ?>" maxlength="30" placeholder="<? FORMAT "Your secondary nickname, if the first is not available on IRC." ?>">
<input type="text" class="form-control" id="AltNickname" name="altnick" value="<? VAR AltNick ?>" maxlength="30" placeholder="Your secondary nickname, if the first is not available on IRC.">
</div>
</div>
<div class="form-group">
<label for="inputIdent" class="col-sm-2 control-label"><? FORMAT "Ident:" ?></label>
<label for="inputIdent" class="col-sm-2 control-label">Ident:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputIdent" name="ident" value="<? VAR Ident ?>" maxlength="30" placeholder="<? FORMAT "Your ident." ?>">
<input type="text" class="form-control" id="inputIdent" name="ident" value="<? VAR Ident ?>" maxlength="30" placeholder="Your ident.">
</div>
</div>
<div class="form-group">
<label for="inputRealname" class="col-sm-2 control-label"><? FORMAT "Realname:" ?></label>
<label for="inputRealname" class="col-sm-2 control-label">Realname:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputRealname" name="realname" value="<? VAR RealName ?>" maxlength="128" placeholder="<? FORMAT "Your real name." ?>">
<input type="text" class="form-control" id="inputRealname" name="realname" value="<? VAR RealName ?>" maxlength="128" placeholder="Your real name.">
</div>
</div>
<? IF BindHostEdit ?>
<div class="form-group">
<label for="inputBindHost" class="col-sm-2 control-label"><? FORMAT "BindHost:" ?></label>
<label for="inputBindHost" class="col-sm-2 control-label">BindHost:</label>
<div class="col-sm-10">
<? IF BindHostLoop ?>
<select class="form-control" name="bindhost">
@ -89,84 +80,62 @@
<? ENDIF ?>
<div class="form-group">
<label for="inputQuit" class="col-sm-2 control-label"><? FORMAT "Quit Message:" ?></label>
<label for="inputQuit" class="col-sm-2 control-label">Quit Message:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputQuit" name="quitmsg" value="<? VAR QuitMsg ?>" maxlength="256" placeholder="<? FORMAT "You may define a Message shown, when you quit IRC." ?>">
<input type="text" class="form-control" id="inputQuit" name="quitmsg" value="<? VAR QuitMsg ?>" maxlength="256" placeholder="You may define a Message shown, when you quit IRC.">
</div>
</div>
<div class="form-group">
<label for="inputActive" class="col-sm-2 control-label"><? FORMAT "Active:" ?></label>
<label for="inputActive" class="col-sm-2 control-label">Active:</label>
<div class="col-sm-10">
<div class="switch">
<input type="checkbox" value="1" name="doconnect" class="cmn-toggle cmn-toggle-round-flat" id="doconnect_checkbox"<? IF IRCConnectEnabled ?> checked="checked"<? ENDIF ?> />
<label for="doconnect_checkbox"></label>
<span class="help-block"><? FORMAT "Connect to IRC &amp; automatically re-connect" ?></span>
<span class="help-block">Connect to IRC &amp; automatically re-connect</span>
</div>
</div>
</div>
<div class="form-group">
<label for="inputTrustAll" class="col-sm-2 control-label"><? FORMAT "Trust all certs:" ?></label>
<div class="form-group" id="servers_plain">
<label for="inputServers" class="col-sm-2 control-label">Servers of this IRC network:</label>
<div class="col-sm-10">
<div class="switch">
<input type="checkbox" value="1" name="trustallcerts" class="cmn-toggle cmn-toggle-round-flat" id="trustallcerts_checkbox"<? IF TrustAllCerts ?> checked="checked"<? ENDIF ?> />
<label for="trustallcerts_checkbox"></label>
<span class="help-block"><? FORMAT "Disable certificate validation (takes precedence over TrustPKI). INSECURE!" ?></span>
</div>
<textarea class="form-control" name="servers" cols="70" rows="5" id="servers_text"><? LOOP ServerLoop ?><? VAR Server ?>
<? ENDLOOP ?></textarea>
<span class="help-block">One server per line, "host [[+]port] [password]", + means SSL</span>
<br/>
</div>
</div>
<div class="form-group">
<label for="inputTrustPKI" class="col-sm-2 control-label"><? FORMAT "Automatically detect trusted certificates (Trust the PKI):" ?></label>
<div class="form-group" id="servers_js" style="display:none">
<label for="inputServers" class="col-sm-2 control-label">Servers of this IRC network:</label>
<div class="col-sm-10">
<div class="switch">
<input type="checkbox" value="1" name="trustpki" class="cmn-toggle cmn-toggle-round-flat" id="trustpki_checkbox"<? IF TrustPKI ?> checked="checked"<? ENDIF ?> />
<label for="trustpki_checkbox"></label>
<span class="help-block"><? FORMAT "When disabled, manually whitelist all server fingerprints, even if the certificate is valid" ?></span>
</div>
<table class="table table-hover">
<thead>
<tr>
<th>Hostname</th>
<th>Port</th>
<th>SSL</th>
<th>Password</th>
<th/>
</tr>
</thead>
<tbody id="servers_tbody">
<tr>
</tr>
</tbody>
</table>
<button type="button" class="btn btn-default" value="Add" id="servers_add">Add New Server</button>
</div>
</div>
<div class="form-group" id="servers_plain">
<label for="inputServers" class="col-sm-2 control-label"><? FORMAT "Servers of this IRC network:" ?></label>
<div class="col-sm-10">
<textarea class="form-control" name="servers" cols="70" rows="5" id="servers_text"><? LOOP ServerLoop ?><? VAR Server ?>
<? ENDLOOP ?></textarea>
<span class="help-block"><? FORMAT "One server per line, “host [[+]port] [password]”, + means SSL" ?></span>
<br/>
</div>
</div>
<div class="form-group" id="servers_js" style="display:none">
<label for="inputServers" class="col-sm-2 control-label"><? FORMAT "Servers of this IRC network:" ?></label>
<div class="col-sm-10">
<table class="table table-hover">
<thead>
<tr>
<th><? FORMAT "Hostname" ?></th>
<th><? FORMAT "Port" ?></th>
<th><? FORMAT "SSL" ?></th>
<th><? FORMAT "Password" ?></th>
<th/>
</tr>
</thead>
<tbody id="servers_tbody">
<tr>
</tr>
</tbody>
</table>
<button type="button" class="btn btn-default" value="Add" id="servers_add">Add New Server</button>
</div>
</div>
<script type="text/javascript">serverlist_init(jQuery);</script>
</div>
<script type="text/javascript">serverlist_init(jQuery);</script>
<div class="form-group">
<label for="inputTrustedSSL" class="col-sm-2 control-label"><? FORMAT "SHA-256 fingerprints of trusted SSL certificates of this IRC network:" ?></label>
<label for="inputTrustedSSL" class="col-sm-2 control-label">Trusted SSL fingerprints of this IRC network:</label>
<div class="col-sm-10">
<textarea class="form-control" name="fingerprints" rows="3"><? LOOP TrustedFingerprints ?><? VAR FP ?>
<? ENDLOOP ?></textarea>
<span class="help-block"><? FORMAT "When these certificates are encountered, checks for hostname, expiration date, CA are skipped" ?></span>
<span class="help-block">When these certificates are encountered, checks for hostname, expiration date, CA are skipped</span>
</div>
</div>
</div> <!-- Network Info -->
@ -174,41 +143,38 @@
<!-- Flood Protection -->
<div class="tab-pane fade" id="floodprotab">
<div class="form-group">
<label for="floodprotection" class="col-sm-2 control-label"><? FORMAT "Flood protection:" ?></label>
<label for="inputFloodpro" class="col-sm-2 control-label">Flood protection:</label>
<div class="col-sm-10">
<div class="switch">
<input type="checkbox" name="floodprotection" id="floodprotection_checkbox" class="cmn-toggle cmn-toggle-round-flat" onchange="floodprotection_change();" <? IF FloodProtection ?>checked="checked"<? ENDIF ?> />
<label for="floodprotection_checkbox"></label>
<span class="help-block"><? FORMAT "You might enable the flood protection. This prevents “excess flood” errors, which occur, when your IRC bot is command flooded or spammed. After changing this, reconnect ZNC to server." ?></span>
<span class="help-block">You might enable the flood protection. This prevents `excess flood' errors, which occur, when your IRC bot is command flooded or spammed. After changing this, reconnect ZNC to server</span>
</div>
</div>
</div>
<div class="form-group">
<label for="floodprorate" class="col-sm-2 control-label"><? FORMAT "Flood protection rate:" ?></label>
<label for="inputFloodproRate" class="col-sm-2 control-label">Flood protection rate:</label>
<div class="col-sm-10">
<input class="form-control" type="number" name="floodrate" min="0.3" step="0.05" id="floodrate" placeholder="<? FORMAT "The number of seconds per line. After changing this, reconnect ZNC to server." ?>" <? IF FloodProtection ?> value="<? VAR FloodRate ?>" <? ELSE ?> value="1.00" disabled="disabled" <? ENDIF ?> />
<? FORMAT "{1} seconds per line" "FloodInputField_Rate ESC=" ?>
<span class="help-block"><? FORMAT "The number of seconds per line. After changing this, reconnect ZNC to server." ?></span>
<input class="form-control" type="number" name="floodrate" min="0.3" step="0.05" id="floodrate" placeholder="The number of seconds per line." <? IF FloodProtection ?> value="<? VAR FloodRate ?>" <? ELSE ?> value="1.00" disabled="disabled" <? ENDIF ?> />
<span class="help-block">The number of seconds per line. After changing this, reconnect ZNC to server</span>
</div>
</div>
<div class="form-group">
<label for="floodproburst" class="col-sm-2 control-label"><? FORMAT "Flood protection burst:" ?></label>
<label for="inputFloodproBurst" class="col-sm-2 control-label">Flood protection burst:</label>
<div class="col-sm-10">
<input type="number" class="form-control" name="floodburst" min="1" id="floodburst" <? IF FloodProtection ?> value="<? VAR FloodBurst ?>" <? ELSE ?> value="4" disabled="disabled" <? ENDIF ?> />
<? FORMAT "{1} lines can be sent immediately" "FloodInputField_Burst ESC=" ?>
<span class="help-block"><? FORMAT "Defines the number of lines, which can be sent immediately. After changing this, reconnect ZNC to server." ?></span>
<input type="number" class="form-control" name="floodburst" min="1" id="inputFloodproBurst floodburst" <? IF FloodProtection ?> value="<? VAR FloodBurst ?>" <? ELSE ?> value="4" disabled="disabled" <? ENDIF ?> />
<span class="help-block">Defines the number of lines, which can be sent immediately. After changing this, reconnect ZNC to server</span>
</div>
</div>
<div class="form-group">
<label for="joindelay" class="col-sm-2 control-label"><? FORMAT "Channel join delay:" ?></label>
<label for="inputChanjoindelay" class="col-sm-2 control-label">Channel join delay:</label>
<div class="col-sm-10">
<input type="number" class="form-control" name="joindelay" min="0" id="joindelay" value="<? VAR JoinDelay ?>" />
<? FORMAT "{1} seconds" "ChannelJoinDelayInputField ESC=" ?>
<span class="help-block"><? FORMAT "Defines the delay in seconds, until channels are joined after getting connected." ?></span>
<input type="number" class="form-control" name="joindelay" min="0" id="inputChanjoindelay joindelay" value="<? VAR JoinDelay ?>" />
<span class="help-block">Defines the delay in seconds, until channels are joined after getting connected</span>
</div>
</div>
@ -219,10 +185,9 @@
<!-- Server Encoding -->
<div class="tab-pane fade" id="charencodetab">
<div class="form-group">
<label for="inputChanencode" class="col-sm-2 control-label"><? FORMAT "Server encoding:" ?></label>
<label for="inputChanencode" class="col-sm-2 control-label">Server encoding:</label>
<div class="col-sm-10">
<? INC encoding_settings.tmpl ?>
<span class="help-block"><? FORMAT "Character encoding used between ZNC and IRC server." ?></span>
</div>
</div>
</div> <!-- Server Encoding -->
@ -230,21 +195,21 @@
<!-- Channels -->
<div class="tab-pane fade" id="channelstab">
<? IF !Edit ?>
<span class="info"><? FORMAT "You will be able to add + modify channels here after you created the network." ?></span><br />
<span class="info">You will be able to add + modify channels here after you created the network.</span><br />
<? ELSE ?>
<table class="table table-bordered table-hover table-striped">
<thead>
<tr>
<td><a href="<? VAR ModPath TOP ?>addchan?user=<? VAR Username ESC=URL ?>&amp;network=<? VAR Name ESC=URL ?>" class="btn btn-primary btn-xs"><? FORMAT "Add" ?></a></td>
<td><a href="addchan?user=<? VAR Username ESC=URL ?>&amp;network=<? VAR Name ESC=URL ?>" class="btn btn-primary btn-xs">Add</a></td>
<? IF ChannelLoop ?>
<th><? FORMAT "Save" ?></th>
<th><? FORMAT "Name" ?></th>
<th><? FORMAT "CurModes" ?></th>
<th><? FORMAT "DefModes" ?></th>
<th><? FORMAT "BufferSize" ?></th>
<th><? FORMAT "Options" ?></th>
<td>Save</td>
<td>Name</td>
<td>CurModes</td>
<td>DefModes</td>
<td>BufferCount</td>
<td>Options</td>
<? ELSE ?>
<td><? FORMAT "← Add a channel (opens in same page)" ?></td>
<td>&lt;- Add a channel (opens in same page)</td>
<? ENDIF ?>
</tr>
</thead>
@ -252,9 +217,7 @@
<? LOOP ChannelLoop SORTASC=Name ?>
<tr>
<td>
<input type="hidden" name="channel" value="<? VAR Name ?>" />
<a href="<? VAR ModPath TOP ?>editchan?user=<? VAR Username ESC=URL ?>&amp;network=<? VAR Network ESC=URL ?>&amp;name=<? VAR Name ESC=URL ?>" class="btn btn-warning btn-xs"><? FORMAT "Edit" ?></a>
<a href="<? VAR ModPath TOP ?>delchan?user=<? VAR Username ESC=URL ?>&amp;network=<? VAR Network ESC=URL ?>&amp;name=<? VAR Name ESC=URL ?>" class="btn btn-danger btn-xs"><? FORMAT "Del" ?></a>
<input type="hidden" name="channel" value="<? VAR Name ?>" /> <a href="editchan?user=<? VAR Username ESC=URL ?>&amp;network=<? VAR Network ESC=URL ?>&amp;name=<? VAR Name ESC=URL ?>" class="btn btn-warning btn-xs">Edit</a> <a href="delchan?user=<? VAR Username ESC=URL ?>&amp;network=<? VAR Network ESC=URL ?>&amp;name=<? VAR Name ESC=URL ?>" class="btn btn-danger btn-xs">Del</a>
</td>
<td class="text-center">
<div class="switch">
@ -280,12 +243,12 @@
<table class="table table-bordered table-hover table-striped">
<thead>
<tr>
<th><? FORMAT "Status" ?></th>
<th><? FORMAT "Name" ?></th>
<th><? FORMAT "Arguments" ?></th>
<th><? FORMAT "Description" ?></th>
<th><? FORMAT "Loaded globally" ?></th>
<th><? FORMAT "Loaded by user" ?></th>
<td>Status</td>
<td>Name</td>
<td>Arguments</td>
<td>Description</td>
<td>Global</td>
<td>Networks</td>
</tr>
</thead>
<tbody>
@ -336,7 +299,7 @@
<div class="tab-pane fade" id="othermods">
<? LOOP EmbeddedModuleLoop ?>
<? IF Embed ?>
<h3><? FORMAT "Module {1}" ModName ?></h3>
<h3>Module <? VAR ModName ?></h3>
<? INC *Embed ?>
<? ENDIF ?>
<? ENDLOOP ?>
@ -346,8 +309,8 @@
<div class="panel-footer text-right">
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" name="submit_return" value="<? IF Edit ?><? FORMAT "Save and return" ?><? ELSE ?><? FORMAT "Add Network and return" ?><? ENDIF ?>" />
<input class="btn btn-default" type="submit" name="submit_continue" value="<? IF Edit ?><? FORMAT "Save and continue" ?><? ELSE ?><? FORMAT "Add Network and continue" ?><? ENDIF ?>" />
<input class="btn btn-success" type="submit" name="submit_return" value="<? IF Edit ?>Save<? ELSE ?>Save Network<? ENDIF ?>" />
<input class="btn btn-default" type="submit" name="submit_continue" value="<? IF Edit ?>Save and continue<? ELSE ?>Save and continue<? ENDIF ?>" />
</div>
</div>

@ -1,35 +1,29 @@
<? I18N znc-webadmin ?>
<? AddRow JSLoop HREF=/modfiles/global/webadmin/webadmin.js ?>
<? AddRow CSSLoop HREF=/modfiles/global/webadmin/webadmin.css ?>
<? INC Header.tmpl ?>
<form class="form-horizontal" action="<? VAR ModPath TOP ?><? IF Edit ?>edituser?user=<? VAR Username ?><? ELSE ?>adduser<? ENDIF ?>" method="post">
<form class="form-horizontal" action="<? IF Edit ?>edituser<? ELSE ?>adduser<? ENDIF ?>" method="post">
<? INC _csrf_check.tmpl ?>
<input type="hidden" name="submitted" value="1" />
<input name="userdummy" type="text" style="display: none"/>
<input name="passworddummy" type="password" style="display: none"/>
<div class="container col-md-10 col-md-offset-1">
<div class="panel with-nav-tabs panel-default">
<div class="panel-heading">
<ul class="nav nav-tabs">
<li class="active"><a href="#authtab" data-toggle="tab"><? FORMAT "Authentication" ?></a></li>
<li><a href="#ircinformationtab" data-toggle="tab"><? FORMAT "IRC Information" ?></a></li>
<li class="hidden-xs"><a href="#networkstab" data-toggle="tab"><? FORMAT "Networks" ?></a></li>
<li class="hidden-xs"><a href="#modulestab" data-toggle="tab"><? FORMAT "Modules" ?></a></li>
<li class="hidden-xs hidden-sm"><a href="#channelstab" data-toggle="tab"><? FORMAT "Channels" ?></a></li>
<li class="hidden-xs hidden-sm"><a href="#queriestab" data-toggle="tab"><? FORMAT "Queries" ?></a></li>
<li class="hidden-xs hidden-sm"><a href="#flagstab" data-toggle="tab"><? FORMAT "Flags" ?></a></li>
<li class="hidden-xs hidden-sm"><a href="#zncbehavetab" data-toggle="tab"><? FORMAT "ZNC Behavior" ?></a></li>
<li class="active"><a href="#authtab" data-toggle="tab">Authentication</a></li>
<li><a href="#ircinformationtab" data-toggle="tab">IRC Information</a></li>
<li class="hidden-xs"><a href="#networkstab" data-toggle="tab">Networks</a></li>
<li class="hidden-xs"><a href="#modulestab" data-toggle="tab">Modules</a></li>
<li class="hidden-xs hidden-sm"><a href="#defaultsettingstab" data-toggle="tab">Default Settings</a></li>
<li class="hidden-xs hidden-sm"><a href="#flagstab" data-toggle="tab">Flags</a></li>
<li class="hidden-xs hidden-sm"><a href="#zncbehavetab" data-toggle="tab">ZNC Behavior</a></li>
<li class="hidden-xs hidden-sm"><a href="#othermodtab" data-toggle="tab">Other Modules</a></li>
<li class="dropdown hidden-lg hidden-md">
<a href="#" data-toggle="dropdown">More <span class="caret"></span></a>
<ul class="dropdown-menu" role="menu">
<li class="hidden-sm"><a href="#networkstab" data-toggle="tab"><? FORMAT "Networks" ?></a></li>
<li class="hidden-sm"><a href="#modulestab" data-toggle="tab"><? FORMAT "Modules" ?></a></li>
<li><a href="#channelsstab" data-toggle="tab"><? FORMAT "Channels" ?></a></li>
<li><a href="#queriesstab" data-toggle="tab"><? FORMAT "Queries" ?></a></li>
<li><a href="#flagstab" data-toggle="tab"><? FORMAT "Flags" ?></a></li>
<li><a href="#zncbehavetab" data-toggle="tab"><? FORMAT "ZNC Behavior" ?></a></li>
<li class="hidden-sm"><a href="#networkstab" data-toggle="tab">Networks</a></li>
<li class="hidden-sm"><a href="#modulestab" data-toggle="tab">Modules</a></li>
<li><a href="#defaultsettingstab" data-toggle="tab">Default Settings</a></li>
<li><a href="#flagstab" data-toggle="tab">Flags</a></li>
<li><a href="#zncbehavetab" data-toggle="tab">ZNC Behavior</a></li>
<li><a href="#othermodtab" data-toggle="tab">Other Modules</a></li>
</ul>
</li>
</ul>
@ -42,7 +36,7 @@
<div class="form-group">
<label for="inputUsername" class="col-sm-2 control-label"><? FORMAT "Username:" ?></label>
<label for="inputUsername" class="col-sm-2 control-label">Username:</label>
<div class="col-sm-10">
<? IF Clone ?>
<input type="hidden" class="form-control" id="inputUsername" name="clone" value="<? VAR CloneUsername ?>" autocomplete="off" />
@ -52,37 +46,31 @@
<input type="hidden" class="form-control" id="inputUsername" name="user" value="<? VAR Username ?>" autocomplete="off" />
<input type="text" class="form-control" id="inputUsername" name="newuser" value="<? VAR Username ?>" disabled="disabled" />
<? ELSE ?>
<input type="text" class="form-control" id="inputUsername" name="user" value="<? VAR Username ?>" placeholder="<? FORMAT "Please enter a username." ?>" autocomplete="off" />
<input type="text" class="form-control" id="inputUsername" name="user" value="<? VAR Username ?>" placeholder="Enter a username" autocomplete="off" />
<? ENDIF ?>
</div>
</div>
<div class="form-group">
<label for="inputPassword" class="col-sm-2 control-label"><? FORMAT "Password:" ?></label>
<label for="inputPassword" class="col-sm-2 control-label">Password:</label>
<div class="col-sm-10">
<input type="password" class="form-control" id="inputPassword" name="password" placeholder="<? FORMAT "Please enter a password." ?>" autocomplete="off">
<input type="password" class="form-control" id="inputPassword" name="password" placeholder="Enter a secure password" autocomplete="off">
</div>
</div>
<div class="form-group">
<label for="inputPassword2" class="col-sm-2 control-label"><? FORMAT "Confirm password:" ?></label>
<label for="inputPassword2" class="col-sm-2 control-label">Confirm Password:</label>
<div class="col-sm-10">
<input type="password" class="form-control" id="inputPassword2" name="password2" placeholder="<? FORMAT "Please re-type the above password." ?>">
<input type="password" class="form-control" id="inputPassword2" name="password2" placeholder="Re-type the password">
</div>
</div>
<div class="form-group">
<label for="authonlyviamodule" class="col-sm-2 control-label"><? FORMAT "Auth Only Via Module:" ?></label>
<div class="col-sm-10">
<input type="checkbox" class="cmn-toggle cmn-toggle-round-flat" id="authonlyviamodule" name="authonlyviamodule" placeholder="<? FORMAT "Allow user authentication by external modules only, disabling built-in password authentication." ?>"<? IF AuthOnlyViaModule ?> checked="checked"<? ENDIF ?><? IF !ImAdmin ?> disabled="disabled"<? ENDIF ?> /> </div>
</div>
<div class="form-group">
<label for="inputAllowedIP" class="col-sm-2 control-label"><? FORMAT "Allowed IPs:" ?></label>
<label for="inputAllowedIP" class="col-sm-2 control-label">Allowed IPs:</label>
<div class="col-sm-10">
<textarea class="form-control class="form-control" data-provide="markdown" id="inputAllowedIP" name="allowedips" cols="70" rows="5"><? LOOP AllowedHostLoop ?><? VAR Host ?>
<? ENDLOOP ?></textarea>
<div class="alert alert-info help-block"><? FORMAT "Leave empty to allow connections from all IPs.<br/>Otherwise, one entry per line, wildcards * and ? are available." ?></div>
<textarea class="form-control class="form-control" data-provide="markdown" id="inputAllowedIP" name="allowedips" cols="70" rows="5"><? LOOP AllowedHostLoop ?><? VAR Host ?><? ENDLOOP ?></textarea>
<div class="alert alert-info help-block">Leave empty to allow connections from all IPs. Otherwise, one entry per line, wildcards * and ? are available.</div>
</div>
</div>
</div><!-- Authentication -->
@ -90,47 +78,47 @@
<!-- IRC Information -->
<div class="tab-pane fade" id="ircinformationtab">
<? IF !Edit ?>
<div class="alert alert-info"><? FORMAT "Nick, AltNick, Ident, RealName and QuitMsg can be left empty to use default values." ?></div>
<div class="alert alert-info">Nick, AltNick, Ident, RealName and QuitMsg can be left empty to use default values.</div>
<? ENDIF ?>
<div class="form-group">
<label for="inputNickname" class="col-sm-2 control-label"><? FORMAT "Nickname:" ?></label>
<label for="inputNickname" class="col-sm-2 control-label">Nickname:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputNickname" name="nick" value="<? VAR Nick ?>" maxlength="30" placeholder="<? FORMAT "Your nickname on IRC." ?>">
<input type="text" class="form-control" id="inputNickname" name="nick" value="<? VAR Nick ?>" maxlength="30" placeholder="This will be your nickname on IRC.">
</div>
</div>
<div class="form-group">
<label for="inputaltNickname" class="col-sm-2 control-label"><? FORMAT "Alt. Nickname:" ?></label>
<label for="inputaltNickname" class="col-sm-2 control-label">Alt. Nickname</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputaltNickname" name="altnick" value="<? VAR AltNick ?>" maxlength="128" placeholder="<? FORMAT "Your secondary nickname, if the first is not available on IRC." ?>">
<input type="text" class="form-control" id="inputaltNickname" name="altnick" value="<? VAR AltNick ?>" maxlength="128" placeholder="If the nickname above is not available anymore, then this will be your nickname on IRC.">
</div>
</div>
<div class="form-group">
<label for="inputIdent" class="col-sm-2 control-label"><? FORMAT "Ident:" ?></label>
<label for="inputIdent" class="col-sm-2 control-label">Ident:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputIdent" name="ident" value="<? VAR Ident ?>" maxlength="128" placeholder="<? FORMAT "The Ident is sent to server as username." ?>">
<input type="text" class="form-control" id="inputIdent" name="ident" value="<? VAR Ident ?>" maxlength="128" placeholder="The Ident identifies you as one specific user of your host.">
</div>
</div>
<div class="form-group">
<label for="inputStatusPrefix" class="col-sm-2 control-label"><? FORMAT "Status Prefix:" ?></label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputStatusPrefix" name="statusprefix" value="<? VAR StatusPrefix ?>" maxlength="5" placeholder="<? FORMAT "The prefix for the status and module queries." ?>">
</div>
<label for="inputStatusPrefix" class="col-sm-2 control-label">StatusPrefix:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputStatusPrefix" name="statusprefix" value="<? VAR StatusPrefix ?>" maxlength="5" placeholder="This defines the prefix for the status and module queries.">
</div>
<div class="form-group">
<label for="inputRealname" class="col-sm-2 control-label"><? FORMAT "Realname:" ?></label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputRealname" name="realname" value="<? VAR RealName ?>" maxlength="256" placeholder="<? FORMAT "Your real name." ?>">
</div>
</div>
<div class="form-group">
<label for="inputRealname" class="col-sm-2 control-label">Realname:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputRealname" name="realname" value="<? VAR RealName ?>" maxlength="256" placeholder="The real name of the user.">
</div>
</div>
<? IF BindHostEdit ?>
<div class="form-group">
<label for="inputBindHost" class="col-sm-2 control-label"><? FORMAT "BindHost:" ?></label>
<label for="inputBindHost" class="col-sm-2 control-label">BindHost:</label>
<div class="col-sm-10">
<? IF BindHostLoop ?>
<select class="form-control" id="inputBindHost" name="bindhost">
@ -143,8 +131,9 @@
</div>
</div>
<? ENDIF ?>
<div class="form-group">
<label for="inputDCCBindHost" class="col-sm-2 control-label"><? FORMAT "DCCBindHost:" ?></label>
<label for="inputDCCBindHost" class="col-sm-2 control-label">DCCBindHost:</label>
<div class="col-sm-10">
<? IF DCCBindHostLoop ?>
<select class="form-control" id="inputDCCBindHost" name="dccbindhost">
@ -158,9 +147,9 @@
</div>
<div class="form-group">
<label for="inputQuit" class="col-sm-2 control-label"><? FORMAT "Quit Message:" ?></label>
<label for="inputQuit" class="col-sm-2 control-label">Quit Message:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputQuit" name="quitmsg" value="<? VAR QuitMsg ?>" maxlength="256" placeholder="<? FORMAT "You may define a Message shown, when you quit IRC." ?>">
<input type="text" class="form-control" id="inputQuit" name="quitmsg" value="<? VAR QuitMsg ?>" maxlength="256" placeholder="You may define a Message shown, when you quit IRC.">
</div>
</div>
</div> <!-- IRC Information -->
@ -171,14 +160,14 @@
<table class="table table-bordered table-hover table-striped">
<thead>
<tr>
<td><a href="<? VAR ModPath TOP ?>addnetwork?user=<? VAR Username ESC=URL ?>" class="btn btn-default btn-xs"><? FORMAT "Add" ?></a></td>
<td><a href="addnetwork?user=<? VAR Username ESC=URL ?>" class="btn btn-default btn-xs">Add</a></td>
<? IF NetworkLoop ?>
<td><? FORMAT "Name" ?></td>
<td><? FORMAT "Clients" ?></td>
<td><? FORMAT "Current Server" ?></td>
<td><? FORMAT "Nick" ?></td>
<td>Name</td>
<td>Clients</td>
<td>Current Server</td>
<td>IRC Nick</td>
<? ELSE ?>
<td><? FORMAT "← Add a network (opens in same page)" ?></td>
<td>&lt;- Add a network (opens in same page)</td>
<? ENDIF ?>
</tr>
</thead>
@ -187,7 +176,7 @@
<tr>
<td>
<input type="hidden" name="network" value="<? VAR Name ?>" />
<a href="<? VAR ModPath TOP ?>editnetwork?user=<? VAR Username ESC=URL ?>&amp;network=<? VAR Name ESC=URL ?>" class="btn btn-primary btn-xs">Edit</a> <a href="delnetwork?user=<? VAR Username ESC=URL ?>&amp;name=<? VAR Name ESC=URL ?>" class="btn btn-danger btn-xs"><? FORMAT "Del" ?></a>
<a href="editnetwork?user=<? VAR Username ESC=URL ?>&amp;network=<? VAR Name ESC=URL ?>" class="btn btn-primary btn-xs">Edit</a> <a href="delnetwork?user=<? VAR Username ESC=URL ?>&amp;name=<? VAR Name ESC=URL ?>" class="btn btn-danger btn-xs">Delete</a>
</td>
<td><? VAR Name ?></td>
<td><? VAR Clients ?></td>
@ -198,35 +187,21 @@
</tbody>
</table>
<? ELSE ?>
<? IF Clone ?>
<span class="info"><? FORMAT "You will be able to add + modify networks here after you have cloned the user." ?></span><br />
<? ELSE ?>
<span class="info"><? FORMAT "You will be able to add + modify networks here after you have created the user." ?></span><br />
<? ENDIF ?>
<span class="info">You will be able to add + modify networks here after you <? IF Clone ?>have cloned<? ELSE ?>created<? ENDIF ?> the user.</span><br />
<? ENDIF ?>
</div><!-- Networks -->
<!-- Modules -->
<div class="tab-pane fade" id="modulestab">
<? LOOP EmbeddedModuleLoop ?>
<? IF Embed ?>
<div class="form-group">
<label for="input<? VAR ModName ?>" class="col-sm-2 control-label"><? VAR ModName ?>:</label>
<div class="col-sm-10">
<? INC *Embed ?>
</div>
</div>
<? ENDIF ?>
<? ENDLOOP ?>
<table class="table table-bordered table-hover table-striped">
<thead>
<tr>
<td><? FORMAT "Status" ?></td>
<td><? FORMAT "Name" ?></td>
<td><? FORMAT "Arguments" ?></td>
<td><? FORMAT "Description" ?></td>
<td><? FORMAT "Loaded globally" ?></td>
<td><? FORMAT "Loaded by networks" ?></td>
<td>Status</td>
<td>Name</td>
<td>Arguments</td>
<td>Description</td>
<td>Global</td>
<td>Networks</td>
</tr>
</thead>
<tbody>
@ -235,9 +210,6 @@
<td>
<div class="switch">
<input type="checkbox" name="loadmod" id="lm_<? VAR Name ?>" value="<? VAR Name ?>" class="cmn-toggle cmn-toggle-round-flat" value="<? VAR Name ?>"<? IF Checked ?> checked="checked"<? ENDIF ?><? IF Disabled ?> disabled="disabled"<? ENDIF ?> />
<? IF Disabled ?>
<input type="hidden" name="loadmod" value="<? VAR Name ?>" value="<? VAR Name ?>"<? IF Checked ?> checked="checked"<? ENDIF ?> />
<? ENDIF ?>
<label for="lm_<? VAR Name ?>"></label>
</div>
</td>
@ -279,41 +251,23 @@
</div> <!-- Modules -->
<!-- Default Settings -->
<div class="tab-pane fade" id="channelstab">
<div class="tab-pane fade" id="defaultsettingstab">
<div class="form-group">
<label for="inputModes" class="col-sm-2 control-label"><? FORMAT "Default Modes:" ?></label>
<label for="inputModes" class="col-sm-2 control-label">Channel Modes:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputModes" name="chanmodes" value="<? VAR DefaultChanModes ?>" maxlength="32" placeholder="<? FORMAT "These are the default modes ZNC will set when you join an empty channel." ?>">
<div class="alert alert-info help-block"><? FORMAT "Empty = use standard value" ?></div>
<input type="text" class="form-control" id="inputModes" name="chanmodes" value="<? VAR DefaultChanModes ?>" maxlength="32" placeholder="These are the default modes ZNC will set when you join an empty channel.">
<div class="alert alert-info help-block">Empty = use standard value</div>
</div>
</div>
<div class="form-group">
<label for="chanbuffersize" class="col-sm-2 control-label"><? FORMAT "Buffer Size:" ?></label>
<label for="inputBufferSize" class="col-sm-2 control-label">Buffer Size:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="chanbufsize" name="chanbufsize" value="<? VAR ChanBufferSize ?>" min="0" placeholder="<? FORMAT "This is the amount of lines that the playback buffer will store for channels before dropping off the oldest line. The buffers are stored in the memory by default." ?>" />
<div class="alert alert-info help-block"><? FORMAT "Empty = use standard value" ?></div>
<input type="text" class="form-control" id="inputBufferSize" name="bufsize" value="<? VAR BufferCount ?>" min="0" placeholder="This is the amount of lines that the playback buffer will store before dropping off the oldest line. The buffers are stored in the memory by default." />
<div class="alert alert-info help-block">Empty = use standard value</div>
</div>
</div>
</div>
<div class="tab-pane fade" id="queriestab">
<div class="form-group">
<label for="maxquerybuffers" class="col-sm-2 control-label"><? FORMAT "Max Buffers:" ?></label>
<div class="col-sm-10">
<input type="text" class="form-control" id="maxquerybuffers" name="maxquerybuffers" value="<? VAR MaxQueryBuffers ?>" min="0" placeholder="<? FORMAT "Maximum number of query buffers. 0 is unlimited." ?>" />
<div class="alert alert-info help-block"><? FORMAT "Empty = use standard value" ?></div>
</div>
</div>
<div class="form-group">
<label for="querybufsize" class="col-sm-2 control-label"><? FORMAT "Buffer Size:" ?></label>
<div class="col-sm-10">
<input type="text" class="form-control" id="querybufsize" name="querybufsize" value="<? VAR QueryBufferSize ?>" min="0" placeholder="<? FORMAT "This is the amount of lines that the playback buffer will store for queries before dropping off the oldest line. The buffers are stored in the memory by default." ?>" />
<div class="alert alert-info help-block"><? FORMAT "Empty = use standard value" ?></div>
</div>
</div>
</div> <!-- Default Settings -->
</div> <!-- Default Settings -->
<!-- Flags -->
<div class="tab-pane fade" id="flagstab">
@ -322,8 +276,8 @@
<table class="table table-bordered table-hover table-striped">
<thead>
<tr>
<td></td>
<td><? FORMAT "Description" ?></td>
<td>Status</td>
<td>Flag Title</td>
</tr>
</thead>
<tbody>
@ -346,145 +300,153 @@
<!-- ZNC Behavior -->
<div class="tab-pane fade" id="zncbehavetab">
<div class="alert alert-info help-block"><? FORMAT "Any of the following text boxes can be left empty to use their default value." ?></div>
<div class="form-group">
<label for="inputtimeFormat" class="col-sm-2 control-label"><? FORMAT "Timestamp Format:" ?></label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputtimeFormat" name="timestampformat" value="<? VAR TimestampFormat ?>" placeholder="The format for the timestamps used in buffers, for example [%H:%M:%S]." />
<div class="alert alert-info help-block"><? FORMAT "The format for the timestamps used in buffers, for example [%H:%M:%S]. This setting is ignored in new IRC clients, which use server-time. If your client supports server-time, change timestamp format in client settings instead." ?></div>
</div>
<div class="alert alert-info help-block">Any of the following text boxes can be left empty to use their default value.</div>
<div class="form-group">
<label for="inputtimeFormat" class="col-sm-2 control-label">Timestamp Format:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputtimeFormat" name="timestampformat" value="<? VAR TimestampFormat ?>" placeholder="The format for the timestamps used in buffers, for example [%H:%M:%S]." />
<div class="alert alert-info help-block">This setting is ignored in new IRC clients, which use server-time. If your client supports server-time, change timestamp format in client settings instead.</div>
</div>
<div class="form-group">
<label for="inputTimezone" class="col-sm-2 control-label"><? FORMAT "Timezone:" ?></label>
<div class="col-sm-10">
<input class="form-control" id="inputTimezone" name="timezone" value="<? VAR Timezone ?>" placeholder="<? FORMAT "Select your timezone." ?>">
<div class="alert alert-info help-block"><? FORMAT "E.g. <code>Europe/Berlin</code>, or <code>GMT-6</code>" ?></div>
</div>
</div>
<div class="form-group">
<label for="inputTimezone" class="col-sm-2 control-label">Timezone:</label>
<div class="col-sm-10">
<input class="form-control" id="inputTimezone" name="timezone" value="<? VAR Timezone ?>" placeholder="Select your timezone.">
<div class="alert alert-info help-block">E.g. <b>Europe/Berlin</b> or <b>GMT-6</b></div>
</div>
<div class="form-group">
<label for="inputClientencode" class="col-sm-2 control-label"><? FORMAT "Client encoding:" ?></label>
<div class="col-sm-10">
<? INC encoding_settings.tmpl ?>
<span class="help-block"><? FORMAT "Character encoding used between IRC client and ZNC." ?></span>
</div>
</div>
<div class="form-group">
<label for="inputClientencode" class="col-sm-2 control-label">Client encoding:</label>
<div class="col-sm-10">
<? INC encoding_settings.tmpl ?>
<span class="help-block">Character encoding used between IRC client and ZNC. After changing this, reconnect client to ZNC</span>
</div>
<div class="form-group">
<label for="inputJoinTries" class="col-sm-2 control-label"><? FORMAT "Join Tries:" ?></label>
<div class="col-sm-10">
<input class="form-control" type="number" id="inputJoinTries" name="jointries" value="<? VAR JoinTries ?>" min="0" placeholder="<? FORMAT "This defines how many times ZNC tries to join a channel, if the first join failed, e.g. due to channel mode +i/+k or if you are banned." ?>" />
</div>
</div>
<div class="form-group">
<label for="inputJoinTries" class="col-sm-2 control-label">Join Tries:</label>
<div class="col-sm-10">
<input class="form-control" type="number" id="inputJoinTries" name="jointries" value="<? VAR JoinTries ?>" min="0" placeholder="This defines how often ZNC tries to join, if the first join failed, e.g. due to channel mode +i/+k or if you're banned."/>
</div>
<div class="form-group">
<label for="inputMaxJoins" class="col-sm-2 control-label"><? FORMAT "Join speed:" ?></label>
<div class="col-sm-10">
<input class="form-control" type="number" id="inputMaxJoins" name="maxjoins" value="<? VAR MaxJoins ?>" min="0" placeholder="<? FORMAT "How many channels are joined in one JOIN command. 0 is unlimited (default). Set to small positive value if you get disconnected with “Max SendQ Exceeded”" ?>" />
</div>
</div>
<div class="form-group">
<label for="inputMaxJoins" class="col-sm-2 control-label">Max Joins:</label>
<div class="col-sm-10">
<input class="form-control" type="number" id="inputMaxJoins" name="maxjoins" value="<? VAR MaxJoins ?>" min="0" placeholder="How many channels are joined in one JOIN command. 0 is unlimited (default). Set to small positive value if you get disconnected with `Max SendQ Exceeded'"/>
</div>
<div class="form-group">
<label for="inputmaxIRCnet" class="col-sm-2 control-label"><? FORMAT "Max IRC Networks Number:" ?></label>
<div class="col-sm-10">
<input class="form-control" type="number" id="inputmaxIRCnet" name="maxnetworks" value="<? VAR MaxNetworks ?>" min="0" placeholder="<? FORMAT "Maximum number of IRC networks allowed for this user." ?>" <? IF !ImAdmin ?>disabled="disabled"<? ENDIF ?> />
</div>
</div>
<div class="form-group">
<label for="inputmaxIRCnet" class="col-sm-2 control-label">Max IRC Networks Number:</label>
<div class="col-sm-10">
<input class="form-control" type="number" id="inputmaxIRCnet" name="maxnetworks" value="<? VAR MaxNetworks ?>" min="0" placeholder="Maximum number of IRC networks allowed for this user." <? IF !ImAdmin ?>disabled="disabled"<? ENDIF ?> />
</div>
<div class="form-group">
<label for="notraffictimeout" class="col-sm-2 control-label"><? FORMAT "Timeout before reconnect:" ?></label>
<div class="col-sm-10">
<input class="form-control" type="number" id="notraffictimeout" name="notraffictimeout" value="<? VAR NoTrafficTimeout ?>" class="third" min="30" placeholder="<? FORMAT "How much time ZNC waits (in seconds) until it receives something from network or declares the connection timeout. This happens after attempts to ping the peer." ?>"/>
</div>
</div>
<div class="form-group">
<label for="inputmaxQueryBuffers" class="col-sm-2 control-label">Max Query Buffers:</label>
<div class="col-sm-10">
<input class="form-control" type="number" id="inputmaxQueryBuffers" name="maxquerybuffers" value="<? VAR MaxQueryBuffers ?>" class="third" min="0" placeholder="Maximum number of query buffers. 0 is unlimited."/>
</div>
</div>
<? SETBLOCK Substitutions_Link ?><a href="https://wiki.znc.in/ExpandString" target="_blank" class="external"><? FORMAT "Substitutions" ?></a><? ENDSETBLOCK ?>
<!-- Broken. Work is in progress... Hang in there cowboy/girl...
<div class="form-group" id="ctcpreplies_plain">
<label for="inputCTCPreplies" class="col-sm-2 control-label">CTCP Replies:</label>
<div class="col-sm-10">
<textarea class="form-control" name="ctcpreplies" cols="70" rows="3" id="ctcpreplies_text"><? LOOP CTCPLoop ?><? VAR CTCP ?>
<textarea class="form-control" id="inputCTCPreplies" name="ctcpreplies" cols="70" rows="3" id="ctcpreplies_text"><? LOOP CTCPLoop ?><? VAR CTCP ?>
<? ENDLOOP ?></textarea>
<div class="alert alert-info help-block"><? FORMAT "One reply per line. Example: <code>TIME Buy a watch!</code>" ?></div>
<div class="alert alert-info help-block"><? FORMAT "{1} are available" "Substitutions_Link ESC=" ?></div>
<div class="alert alert-info help-block">One reply per line. Example: TIME Buy a watch!</div>
</div>
</div>
<div class="form-group" id="ctcpreplies_js" style="display:none" data-placeholder="<? FORMAT "Empty value means this CTCP request will be ignored" ?>">
<label for="ctcpreplies" class="col-sm-2 control-label"><? FORMAT "CTCP Replies:" ?></label>
<div class="form-group" id="ctcpreplies_js">
<label for="inputCTCPreplies" class="col-sm-2 control-label">CTCP Replies:</label>
<div class="col-sm-10">
<table class="table table-hover">
<thead>
<tr>
<th><? FORMAT "Request" ?></th>
<th><? FORMAT "Response" ?></th>
<th>Request</th>
<th>Response</th>
</tr>
</thead>
<tbody id="ctcpreplies_tbody" />
<tbody id="ctcpreplies_tbody">
</tbody>
</table>
<button type="button" class="btn btn-default" value="<? FORMAT "Add" ?>" id="ctcpreplies_add"><? FORMAT "Add" ?></button>
<span class="info"><? FORMAT "{1} are available" "Substitutions_Link ESC=" ?></span>
<datalist id="ctcpreplies_list">
<option value="PING"/>
<option value="FINGER"/>
<option value="CLIENTINFO"/>
<option value="USERINFO"/>
<option value="VERSION"/>
<option value="SOURCE"/>
<option value="TIME"/>
<option value="PAGE"/>
<option value="DCC"/>
<option value="UPTIME"/>
</datalist>
<select class="form-control" id="ctcpreplies_list">
<option value="PING">PING</option>
<option value="FINGER">FINGER</option>
<option value="CLIENTINFO">CLIENTINFO</option>
<option value="USERINFO">USERINFO</option>
<option value="VERSION">VERSION</option>
<option value="SOURCE">SOURCE</option>
<option value="TIME">TIME</option>
<option value="PAGE">PAGE</option>
<option value="DCC">DCC</option>
<option value="UPTIME">UPTIME</option>
</select>
<button type="button" class="btn btn-default" value="Add" id="ctcpreplies_add">Add</button>
</div>
</div>
</div>
<script type="text/javascript">ctcpreplies_init(jQuery);</script>
-->
<div class="form-group">
<label for="inputSkins" class="col-sm-2 control-label"><? FORMAT "Skin:" ?></label>
<div class="col-sm-10">
<? IF SkinLoop ROWS > 1 ?>
<select class="form-control" name="skin">
<option value=""><? FORMAT "- Global -" ?></option>
<? LOOP SkinLoop ?>
<option value="<? VAR Name ?>"<? IF Checked ?> selected="selected"<? ENDIF ?>><? IF Name == "_default_" ?><? FORMAT "Default" ?><? ELSE ?><? VAR Name ?><? ENDIF ?></option>
<? ENDLOOP ?>
</select>
<? ELSE ?>
<p><? FORMAT "No other skins found" ?></p>
<? ENDIF ?>
</div>
<label for="inputCTCPreplies" class="col-sm-2 control-label">CTCP Replies:</label>
<div class="col-sm-10">
<textarea class="form-control" id="inputCTCPreplies" name="ctcpreplies" cols="70" rows="3"><? LOOP CTCPLoop ?><? VAR CTCP ?>
<? ENDLOOP ?></textarea>
<div class="alert alert-info help-block">One reply per line. Example: TIME Buy a watch! &mdash; Some variable-like strings can be found <a href="http://wiki.znc.in/ExpandString" target="_blank">here</a></div>
</div>
<div class="form-group">
<label for="language" class="col-sm-2 control-label"><? FORMAT "Language:" ?></label>
<div class="col-sm-10">
<? IF HaveI18N ?>
<select class="form-control" name="language">
<? LOOP LanguageLoop ?>
<option value="<? VAR Code ?>" <? IF Language TOP == *Code ?>selected="selected"<? ENDIF ?>><? VAR Name ?></option>
<? ENDLOOP ?>
</select>
<? ELSE ?>
<p>ZNC is compiled without i18n support!</p>
<? ENDIF ?>
</div>
</div>
</div><!-- ZNC Behavior -->
</div>
<div class="form-group">
<label for="inputSkins" class="col-sm-2 control-label">Skin(s):</label>
<div class="col-sm-10">
<? IF SkinLoop ROWS > 1 ?>
<select class="form-control" name="skin">
<option value="">- Global -</option>
<? LOOP SkinLoop ?>
<option value="<? VAR Name ?>"<? IF Checked ?> selected="selected"<? ENDIF ?>><? IF Name == "_default_" ?>Default<? ELSE ?><? VAR Name ?><? ENDIF ?></option>
<? ENDLOOP ?>
</select>
<? ELSE ?>
<p>No other skins found!</p>
<? ENDIF ?>
</div>
</div>
</div><!-- ZNC Behavior -->
<!-- Other Modules -->
<div class="tab-pane fade" id="othermodtab">
<? LOOP EmbeddedModuleLoop ?>
<? IF Embed ?>
<div class="form-group">
<label for="input<? VAR ModName ?>" class="col-sm-2 control-label"><? VAR ModName ?>:</label>
<div class="col-sm-10">
<? INC *Embed ?>
</div>
</div>
<? ENDIF ?>
<? ENDLOOP ?>
</div><!-- Other Modules -->
</div>
</div>
<div class="panel-footer text-right">
<? IF ImAdmin ?>
<? IF ImAdmin ?>
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" name="submit_return" value="<? IF Edit ?><? FORMAT "Save and return" ?><? ELSE ?><? IF Clone ?><? FORMAT "Clone and return" ?><? ELSE ?><? FORMAT "Create and return" ?><? ENDIF ?><? ENDIF ?>" />
<input class="btn btn-default" type="submit" name="submit_continue" value="<? IF Edit ?><? FORMAT "Save and continue" ?><? ELSE ?><? IF Clone ?><? FORMAT "Clone and continue" ?><? ELSE ?><? FORMAT "Create and continue" ?><? ENDIF ?><? ENDIF ?>" />
<input class="btn btn-success" type="submit" name="submit_return" value="<? IF Edit ?>Save<? ELSE ?><? IF Clone ?>Clone<? ELSE ?>Create<? ENDIF ?><? ENDIF ?>" />
<input class="btn btn-default" type="submit" name="submit_continue" value="<? IF Edit ?>Save and continue<? ELSE ?><? IF Clone ?>Clone<? ELSE ?>Create<? ENDIF ?><? ENDIF ?>" />
<? ELSE ?>
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" value="<? IF Edit ?><? FORMAT "Save" ?><? ELSE ?><? IF Clone ?><? FORMAT "Clone" ?><? ELSE ?><? FORMAT "Create" ?><? ENDIF ?><? ENDIF ?>" />
<input class="btn btn-success" type="submit" value="<? IF Edit ?>Save<? ELSE ?><? IF Clone ?>Clone<? ELSE ?>Create<? ENDIF ?><? ENDIF ?>" />
<? ENDIF ?>
</div>
</div>

@ -1,23 +1,22 @@
<? I18N znc-webadmin ?>
<? INC Header.tmpl ?>
<div class="container">
<div class="row">
<div class="col-md-6 col-md-offset-3">
<div class="panel panel-danger">
<div class="panel-heading"><? FORMAT "Confirm Network Deletion" ?></div>
<div class="panel-heading">Confirm Network Deletion</div>
<div class="panel-body">
<p><? FORMAT "Are you sure you want to delete network “{2}” of user “{1}”?" Username Network ?></p>
<p>Are you absolutely sure you want to delete <b>"<? VAR Network ?>"</b> network, <? VAR Username ?>?</p>
<br>
<center>
<form action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>delnetwork?user=<? VAR Username ?>&network=<? VAR Network ?>" method="post">
<form action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>delnetwork" method="post">
<? INC _csrf_check.tmpl ?>
<input type="hidden" name="user" value="<? VAR Username ?>" />
<input type="hidden" name="name" value="<? VAR Network ?>" />
<input type="submit" class="btn btn-danger btn-xs" value="<? FORMAT "Yes" ?>" />
<input type="submit" class="btn btn-danger btn-xs" value="Yes, I want <? VAR Network ?> deleted" />
</form><br>
<form action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>listusers" method="get">
<input type="submit" class="btn btn-success btn-xs" value="<? FORMAT "No" ?>" />
<input type="submit" class="btn btn-success btn-xs" value="No, I want to keep <? VAR Network ?>" />
</form>
</center>
</div>

@ -1,23 +1,22 @@
<? I18N znc-webadmin ?>
<? INC Header.tmpl ?>
<div class="container">
<div class="row">
<div class="col-md-6 col-md-offset-3">
<div class="panel panel-danger">
<div class="panel-heading"><? FORMAT "Confirm User Deletion" ?></div>
<div class="panel-heading">Confirm User Deletion</div>
<div class="panel-body">
<p><? FORMAT "Are you sure you want to delete user “{1}”?" Username ?></p>
<p>Are you absolutely sure you want to delete "<? VAR Username ?>"?</p>
<br>
<center>
<form action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>deluser?user=<? VAR Username ?>" method="post">
<form action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>deluser" method="post">
<? INC _csrf_check.tmpl ?>
<input type="hidden" name="submitted" value="1" />
<input type="hidden" name="user" value="<? VAR Username ?>" />
<input type="submit" class="btn btn-danger btn-xs" value="<? FORMAT "Yes" ?>" />
<input type="submit" class="btn btn-danger btn-xs" value="Yes, delete <? VAR Username ?>" />
</form><br>
<form action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>listusers" method="get">
<input type="submit" class="btn btn-success btn-xs" value="<? FORMAT "No" ?>" />
<input type="submit" class="btn btn-success btn-xs" value="No, do not delete <? VAR Username ?>" />
</form>
</center>

@ -1,35 +1,33 @@
<? I18N znc-webadmin ?>
<? SETBLOCK Encoding_Placeholder ?><span class="encoding-placeholder-big text-success">&nbsp;&nbsp;<span class="encoding-placeholder"></span>&nbsp;&nbsp;</span><? ENDSETBLOCK ?>
<div class="radio">
<label>
<input type="radio" name="encoding_utf" id="encoding_utf_legacy" value="legacy" <? IF EncodingUtf == "legacy" ?>checked="checked"<? ENDIF ?> <? IF EncodingDisabled ?>disabled="disabled"<? ENDIF ?> />
<span class="help-block" for="encoding_utf_legacy"><? FORMAT "Don't ensure any encoding at all (legacy mode, not recommended)" ?></span>
<span class="help-block" for="encoding_utf_legacy">Don't ensure any encoding at all (legacy mode, not recommended)</span>
</label>
</div>
<div class="radio">
<label>
<input type="radio" name="encoding_utf" id="encoding_utf_send" value="send" <? IF EncodingUtf == "send" ?>checked="checked"<? ENDIF ?> <? IF EncodingDisabled ?>disabled="disabled"<? ENDIF ?> />
<span class="help-block" for="encoding_utf_send"><? FORMAT "Try to parse as UTF-8 and as {1}, send as UTF-8 (recommended)" "Encoding_Placeholder ESC=" ?></span>
<span class="help-block" for="encoding_utf_send">Try to parse as UTF-8 and as <span class="encoding-placeholder-big text-success">&nbsp;&nbsp;<span class="encoding-placeholder"></span>&nbsp;&nbsp;</span>, send as UTF-8</span>
</label>
</div>
<div class="radio">
<label>
<input type="radio" name="encoding_utf" id="encoding_utf_receive" value="receive" <? IF EncodingUtf == "receive" ?>checked="checked"<? ENDIF ?> <? IF EncodingDisabled ?>disabled="disabled"<? ENDIF ?> />
<span class="help-block" for="encoding_utf_receive"><? FORMAT "Try to parse as UTF-8 and as {1}, send as {1}" "Encoding_Placeholder ESC=" ?></span>
<span class="help-block" for="encoding_utf_receive">Try to parse as UTF-8 and as <span class="encoding-placeholder-big text-success">&nbsp;&nbsp;<span class="encoding-placeholder"></span>&nbsp;&nbsp;</span>, send as <span class="encoding-placeholder-big text-success">&nbsp;&nbsp;<span class="encoding-placeholder"></span >&nbsp;&nbsp;</span>
</label>
</div>
<div class="radio">
<label>
<input type="radio" name="encoding_utf" id="encoding_utf_simple" value="simple" <? IF EncodingUtf == "simple" ?>checked="checked"<? ENDIF ?> <? IF EncodingDisabled ?>disabled="disabled"<? ENDIF ?> />
<span class="help-block" for="encoding_utf_simple"><? FORMAT "Parse and send as {1} only" "Encoding_Placeholder ESC=" ?></span>
<span class="help-block" for="encoding_utf_simple">Parse and send as <span class="encoding-placeholder-big text-success">&nbsp;&nbsp;<span class="encoding-placeholder"></span>&nbsp;&nbsp;</span> only</span>
</label>
</div>
<div class="test-text">
<input class="form-control" type="text" name="encoding" placeholder="<? FORMAT "E.g. <code>UTF-8</code>, or <code>ISO-8859-15</code>" ?>" value="<? VAR Encoding ?>" list="encoding_list" <? IF EncodingDisabled ?>disabled="disabled"<? ENDIF ?> />
<input class="form-control" type="text" name="encoding" placeholder="Enter a text here (e.g. UTF-8 or ISO-8859-15)" value="<? VAR Encoding ?>" list="encoding_list" <? IF EncodingDisabled ?>disabled="disabled"<? ENDIF ?> />
</div>
<datalist id="encoding_list">
@ -55,4 +53,4 @@
jQuery("input:radio[name=encoding_utf]").change(updateEncodingLegacy);
updateEncodingLegacy();
</script>
</script>

@ -1,11 +1,10 @@
<? I18N znc-webadmin ?>
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
<div class="panel panel-default">
<div class="panel-heading">Webadmin</div>
<div class="panel-body">
<p><? FORMAT "Welcome to the ZNC webadmin module." ?><br><? FORMAT "All changes you make will be in effect immediately after you submitted them." ?></p>
<p>Welcome to the ZNC webadmin module.<br>All changes you make will be in effect immediately after you submitted them.</p>
</div>
</div>
</div>

@ -1,70 +1,60 @@
<? I18N znc-webadmin ?>
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
<div class="panel panel-default">
<div class="panel-heading">List of Users</div>
<div class="panel-body">
<?IF !UserLoop?>
<div class="alert alert-warning">
<? FORMAT "There are no users defined. Click <a href="{1}adduser">here</a> if you would like to add one." "ModPath TOP" ?>
<div class="panel-body">
<?IF !UserLoop?>
<div class="alert alert-warning">
There are no users defined. Click <a href="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>adduser">here</a> if you would like to add one.
</div>
<?ELSE?>
<div class="row">
<div class="col-md-4 col-md-offset-8">
<div class="input-group custom-search-form" style=".custom-search-form{margin-top:5px;}">
<input class="form-control" id="system-search" name="q" placeholder="Search..." required>
<span class="input-group-btn">
<button type="submit" class="btn btn-default">
<span class="fa fa-search"></span>
</button>
</span>
</div>
<?ELSE?>
<div class="table">
<input type="text" class="form-control input-lg" id="inputSearch" onkeyup="UserSearch()" placeholder="Search..." title="Type in a user">
<br>
<table class="table table-bordered table-hover" id="users">
<thead>
<tr class="header">
<th><a href="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>adduser" class="btn btn-default btn-xs"><? FORMAT "Add" ?></a></th>
<th><? FORMAT "Username" ?></th>
<th><? FORMAT "Networks" ?></th>
<th><? FORMAT "Clients" ?></th>
</tr>
</thead>
<tbody>
<?LOOP UserLoop SORTASC=Username ?>
<tr class="<?IF __EVEN__?>evenrow<?ELSE?>oddrow<?ENDIF?>">
<td>
<span class="nowrap">
<a href="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>edituser?user=<?VAR Username ESC=URL?>" class="btn btn-primary btn-xs"><? FORMAT "Edit" ?></a>
<a href="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>adduser?clone=<? VAR Username ESC=URL ?>" alt="Clone <? VAR Username ESC=URL ?>" class="btn btn-warning btn-xs"><? FORMAT "Clone" ?></a>
<? IF !IsSelf ?><a href="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>deluser?user=<?VAR Username ESC=URL?>" class="btn btn-danger btn-xs"><? FORMAT "Delete" ?></a><? ENDIF ?>
</span>
</td>
<td><? VAR Username ?></td>
<td><? VAR Networks ?></td>
<td><? VAR Clients ?></td>
</tr>
<?ENDLOOP?>
</tbody>
</table>
<?ENDIF?>
</div>
</div>
</div>
</div>
</div>
<br>
<table class="table table-bordered table-hover table-striped table-list-search">
<thead>
<tr>
<td><a href="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>adduser" class="btn btn-default btn-xs">Add</a></td>
<td>Username</td>
<td>Networks</td>
<td>Clients</td>
</tr>
</thead>
<tbody>
<?LOOP UserLoop SORTASC=Username ?>
<tr class="<?IF __EVEN__?>evenrow<?ELSE?>oddrow<?ENDIF?>">
<td>
<span class="nowrap">
<a href="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>edituser?user=<?VAR Username ESC=URL?>" class="btn btn-primary btn-xs">Edit</a>
<a href="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>adduser?clone=<? VAR Username ESC=URL ?>" alt="Clone <? VAR Username ESC=URL ?>" class="btn btn-warning btn-xs">Clone</a>
<? IF !IsSelf ?><a href="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>deluser?user=<?VAR Username ESC=URL?>" class="btn btn-danger btn-xs">Delete</a><? ENDIF ?>
</span>
</td>
<td><? VAR Username ?></td>
<td><? VAR Networks ?></td>
<td><? VAR Clients ?></td>
</tr>
<?ENDLOOP?>
</tbody>
</table>
<?ENDIF?>
</div>
</div>
</div>
<script>
function UserSearch() {
var input, filter, table, tr, td, i;
input = document.getElementById("inputSearch");
filter = input.value.toUpperCase();
table = document.getElementById("users");
tr = table.getElementsByTagName("tr");
for (i = 0; i < tr.length; i++) {
td = tr[i].getElementsByTagName("td")[1];
if (td) {
if (td.innerHTML.toUpperCase().indexOf(filter) > -1) {
tr[i].style.display = "";
} else {
tr[i].style.display = "none";
}
}
}
}
<script type="text/javascript">$(document).ready(function(){var e=$(".list-group-item.active");$("#system-search").keyup(function(){var e=this;var t=$(".table-list-search tbody");var n=$(".table-list-search tbody tr");$(".search-sf").remove();n.each(function(r,i){var s=$(i).text().toLowerCase();var o=$(e).val().toLowerCase();if(o!=""){$(".search-query-sf").remove();t.prepend('<tr class="search-query-sf"><td colspan="6"><strong>Searching for: "'+$(e).val()+'"</strong></td></tr>')}else{$(".search-query-sf").remove()}if(s.indexOf(o)==-1){n.eq(r).hide()}else{$(".search-sf").remove();n.eq(r).show()}});if(n.children(":visible").length==0){t.append('<tr class="search-sf"><td class="text-muted" colspan="6">No entries found.</td></tr>')}})})</script>
</script>
<? INC Footer.tmpl ?>

@ -1,13 +1,12 @@
<? I18N znc-webadmin ?>
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
<div class="panel with-nav-tabs panel-default">
<div class="panel-heading">
<ul class="nav nav-tabs">
<li class="active"><a href="#listenporttab" data-toggle="tab"><? FORMAT "Listen Port(s)" ?></a></li>
<li><a href="#settingstab" data-toggle="tab"><? FORMAT "Settings" ?></a></li>
<li><a href="#globalmodtab" data-toggle="tab"><? FORMAT "Global Modules" ?></a></li>
<li class="active"><a href="#listenporttab" data-toggle="tab">Listen Port(s)</a></li>
<li><a href="#settingstab" data-toggle="tab">Settings</a></li>
<li><a href="#globalmodtab" data-toggle="tab">Global Modules</a></li>
</ul>
</div>
<div class="panel-body">
@ -17,15 +16,14 @@
<table class="table table-bordered table-hover table-striped">
<thead>
<tr>
<th><? FORMAT "Port" ?></th>
<th><? FORMAT "BindHost" ?></th>
<th><? FORMAT "SSL" ?></th>
<th><? FORMAT "IPv4" ?></th>
<th><? FORMAT "IPv6" ?></th>
<th><? FORMAT "IRC" ?></th>
<th><? FORMAT "HTTP" ?></th>
<th><? FORMAT "URIPrefix" ?></th>
<th><? FORMAT "Delete" ?></th>
<td>Port</td>
<td>BindHost</td>
<td>SSL</td>
<td>IPv4</td>
<td>IPv6</td>
<td>IRC</td>
<td>Web</td>
<td>URIPrefix</td>
</tr>
</thead>
<? LOOP ListenLoop ?>
@ -58,8 +56,8 @@
</td>
<td>
<div class="checkboxSwitchMini">
<input type="checkbox" id="<? VAR IsHTTP ?>" disabled="disabled" <? IF IsHTTP ?>checked="checked"<? ENDIF ?>/>
<label for="<? VAR IsHTTP ?>"></label>
<input type="checkbox" id="<? VAR IsWeb ?>" disabled="disabled" <? IF IsWeb ?>checked="checked"<? ENDIF ?>/>
<label for="<? VAR IsWeb ?>"></label>
</div>
</td>
<td><? VAR URIPrefix ?></td>
@ -69,13 +67,10 @@
<? INC _csrf_check.tmpl ?>
<input name="host" type="hidden" value="<? VAR BindHost ?>"/>
<input name="port" type="hidden" value="<? VAR Port ?>"/>
<input name="ssl" type="hidden" value="<? VAR IsSSL ?>"/>
<input name="ipv4" type="hidden" value="<? VAR IsIPV4 ?>"/>
<input name="ipv6" type="hidden" value="<? VAR IsIPV6 ?>"/>
<input type="submit" class="btn btn-danger btn-xs" value="<? FORMAT "Del" ?>"/>
<input type="submit" class="btn btn-danger btn-xs" value="Del"/>
</form>
<? ELSE ?>
<input name="unavailable" type="text" disabled="disabled" title="<? FORMAT "To delete port which you use to access webadmin itself, either connect to webadmin via another port, or do it in IRC (/znc DelPort)" ?>" value="<? FORMAT "Current" ?>" />
<? ENDIF ?>
</td>
</tr>
@ -91,7 +86,7 @@
</td>
<td>
<div class="checkboxSwitchMini">
<input type="checkbox" id="ssl" name="ssl" checked="checked"/>
<input type="checkbox" id="ssl"/>
<label for="ssl"></label>
</div>
</td>
@ -120,7 +115,7 @@
</div>
</td>
<td><input type="text" class="form-control" name="uriprefix" value="/"></td>
<td><input type="submit" class="btn btn-primary btn-xs" value="<? FORMAT "Add" ?>"/></td>
<td><input type="submit" class="btn btn-primary btn-xs" value="Add"/></td>
</form>
</tr>
</table>
@ -132,95 +127,93 @@
<? INC _csrf_check.tmpl ?>
<input type="hidden" name="submitted" value="1" />
<div class="form-group">
<label for="inputSkins" class="col-sm-2 control-label"><? FORMAT "Skin:" ?></label>
<label for="inputSkins" class="col-sm-2 control-label">Skin(s):</label>
<div class="col-sm-10">
<select class="form-control" id="inputSkins" name="skin">
<? LOOP SkinLoop ?>
<option value="<? VAR Name ?>"<? IF Checked ?> selected="selected"<? ENDIF ?>><? IF Name == "_default_" ?><? FORMAT "Default" ?><? ELSE ?><? VAR Name ?><? ENDIF ?></option>
<option value="<? VAR Name ?>"<? IF Checked ?> selected="selected"<? ENDIF ?>><? IF Name == "_default_" ?>Default<? ELSE ?><? VAR Name ?><? ENDIF ?></option>
<? ENDLOOP ?>
</select>
</div>
</div>
<div class="form-group">
<label for="inputStatusPrefix" class="col-sm-2 control-label"><? FORMAT "Status Prefix:" ?></label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputStatusPrefix" value="<? VAR StatusPrefix ?>" placeholder="<? FORMAT "The prefix for the status and module queries." ?>"/>
<div class="alert alert-info help-block"><? FORMAT "Default for new users only." ?></div>
</div>
<label for="inputStatusPrefix" class="col-sm-2 control-label">Status Prefix:</label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputStatusPrefix" value="<? VAR StatusPrefix ?>" placeholder="The prefix for the status and module queries."/>
<div class="alert alert-info help-block">Default for new users only.</div>
</div>
<div class="form-group">
<label for="inputmaxBufferSize" class="col-sm-2 control-label"><? FORMAT "Maximum Buffer Size:" ?></label>
<div class="col-sm-10">
<input type="number" class="form-control" id="inputmaxBufferSize" name="maxbufsize" value="<? VAR MaxBufferSize ?>" placeholder="<? FORMAT "Sets the global Max Buffer Size a user can have." ?>"/>
</div>
</div>
<div class="form-group">
<label for="inputmaxBufferSize" class="col-sm-2 control-label">Maximum Buffer Size:</label>
<div class="col-sm-10">
<input type="number" class="form-control" id="inputmaxBufferSize" name="maxbufsize" value="<? VAR MaxBufferSize ?>" placeholder="Sets the global Max Buffer Size a user can have."/>
</div>
<div class="form-group">
<label for="inputConnectDelay" class="col-sm-2 control-label"><? FORMAT "Connect Delay:" ?></label>
<div class="col-sm-10">
<input type="number" class="form-control" id="inputConnectDelay" name="connectdelay" value="<? VAR ConnectDelay ?>" placeholder="<? FORMAT "The time between connection attempts to IRC servers, in seconds. This affects the connection between ZNC and the IRC server; not the connection between your IRC client and ZNC." ?>" />
</div>
</div>
<div class="form-group">
<label for="inputConnectDelay" class="col-sm-2 control-label">Connect Delay:</label>
<div class="col-sm-10">
<input type="number" class="form-control" id="inputConnectDelay" name="connectdelay" value="<? VAR ConnectDelay ?>" placeholder="The time every connection will be delayed, in seconds. Some servers refuse your connection if you reconnect too fast. This affects the connection between ZNC and the IRC server; not the connection between your IRC client and ZNC. "/>
</div>
<div class="form-group">
<label for="inputServerThrottle" class="col-sm-2 control-label"><? FORMAT "Server Throttle:" ?></label>
<div class="col-sm-10">
<input type="number" class="form-control" id="inputServerThrottle" name="serverthrottle" value="<? VAR ServerThrottle ?>" placeholder="<? FORMAT "The minimal time between two connect attempts to the same hostname, in seconds. Some servers refuse your connection if you reconnect too fast." ?>" />
</div>
</div>
<div class="form-group">
<label for="inputServerThrottle" class="col-sm-2 control-label">Server Throttle:</label>
<div class="col-sm-10">
<input type="number" class="form-control" id="inputServerThrottle" name="serverthrottle" value="<? VAR ServerThrottle ?>" placeholder="The time between two connect attempts to the same hostname." />
</div>
<div class="form-group">
<label for="inputAnonIPLimit" class="col-sm-2 control-label"><? FORMAT "Anonymous Connection Limit per IP:" ?></label>
<div class="col-sm-10">
<input type="number" class="form-control" id="inputAnonIPLimit" name="anoniplimit" value="<? VAR AnonIPLimit ?>" placeholder="<? FORMAT "Limits the number of unidentified connections per IP." ?>" />
</div>
</div>
<div class="form-group">
<label for="inputAnonIPLimit" class="col-sm-2 control-label">Anonymous IP Limit:</label>
<div class="col-sm-10">
<input type="number" class="form-control" id="inputAnonIPLimit" name="anoniplimit" value="<? VAR AnonIPLimit ?>" placeholder="Limits the number of unidentified connections per IP." />
</div>
<div class="form-group">
<label for="inputprotectWeb" class="col-sm-2 control-label"><? FORMAT "Protect Web Sessions:" ?></label>
<div class="col-sm-10">
<div class="switch">
<input type="checkbox" name="protectwebsessions" id="protectwebsessions_checkbox" class="cmn-toggle cmn-toggle-round-flat"<? IF ProtectWebSessions ?> checked="checked"<? ENDIF ?> />
<label for="protectwebsessions_checkbox"></label>
<div class="alert alert-info help-block"><? FORMAT "Disallow IP changing during each web session" ?></div>
</div>
</div>
<div class="form-group">
<label for="inputprotectWeb" class="col-sm-2 control-label">Protect Web Sessions:</label>
<div class="col-sm-10">
<div class="switch">
<input type="checkbox" name="protectwebsessions" id="protectwebsessions_checkbox" class="cmn-toggle cmn-toggle-round-flat"<? IF ProtectWebSessions ?> checked="checked"<? ENDIF ?> />
<label for="protectwebsessions_checkbox"></label>
<div class="alert alert-info help-block">Disallow IP changing during each web session</div>
</div>
</div>
<div class="form-group">
<label for="inputhideversion" class="col-sm-2 control-label"><? FORMAT "Hide ZNC Version:" ?></label>
<div class="col-sm-10">
<div class="switch">
<input type="checkbox" name="hideversion" id="hideversion_checkbox" class="cmn-toggle cmn-toggle-round-flat"<? IF HideVersion ?> checked="checked"<? ENDIF ?> />
<label for="hideversion_checkbox"></label>
<div class="alert alert-info help-block"><? FORMAT "Hide version number from non-ZNC users" ?></div>
</div>
</div>
<div class="form-group">
<label for="inputhideversion" class="col-sm-2 control-label">Hide ZNC Version:</label>
<div class="col-sm-10">
<div class="switch">
<input type="checkbox" name="hideversion" id="hideversion_checkbox" class="cmn-toggle cmn-toggle-round-flat"<? IF HideVersion ?> checked="checked"<? ENDIF ?> />
<label for="hideversion_checkbox"></label>
<div class="alert alert-info help-block">Hide version number from non-ZNC users</div>
</div>
</div>
<div class="form-group">
<label for="inputauthonlyviamodule" class="col-sm-2 control-label"><? FORMAT "Auth Only Via Module:" ?></label>
<div class="col-sm-10">
<div class="switch">
<input type="checkbox" name="authonlyviamodule" id="authonlyviamodule_checkbox" class="cmn-toggle cmn-toggle-round-flat"<? IF AuthOnlyViaModule ?> checked="checked"<? ENDIF ?> />
<label for="authonlyviamodule_checkbox"></label>
<div class="alert alert-info help-block"><? FORMAT "Allow user authentication by external modules only" ?></div>
</div>
</div>
</div>
</div>
<div class="form-group">
<label for="inputMOTD" class="col-sm-2 control-label"><? FORMAT "MOTD:" ?></label>
<label for="inputMOTD" class="col-sm-2 control-label">MOTD:</label>
<div class="col-sm-10">
<textarea class="form-control" id="inputMOTD" name="motd" rows="5" class="monospace"><? LOOP MOTDLoop ?><? VAR Line ?>
<? ENDLOOP ?>
</textarea>
<div class="alert alert-info help-block"><? FORMAT "“Message of the Day”, sent to all ZNC users on connect." ?></div>
</div>
<div class="alert alert-info help-block">"Message of the Day", sent to all ZNC users on connect.</div>
</div>
</div>
<div class="form-group">
<label for="inputBindHosts" class="col-sm-2 control-label">BindHosts:</label>
<div class="col-sm-10">
<textarea type="text" class="form-control" id="inputBindHosts" name="bindhosts" rows="5"><? LOOP BindHostLoop ?><? VAR BindHost ?>
<? ENDLOOP ?>
</textarea>
<div class="alert alert-info help-block">One host name or IP entry per line.</div>
</div>
</div>
</div><!-- Settings -->
<!-- Global Module Settings -->
@ -228,12 +221,12 @@
<table class="table table-bordered table-hover table-striped">
<thead>
<tr>
<th></th>
<th><? FORMAT "Name" ?></th>
<th><? FORMAT "Arguments" ?></th>
<th><? FORMAT "Description" ?></th>
<th><? FORMAT "Loaded by networks" ?></th>
<th><? FORMAT "Loaded by users" ?></th>
<td>Status</td>
<td>Name</td>
<td>Arguments</td>
<td>Description</td>
<td>Global</td>
<td>Networks</td>
</tr>
</thead>
<tbody>
@ -289,7 +282,7 @@
<div class="panel-footer text-right">
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" value="<? FORMAT "Save" ?>" />
<input class="btn btn-success" type="submit" value="Save" />
</div>
</div>

@ -1,9 +1,8 @@
<? I18N znc-webadmin ?>
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
<div class="panel panel-default">
<div class="panel-heading"><? FORMAT "Information" ?></div>
<div class="panel-heading">Traffic Information</div>
<div class="panel-body">
<div class="row">
<div class="col-md-6"><div id="totalstats"></div></div>
@ -59,10 +58,10 @@
<table class="table table-bordered table-hover">
<tbody>
<tr>
<th><? FORMAT "Uptime" ?></th>
<th>Uptime</th>
<td><? VAR Uptime ?></td>
<td>
<div class="progress" data-toggle="tooltip" data-placement="right" data-original-title="<? VAR Uptime ?> <? FORMAT "Uptime" ?>">
<div class="progress" data-toggle="tooltip" data-placement="right" data-original-title="<? VAR Uptime ?> Uptime">
<div class="progress-bar progress-bar-success" role="progressbar" aria-valuenow="100" aria-valuemin="0" aria-valuemax="100" style="width: 100%;">
</div>
</div>
@ -70,52 +69,52 @@
</tr>
<? IF IsAdmin ?>
<tr>
<th><? FORMAT "Total Users" ?></th>
<th>Total Users</th>
<td>
<? VAR TotalUsers ?>
</td>
<td>
<div class="progress" data-toggle="tooltip" data-placement="right" data-original-title="<? VAR TotalUsers ?> <? FORMAT "Total Users" ?>">
<div class="progress" data-toggle="tooltip" data-placement="right" data-original-title="<? VAR TotalUsers ?> Total Users">
<div class="progress-bar progress-bar-success" role="progressbar" aria-valuenow="<? VAR TotalUsers ?>" aria-valuemin="0" aria-valuemax="500" style="width: <? VAR TotalUsers ?>%">
</div>
</div>
</td>
</tr>
<tr>
<th><? FORMAT "Total Networks" ?></th>
<th>Total Networks</th>
<td><? VAR TotalNetworks ?></td>
<td>
<div class="progress" data-toggle="tooltip" data-placement="right" data-original-title="<? VAR TotalNetworks ?> <? FORMAT "Total Networks" ?>">
<div class="progress" data-toggle="tooltip" data-placement="right" data-original-title="<? VAR TotalNetworks ?> Total Networks">
<div class="progress-bar progress-bar-success" role="progressbar" aria-valuenow="<? VAR TotalNetworks ?>" aria-valuemin="0" aria-valuemax="500" style="width: <? VAR TotalNetworks ?>%">
</div>
</div>
</td>
</tr>
<tr>
<th><? FORMAT "Attached Networks" ?></th>
<th>Attached Networks</th>
<td><? VAR AttachedNetworks ?></td>
<td>
<div class="progress" data-toggle="tooltip" data-placement="right" data-original-title="<? VAR AttachedNetworks ?> <? FORMAT "Attached Networks" ?>">
<div class="progress" data-toggle="tooltip" data-placement="right" data-original-title="<? VAR AttachedNetworks ?> Attached Networks">
<div class="progress-bar" role="progressbar" aria-valuenow="<? VAR AttachedNetworks ?>" aria-valuemin="0" aria-valuemax="500" style="width: <? VAR AttachedNetworks ?>%;">
</div>
</div>
</td>
</tr>
<tr>
<th><? FORMAT "Total Client Connections" ?></th>
<th>Total Client Connections</th>
<td><? VAR TotalCConnections ?></td>
<td>
<div class="progress" data-toggle="tooltip" data-placement="right" data-original-title="<? VAR TotalCConnections ?> <? FORMAT "Total Client Connections" ?>">
<div class="progress" data-toggle="tooltip" data-placement="right" data-original-title="<? VAR TotalCConnections ?> Total Client Connections">
<div class="progress-bar" role="progressbar" aria-valuenow="<? VAR TotalCConnections ?>" aria-valuemin="0" aria-valuemax="500" style="width: <? VAR TotalCConnections ?>%;">
</div>
</div>
</td>
</tr>
<tr>
<th><? FORMAT "Total IRC Connections" ?></th>
<th>Total IRC Connections</th>
<td><? VAR TotalIRCConnections ?></td>
<td>
<div class="progress" data-toggle="tooltip" data-placement="right" data-original-title="<? VAR TotalIRCConnections ?> <? FORMAT "Total IRC Connections" ?>">
<div class="progress" data-toggle="tooltip" data-placement="right" data-original-title="<? VAR TotalIRCConnections ?> Total IRC Connections">
<div class="progress-bar" role="progressbar" aria-valuenow="<? VAR TotalIRCConnections ?>" aria-valuemin="0" aria-valuemax="500" style="width: <? VAR TotalIRCConnections ?>%;">
</div>
</div>
@ -141,10 +140,10 @@
<table class="table table-bordered table-hover table-striped table-list-search">
<thead>
<tr>
<td></td>
<th><? FORMAT CTX="Traffic" "In" ?></th>
<th><? FORMAT CTX="Traffic" "Out" ?></th>
<th><? FORMAT "Total" ?></th>
<td>Username</td>
<td>In</td>
<td>Out</td>
<td>Total</td>
</tr>
</thead>
<tbody>
@ -159,19 +158,19 @@
<? ENDREM ?>
<? IF __LAST__ ?>
<tr>
<td><? FORMAT "Users" ?></td>
<td>User Total</td>
<td><? VAR UserIn TOP ?></td>
<td><? VAR UserOut TOP ?></td>
<td><? VAR UserTotal TOP ?></td>
</tr>
<tr>
<td>ZNC</td>
<td>ZNC Total</td>
<td><? VAR ZNCIn TOP ?></td>
<td><? VAR ZNCOut TOP ?></td>
<td><? VAR ZNCTotal TOP ?></td>
</tr>
<tr>
<td><? FORMAT "Total" ?></td>
<td>Grand Total</td>
<td><? VAR AllIn TOP ?></td>
<td><? VAR AllOut TOP ?></td>
<td><? VAR AllTotal TOP ?></td>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -2,11 +2,9 @@
<? ADDROW CSSLoop HREF=/skinfiles/_default_/bootstrap.min.css ?>
<? ADDROW CSSLoop HREF=/skinfiles/_default_/selectize.bootstrap3.css ?>
<? ADDROW CSSLoop HREF=/skinfiles/_default_/font-awesome.min.css ?>
<? ADDROW CSSLoop HREF=/skinfiles/_default_/jquery-ui-sortable.1.11.4.min.css ?>
<? ADDROW JSLoop HREF=/skinfiles/_default_/jquery.min.js ?>
<? ADDROW JSLoop HREF=/skinfiles/_default_/bootstrap.min.js ?>
<? ADDROW JSLoop HREF=/skinfiles/_default_/selectize.min.js ?>
<? ADDROW JSLoop HREF=/skinfiles/_default_/jquery-ui-sortable.1.11.4.min.js ?>
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta charset="UTF-8" />

@ -5,7 +5,7 @@
<?IF LoggedIn ?>
<hr>
<p>Welcome to ZNC's web interface! &mdash; This web interface will allow you to manage your ZNC account(s) via the WWW. You will be able to enable, disable, add, edit, remove, clone, search your bouncer(s).</p>
<p>New to ZNC? Trying to figure out how to connect to your ZNC? Check out the official <a href="http://wiki.znc.in/" target="_blank">ZNC Wiki</a> or hop onto the IRC channel: #znc at Libera.Chat.</p>
<p>New to ZNC? Trying to figure out how to connect to your ZNC? Check out the official <a href="http://wiki.znc.in/" target="_blank">ZNC Wiki</a> or hop onto the IRC channel: #znc at Freenode or EFnet IRC Network.</p>
<?IF !GlobalModLoop ?>
<?IF !UserModLoop ?>
<p>Oppss! No Web-enabled modules have been loaded. Load modules from IRC ("<code>/msg *status help</code>" and "<code>/msg *status loadmod &lt;module&gt;</code>"). Once you have loaded some Web-enabled modules, the menu will expand.</p>

Loading…
Cancel
Save