Added 'admin textarea'

SVN revision: 446
This commit is contained in:
Stefan Ritt 2003-03-21 16:04:28 +00:00
parent bf342b72c2
commit 2957325d8d
2 changed files with 21 additions and 2 deletions

View File

@ -539,6 +539,11 @@ The default value is 20, and can be changed for installations
which need a different window size. which need a different window size.
<p> <p>
<li><b><code>Admin textarea = &lt;cols&gt;,&lt;rows&gt;</code></b>
<br>
This defines the textarea size for the admin page. Default is <b>80,40</b>.
<p>
<li><b><code>Display mode = [full|summary|threaded]</code></b> <li><b><code>Display mode = [full|summary|threaded]</code></b>
<br> <br>
Default mode for search display. On the find entry form, the checkboxes Default mode for search display. On the find entry form, the checkboxes

View File

@ -6,6 +6,9 @@
Contents: Web server program for Electronic Logbook ELOG Contents: Web server program for Electronic Logbook ELOG
$Log$ $Log$
Revision 1.50 2003/03/21 16:04:28 midas
Added 'admin textarea'
Revision 1.49 2003/03/19 08:56:40 midas Revision 1.49 2003/03/19 08:56:40 midas
Added 'quote on reply' Added 'quote on reply'
@ -5725,7 +5728,7 @@ char str[NAME_LENGTH], mode[256];
void show_admin_page(LOGBOOK *lbs) void show_admin_page(LOGBOOK *lbs)
{ {
int fh, length; int fh, length, rows, cols;
char *buffer; char *buffer;
char str[NAME_LENGTH]; char str[NAME_LENGTH];
@ -5774,7 +5777,18 @@ char str[NAME_LENGTH];
buffer[length] = 0; buffer[length] = 0;
close(fh); close(fh);
rsprintf("<textarea rows=40 cols=80 wrap=virtual name=Text>"); if (getcfg(lbs->name, "Admin textarea", str) && strchr(str, ',') != NULL)
{
cols = atoi(str);
rows = atoi(strchr(str, ',')+1);
}
else
{
cols = 80;
rows = 40;
}
rsprintf("<textarea cols=%d rows=%d wrap=virtual name=Text>", cols, rows);
rsputs(buffer); rsputs(buffer);
free(buffer); free(buffer);