status-nosavebutton.xslt (23646B)
1 <?xml version="1.0" encoding="UTF-8"?> 2 <xsl:stylesheet version="1.0" 3 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> 4 <xsl:output method="html" 5 encoding="UTF-8" 6 doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN"/> 7 8 <xsl:template match="/"> 9 <html> 10 <head> 11 <title>XR Status Overview</title> 12 <style type="text/css"> 13 h1 { 14 font-family: Verdana,Helvetica; 15 font-size: 12pt; 16 color: blue; 17 } 18 body { 19 font-family: Verdana,Helvetica; 20 font-size: 8pt; 21 } 22 table { 23 border-collapse: collapse; 24 border-style: hidden; 25 } 26 td { 27 font-family: Verdana,Helvetica; 28 font-size: 8pt; 29 background-color: #ffff99; 30 border: 1px solid #f0f090; 31 } 32 input { 33 font-family: Verdana,Helvetica; 34 font-size: 8pt; 35 } 36 .header { background-color: #f3f399; } 37 .footer { color: gray; } 38 </style> 39 <script type="text/javascript"> 40 function goto(uri, input) { 41 if (input == '') 42 document.location = uri; 43 else { 44 var el = document.getElementById(input); 45 if (el) { 46 var value = el.value; 47 if (value != "") 48 document.location = uri + encodeURIComponent(value); 49 else 50 document.location = uri; 51 } 52 } 53 } 54 </script> 55 </head> 56 <body> 57 <h1> 58 XR Status Overview 59 <xsl:apply-templates select="/status/server/webinterfacename"/> 60 </h1> 61 <hr/> 62 <xsl:apply-templates/> 63 </body> 64 </html> 65 </xsl:template> 66 67 <xsl:template match="/status/server/webinterfacename"> 68 <xsl:if test="/status/server/webinterfacename != ''"> 69 <font color="red"> 70 service: <xsl:value-of select="/status/server/webinterfacename"/> 71 </font> 72 </xsl:if> 73 </xsl:template> 74 75 <xsl:template match="/status"> 76 <table> 77 <tr> 78 <td valign="top"> 79 <!-- This is the left hand detailed status view --> 80 <table> 81 <tr> 82 <td colspan="4"><b>Detailed Status</b></td> 83 </tr> 84 <tr> 85 <td colspan="4"><hr/></td> 86 </tr> 87 <xsl:apply-templates select="/status/server"/> 88 <xsl:apply-templates select="/status/backend"/> 89 90 <tr> <td colspan="4"><hr/></td></tr> 91 <tr> 92 <td class="header" colspan="2"> 93 <b>Add back end ip:port</b> 94 </td> 95 <td class="header" colspan="2" align="right"> 96 <input type="text" size="30" name="addbackend" id="addbackend" 97 onchange="goto('/server/addbackend/', 'addbackend');"/> 98 </td> 99 </tr> 100 <tr> <td colspan="4"><hr/></td></tr> 101 102 </table> 103 <xsl:apply-templates select="/status/id"/> 104 </td> 105 <td valign="top"> 106 <!-- This is the right-hand overview --> 107 <table width="100%"> 108 <tr> 109 <td colspan="2"><b>Quick Overview</b></td> 110 </tr> 111 <tr> 112 <td colspan="2"><hr/></td> 113 </tr> 114 <xsl:for-each select="/status/backend"> 115 <tr> 116 <td> 117 <b>Back end 118 <a href="#{nr}"><xsl:value-of select="address"/></a> 119 </b> 120 </td> 121 <td> 122 <xsl:value-of select="up"/>, 123 <xsl:value-of select="live"/>, 124 <xsl:value-of select="available"/>, 125 <xsl:value-of select="connections"/> connections 126 </td> 127 </tr> 128 </xsl:for-each> 129 </table> 130 <!-- This is the activity overview --> 131 <table width="100%"> 132 <tr> 133 <td colspan="5"><hr/></td> 134 </tr> 135 <tr> 136 <td colspan="5"><b>Activity</b></td> 137 </tr> 138 <tr> 139 <td colspan="5"><hr/></td> 140 </tr> 141 <tr> 142 <td colspan="3">Number of threads</td> 143 <td><xsl:value-of select="/status/activity/threadcount"/></td> 144 <td></td> 145 </tr> 146 <tr> 147 <td colspan="3">Used file descriptors (approx.)</td> 148 <td><xsl:value-of select="/status/activity/openfiles"/></td> 149 <td></td> 150 </tr> 151 <tr> 152 <td colspan="3">File descriptor limit</td> 153 <td><xsl:value-of select="/status/activity/maxopenfiles"/></td> 154 <td></td> 155 </tr> 156 <tr> 157 <td><b>Thread</b></td> 158 <td><b>Description</b></td> 159 <td><b>Back end</b></td> 160 <td><b>Duration</b></td> 161 <td></td> 162 </tr> 163 <xsl:apply-templates select="/status/activity/threadlist/thread"> 164 <xsl:sort select="duration" data-type="number"/> 165 </xsl:apply-templates> 166 </table> 167 </td> 168 </tr> 169 </table> 170 </xsl:template> 171 172 <xsl:template match="/status/activity/threadlist/thread"> 173 <tr> 174 <td><xsl:value-of select="id"/></td> 175 <td> 176 <xsl:value-of select="description"/> 177 <xsl:if test="clientip != '0.0.0.0'"> 178 (client <xsl:value-of select="clientip"/>) 179 </xsl:if> 180 </td> 181 <xsl:choose> 182 <xsl:when test="backend = -1"> 183 <td></td> 184 </xsl:when> 185 <xsl:otherwise> 186 <td><xsl:value-of select="address"/></td> 187 </xsl:otherwise> 188 </xsl:choose> 189 <td><xsl:value-of select="duration"/></td> 190 <xsl:choose> 191 <xsl:when test="backend = -1"> 192 <td></td> 193 </xsl:when> 194 <xsl:otherwise> 195 <td><input type="button" value="Kill" 196 onclick="goto('/thread/kill/{id}', '');"/> 197 </td> 198 </xsl:otherwise> 199 </xsl:choose> 200 </tr> 201 </xsl:template> 202 203 <xsl:template match="/status/id"> 204 <i> 205 Powered by Crossroads V<xsl:value-of select="version"/>. 206 Visit 207 <a href="{distsite}" 208 target="_blank"><xsl:value-of select="distsite"/></a> 209 for more info. 210 </i> 211 </xsl:template> 212 213 <xsl:template match="/status/server"> 214 <tr> 215 <td class="header" colspan="3"> 216 <b>Server <xsl:value-of select="address"/> </b> 217 </td> 218 <td class="header"> 219 <input type="button" onclick="goto('/', '');" value="Refresh"/> 220 </td> 221 </tr> 222 <tr> 223 <td>Status</td> 224 <td colspan="3"> 225 <xsl:choose> 226 <xsl:when test="terminating = 0"> 227 Accepting connections, 228 <xsl:value-of select="connections"/> concurrent client(s), 229 </xsl:when> 230 <xsl:otherwise> 231 <font color="red"> 232 Terminating, still serving 233 <xsl:value-of select="connections"/> connections, 234 </font> 235 </xsl:otherwise> 236 </xsl:choose> 237 <xsl:value-of select="backends"/> defined back ends 238 </td> 239 </tr> 240 <tr> 241 <td>Dispatch mode</td> 242 <td colspan="3"> <xsl:value-of select="dispatchmode"/> </td> 243 </tr> 244 <tr> 245 <td>Type</td> 246 <td colspan="2"></td> 247 <td> 248 <xsl:choose> 249 <xsl:when test="type = 'http'"> 250 <select onchange="goto('/server/type/tcp', '');"> 251 <option value="tcp">tcp</option> 252 <option value="http" selected="1">http</option> 253 </select> 254 </xsl:when> 255 <xsl:otherwise> 256 <select onchange="goto('/server/type/http', '');"> 257 <option value="tcp" selected="1">tcp</option> 258 <option value="http">http</option> 259 </select> 260 </xsl:otherwise> 261 </xsl:choose> 262 </td> 263 </tr> 264 <tr> 265 <td>Checks</td> 266 <td>Wakeup interval</td> 267 <td> 268 <xsl:choose> 269 <xsl:when test="checks/wakeupinterval = 0"> 270 off 271 </xsl:when> 272 <xsl:otherwise> 273 sec 274 </xsl:otherwise> 275 </xsl:choose> 276 </td> 277 <td> 278 <input type="text" size="8" name="wakeupinterval" 279 id="wakeupinterval" value="{checks/wakeupinterval}" 280 onchange="goto('/server/wakeupinterval/', 'wakeupinterval');"/> 281 </td> 282 </tr> 283 <tr> 284 <td></td> 285 <td>Checkup interval</td> 286 <td> 287 <xsl:choose> 288 <xsl:when test="checks/checkupinterval = 0"> 289 off 290 </xsl:when> 291 <xsl:otherwise> 292 sec 293 </xsl:otherwise> 294 </xsl:choose> 295 </td> 296 <td> 297 <input type="text" size="8" name="checkupinterval" 298 id="checkupinterval" value="{checks/checkupinterval}" 299 onchange="goto('/server/checkupinterval/', 'checkupinterval');"/> 300 </td> 301 </tr> 302 <tr> 303 <td>Timeouts</td> 304 <td>Client read</td> 305 <td> 306 <xsl:choose> 307 <xsl:when test="clientreadtimeout = 0"> 308 unlimited 309 </xsl:when> 310 <xsl:otherwise> 311 sec 312 </xsl:otherwise> 313 </xsl:choose> 314 </td> 315 <td> 316 <input type="text" size="8" name="clientreadtimeout" 317 id="clientreadtimeout" value="{clientreadtimeout}" 318 onchange="goto('/server/clientreadtimeout/', 'clientreadtimeout');"/> 319 </td> 320 </tr> 321 <tr> 322 <td></td> 323 <td>Client write</td> 324 <td> 325 <xsl:choose> 326 <xsl:when test="clientwritetimeout = 0"> 327 unlimited 328 </xsl:when> 329 <xsl:otherwise> 330 sec 331 </xsl:otherwise> 332 </xsl:choose> 333 </td> 334 <td> 335 <input type="text" size="8" name="clientwritetimeout" 336 id="clientwritetimeout" value="{clientwritetimeout}" 337 onchange="goto('/server/clientwritetimeout/', 'clientwritetimeout');"/> 338 </td> 339 </tr> 340 <tr> 341 <td></td> 342 <td>Back end read</td> 343 <td> 344 <xsl:choose> 345 <xsl:when test="backendreadtimeout = 0"> 346 unlimited 347 </xsl:when> 348 <xsl:otherwise> 349 sec 350 </xsl:otherwise> 351 </xsl:choose> 352 </td> 353 <td> 354 <input type="text" size="8" name="backendreadtimeout" 355 id="backendreadtimeout" value="{backendreadtimeout}" 356 onchange="goto('/server/backendreadtimeout/', 'backendreadtimeout');"/> 357 </td> 358 </tr> 359 <tr> 360 <td></td> 361 <td>Back end write</td> 362 <td> 363 <xsl:choose> 364 <xsl:when test="backendwritetimeout = 0"> 365 unlimited 366 </xsl:when> 367 <xsl:otherwise> 368 sec 369 </xsl:otherwise> 370 </xsl:choose> 371 </td> 372 <td> 373 <input type="text" size="8" name="backendwritetimeout" 374 id="backendwritetimeout" value="{backendwritetimeout}" 375 onchange="goto('/server/backendwritetimeout/', 'backendwritetimeout');"/> 376 </td> 377 </tr> 378 <tr> 379 <td></td> 380 <td>DNS cache validity</td> 381 <td> 382 <xsl:choose> 383 <xsl:when test="dnscachetimeout = 0"> 384 unused 385 </xsl:when> 386 <xsl:otherwise> 387 sec 388 </xsl:otherwise> 389 </xsl:choose> 390 </td> 391 <td> 392 <input type="text" size="8" name="dnscachetimeout" 393 id="dnscachetimeout" value="{dnscachetimeout}" 394 onchange="goto('/server/dnscachetimeout/', 'dnscachetimeout');"/> 395 </td> 396 </tr> 397 398 <tr> 399 <td>Fast sockets closing</td> 400 <td colspan="2">eliminates TIME_WAIT state</td> 401 <td> 402 <xsl:choose> 403 <xsl:when test="closesocketsfast = 0"> 404 <select onchange="goto('/server/closesocketsfast/on', '');"> 405 <option value="yes">yes</option> 406 <option value="no" selected="1">no</option> 407 </select> 408 </xsl:when> 409 <xsl:otherwise> 410 <select onchange="goto('/server/closesocketsfast/off', '');"> 411 <option value="yes" selected="1">yes</option> 412 <option value="no">no</option> 413 </select> 414 </xsl:otherwise> 415 </xsl:choose> 416 </td> 417 </tr> 418 <tr> 419 <td>Debugging</td> 420 <td colspan="2">Verbose logging</td> 421 <td> 422 <xsl:choose> 423 <xsl:when test="debugging/verbose = 0"> 424 <select onchange="goto('/server/verbose/on', '');"> 425 <option value="yes">yes</option> 426 <option value="no" selected="1">no</option> 427 </select> 428 </xsl:when> 429 <xsl:otherwise> 430 <select onchange="goto('/server/verbose/off', '');"> 431 <option value="yes" selected="1">yes</option> 432 <option value="no">no</option> 433 </select> 434 </xsl:otherwise> 435 </xsl:choose> 436 </td> 437 </tr> 438 <tr> 439 <td></td> 440 <td colspan="2">Debug logging</td> 441 <td> 442 <xsl:choose> 443 <xsl:when test="debugging/debug = 0"> 444 <select onchange="goto('/server/debug/on', '');"> 445 <option value="yes">yes</option> 446 <option value="no" selected="1">no</option> 447 </select> 448 </xsl:when> 449 <xsl:otherwise> 450 <select onchange="goto('/server/debug/off', '');"> 451 <option value="yes" selected="1">yes</option> 452 <option value="no">no</option> 453 </select> 454 </xsl:otherwise> 455 </xsl:choose> 456 </td> 457 </tr> 458 <tr> 459 <td></td> 460 <td>Traffic log directory</td> 461 <td colspan="2" align="right"> 462 <input type="text" size="30" name="logtrafficdir" id="logtrafficdir" 463 value="{debugging/logtrafficdir}" 464 onchange="goto('/server/logtrafficdir/', 'logtrafficdir');"/> 465 </td> 466 </tr> 467 <tr> 468 <td>Activity scripts</td> 469 <td>Onstart command</td> 470 <td colspan="2" align="right"> 471 <input type="text" size="30" name="onstart" id="onstart" 472 value="{onstart}" 473 onchange="goto('/server/onstart/', 'onstart');"/> 474 </td> 475 </tr> 476 <tr> 477 <td></td> 478 <td>Onend command</td> 479 <td colspan="2" align="right"> 480 <input type="text" size="30" name="onend" id="onend" 481 value="{onend}" 482 onchange="goto('/server/onend/', 'onend');"/> 483 </td> 484 </tr> 485 <tr> 486 <td></td> 487 <td>Onfail command</td> 488 <td colspan="2" align="right"> 489 <input type="text" size="30" name="onfail" id="onfail" 490 value="{onfail}" 491 onchange="goto('/server/onfail/', 'onfail');"/> 492 </td> 493 </tr> 494 <tr> 495 <td>Network buffer size</td> 496 <td colspan="2">bytes</td> 497 <td> 498 <input type="text" size="8" name="serverbufsz" id="serverbufsz" 499 value="{buffersize}" 500 onchange="goto('/server/buffersize/', 'serverbufsz');"/> 501 </td> 502 </tr> 503 <tr> 504 <td>DOS Protection</td> 505 <td>Max. connections </td> 506 <td> 507 <xsl:choose> 508 <xsl:when test="/dosprotection/maxconnections = 0"> 509 unlimited 510 </xsl:when> 511 <xsl:otherwise> 512 maximum value (0 for unlimited) 513 </xsl:otherwise> 514 </xsl:choose> 515 </td> 516 <td> 517 <input type="text" size="8" name="setservermaxcon" class="input" 518 id="setservermaxcon" value="{dosprotection/maxconnections}" 519 onchange="goto('/server/maxconnections/', 'setservermaxcon');"/> 520 </td> 521 </tr> 522 523 <tr> 524 <td></td> 525 <td>Sample duration</td> 526 <td>sec</td> 527 <td> 528 <input type="text" size="8" name="timeinterval" class="input" 529 id="timeinterval" value="{dosprotection/timeinterval}" 530 onchange="goto('/server/timeinterval/', 'timeinterval');"/> 531 </td> 532 </tr> 533 <tr> 534 <td></td> 535 <td>Hard max connection rate</td> 536 <td> 537 <xsl:choose> 538 <xsl:when test="/dosprotection/hardmaxconnrate = 0"> 539 unlimited 540 </xsl:when> 541 <xsl:otherwise> 542 sessions per sample (0 for unlimited) 543 </xsl:otherwise> 544 </xsl:choose> 545 </td> 546 <td> 547 <input type="text" size="8" name="hardmaxconnrate" class="input" 548 id="hardmaxconnrate" value="{dosprotection/hardmaxconnrate}" 549 onchange="goto('/server/hardmaxconnrate/', 'hardmaxconnrate');"/> 550 </td> 551 </tr> 552 <tr> 553 <td></td> 554 <td>Soft max connection rate</td> 555 <td> 556 <xsl:choose> 557 <xsl:when test="/dosprotection/softmaxconnrate = 0"> 558 unlimited 559 </xsl:when> 560 <xsl:otherwise> 561 sessions per sample (0 for unlimited) 562 </xsl:otherwise> 563 </xsl:choose> 564 </td> 565 <td> 566 <input type="text" size="8" name="softmaxconnrate" class="input" 567 id="softmaxconnrate" value="{dosprotection/softmaxconnrate}" 568 onchange="goto('/server/softmaxconnrate/', 'softmaxconnrate');"/> 569 </td> 570 </tr> 571 <tr> 572 <td></td> 573 <td>Defer time</td> 574 <td>in microsec, 1.000.000 = 1 sec</td> 575 <td> 576 <input type="text" size="8" name="defertime" class="input" 577 id="defertime" value="{dosprotection/defertime}" 578 onchange="goto('/server/defertime/', 'defertime');"/> 579 </td> 580 </tr> 581 582 <tr> 583 <td></td> 584 <td>Hard excess signal program</td> 585 <td colspan="2" align="right"> 586 <input type="text" size="30" name="hardexcess" class="input" 587 id="hardexcess" value="{dosprotection/hardmaxconnexcess}" 588 onchange="goto('/server/hardmaxconnexcess/', 'hardexcess');"/> 589 </td> 590 </tr> 591 592 <tr> 593 <td></td> 594 <td>Soft excess signal program</td> 595 <td colspan="2" align="right"> 596 <input type="text" size="30" name="softexcess" class="input" 597 id="softexcess" value="{dosprotection/softmaxconnexcess}" 598 onchange="goto('/server/softmaxconnexcess/', 'softexcess');"/> 599 </td> 600 </tr> 601 602 <tr> 603 <td>Access Control Lists</td> 604 <td>New allow-from</td> 605 <td colspan="2" align="right"> 606 <input type="text" size="30" name="addallowfrom" class="input" 607 id="addallowfrom" 608 onchange="goto('/server/addallowfrom/', 'addallowfrom');"/> 609 </td> 610 </tr> 611 <xsl:apply-templates select="/status/server/acl/allow"/> 612 <tr> 613 <td></td> 614 <td>New deny-from</td> 615 <td colspan="2" align="right"> 616 <input type="text" size="30" name="adddenyfrom" class="input" 617 id="adddenyfrom" 618 onchange="goto('/server/adddenyfrom/', 'adddenyfrom');"/> 619 </td> 620 </tr> 621 <xsl:apply-templates select="/status/server/acl/deny"/> 622 623 <tr> 624 <td>Web interface credentials</td> 625 <td>Format username:password</td> 626 <td colspan="2" align="right"> 627 <input type="text" size="30" name="webinterfaceauth" class="input" 628 id="webinterfaceauth" value="{webinterfaceauth}" 629 onchange="goto('/server/webinterfaceauth/', 'webinterfaceauth');"/> 630 </td> 631 </tr> 632 633 <xsl:if test="/status/server/type = 'http'"> 634 <xsl:apply-templates select="/status/server/http"/> 635 </xsl:if> 636 </xsl:template> 637 638 <xsl:template match="/status/backend"> 639 <tr> <td colspan="4"><hr/></td></tr> 640 <tr> 641 <td class="header" colspan="3"> 642 <a name="{nr}"/> 643 <b> Back end <xsl:value-of select="address"/> </b> 644 </td> 645 <td class="header"> 646 <input type="button" value="Delete" 647 onclick="goto('/server/deletebackend/{nr}', '');"/> 648 </td> 649 </tr> 650 <tr> 651 <td><b>State</b></td> 652 <td>Health</td> 653 <td colspan="2"> 654 <xsl:value-of select="live"/>, 655 <xsl:value-of select="available"/> 656 </td> 657 </tr> 658 <tr> 659 <td></td> 660 <td>Connections</td> 661 <td colspan="2"> 662 <xsl:value-of select="connections"/> 663 <xsl:if test="anticipated > 0"> 664 (anticipating <xsl:value-of select="anticipated"/>) 665 </xsl:if> 666 </td> 667 </tr> 668 <tr> 669 <td></td> 670 <td>Connect failures</td> 671 <td colspan="2"> 672 <xsl:value-of select="connecterrors"/> 673 </td> 674 </tr> 675 <tr> 676 <td></td> 677 <td>Served</td> 678 <td colspan="2"> 679 <xsl:value-of select="bytesserved"/> bytes, 680 <xsl:value-of select="clientsserved"/> clients 681 </td> 682 </tr> 683 <tr> 684 <td><b>Options</b></td> 685 <td colspan="2">Weight</td> 686 <td> 687 <input type="text" size="8" name="setbackendweight{nr}" 688 id="setbackendweight{nr}" value="{weight}" 689 onchange="goto('/backend/{nr}/weight/', 'setbackendweight{nr}');"/> 690 </td> 691 </tr> 692 <tr> 693 <td></td> 694 <td>Max. connections</td> 695 <td> 696 <xsl:choose> 697 <xsl:when test="maxconnections = 0"> 698 unlimited 699 </xsl:when> 700 <xsl:otherwise> 701 maximum value (0 for unlimited) 702 </xsl:otherwise> 703 </xsl:choose> 704 </td> 705 <td> 706 <input type="text" size="8" name="setbackendmaxcon{nr}" class="input" 707 id="setbackendmaxcon{nr}" value="{maxconnections}" 708 onchange="goto('/backend/{nr}/maxconnections/', 'setbackendmaxcon{nr}');"/> 709 </td> 710 </tr> 711 <tr> 712 <td></td> 713 <td colspan="2">Load average</td> 714 <td> 715 <input type="text" size="8" name="setloadaverage{nr}" 716 id="setloadaverage{nr}" value="{loadavg}" 717 onchange="goto('/backend/{nr}/loadavg/', 'setloadaverage{nr}');"/> 718 </td> 719 </tr> 720 <tr> 721 <td></td> 722 <td colspan="2">Backend check (. to reset)</td> 723 <td> 724 <input type="text" size="8" name="backendcheck{nr}" 725 id="backendcheck{nr}" value="{backendcheck}" 726 onchange="goto('/backend/{nr}/backendcheck/', 'backendcheck{nr}');"/> 727 </td> 728 </tr> 729 <xsl:if test="/status/server/type = 'http'"> 730 <tr> 731 <td></td> 732 <td>Host match</td> 733 <td> 734 <xsl:choose> 735 <xsl:when test="hostmatch = '.'"> 736 any host request 737 </xsl:when> 738 <xsl:otherwise> 739 (. for any host) 740 </xsl:otherwise> 741 </xsl:choose> 742 </td> 743 <td> 744 <input type="text" size="8" name="sethostmatch{nr}" 745 id="sethostmatch{nr}" value="{hostmatch}" 746 onchange="goto('/backend/{nr}/hostmatch/', 747 'sethostmatch{nr}');"/> 748 </td> 749 </tr> 750 <tr> 751 <td></td> 752 <td>URL match</td> 753 <td> 754 <xsl:choose> 755 <xsl:when test="urlmatch = '.'"> 756 any url request 757 </xsl:when> 758 <xsl:otherwise> 759 (. for any url) 760 </xsl:otherwise> 761 </xsl:choose> 762 </td> 763 <td> 764 <input type="text" size="8" name="seturlmatch{nr}" 765 id="seturlmatch{nr}" value="{urlmatch}" 766 onchange="goto('/backend/{nr}/urlmatch/', 767 'seturlmatch{nr}');"/> 768 </td> 769 </tr> 770 </xsl:if> 771 <tr> 772 <td></td> 773 <td colspan="2">Up state</td> 774 <td> 775 <xsl:choose> 776 <xsl:when test="up = 'up'"> 777 <select onchange="goto('/backend/{nr}/up/off', '');"> 778 <option value="yes" selected="1">yes</option> 779 <option value="no">no</option> 780 </select> 781 </xsl:when> 782 <xsl:otherwise> 783 <select onchange="goto('/backend/{nr}/up/on', '');"> 784 <option value="yes">yes</option> 785 <option value="no" selected="1">no</option> 786 </select> 787 </xsl:otherwise> 788 </xsl:choose> 789 </td> 790 </tr> 791 <tr> 792 <td></td> 793 <td colspan="2">Stop all connections</td> 794 <td> 795 <input type="button" value="Stop now" 796 onclick="goto('/backend/{nr}/stopconnections', '');"/> 797 </td> 798 </tr> 799 </xsl:template> 800 801 <xsl:template match="/status/server/http"> 802 <tr> 803 <td>HTTP Goodies</td> 804 <td colspan="2">Add X-Forwarded-For</td> 805 <td> 806 <xsl:choose> 807 <xsl:when test="addxforwardedfor = 0"> 808 <select onchange="goto('/server/addxforwardedfor/on', '');"> 809 <option value="yes">yes</option> 810 <option value="no" selected="1">no</option> 811 </select> 812 </xsl:when> 813 <xsl:otherwise> 814 <select onchange="goto('/server/addxforwardedfor/off', '');"> 815 <option value="yes" selected="1">yes</option> 816 <option value="no">no</option> 817 </select> 818 </xsl:otherwise> 819 </xsl:choose> 820 </td> 821 </tr> 822 <tr> 823 <td></td> 824 <td colspan="2">Sticky HTTP</td> 825 <td> 826 <xsl:choose> 827 <xsl:when test="stickyhttp = 0"> 828 <select onchange="goto('/server/stickyhttp/on', '');"> 829 <option value="yes">yes</option> 830 <option value="no" selected="1">no</option> 831 </select> 832 </xsl:when> 833 <xsl:otherwise> 834 <select onchange="goto('/server/stickyhttp/off', '');"> 835 <option value="yes" selected="1">yes</option> 836 <option value="no">no</option> 837 </select> 838 </xsl:otherwise> 839 </xsl:choose> 840 </td> 841 </tr> 842 <tr> 843 <td></td> 844 <td colspan="2">Replace Host: headers</td> 845 <td> 846 <xsl:choose> 847 <xsl:when test="replacehostheader = 0"> 848 <select onchange="goto('/server/replacehostheader/on', '');"> 849 <option value="yes">yes</option> 850 <option value="no" selected="1">no</option> 851 </select> 852 </xsl:when> 853 <xsl:otherwise> 854 <select onchange="goto('/server/replacehostheader/off', '');"> 855 <option value="yes" selected="1">yes</option> 856 <option value="no">no</option> 857 </select> 858 </xsl:otherwise> 859 </xsl:choose> 860 </td> 861 </tr> 862 <xsl:apply-templates select="/status/server/http/serverheaders"/> 863 </xsl:template> 864 865 <xsl:template match="/status/server/acl/allow"> 866 <xsl:for-each select="allowfrom"> 867 <tr> 868 <td></td> 869 <td>Allow from</td> 870 <td colspan="2" align="right"> 871 <input type="text" size="30" name="allowfrom{nr}" 872 id="allowfrom{nr}" value="{mask}" 873 onchange="goto('/server/allowfrom/{nr}/', 'allowfrom{nr}');"/> 874 </td> 875 </tr> 876 </xsl:for-each> 877 </xsl:template> 878 879 <xsl:template match="/status/server/acl/deny"> 880 <xsl:for-each select="denyfrom"> 881 <tr> 882 <td></td> 883 <td>Deny from</td> 884 <td colspan="2" align="right"> 885 <input type="text" size="30" name="denyfrom{nr}" 886 id="denyfrom{nr}" value="{mask}" 887 onchange="goto('/server/denyfrom/{nr}/', 'denyfrom{nr}');"/> 888 </td> 889 </tr> 890 </xsl:for-each> 891 </xsl:template> 892 893 <xsl:template match="/status/server/http/serverheaders"> 894 <xsl:for-each select="serverheader"> 895 <tr> 896 <td></td> 897 <td>Server header</td> 898 <td colspan="2" align="right"> 899 <input type="text" size="30" name="serverheader{nr}" 900 id="serverheader{nr}" value="{header}" 901 onchange="goto('/server/changeheader/{nr}/', 'serverheader{nr}');"/> 902 </td> 903 </tr> 904 </xsl:for-each> 905 <tr> 906 <td></td> 907 <td>New server header</td> 908 <td colspan="2" align="right"> 909 <input type="text" size="30" name="newserverheader" 910 id="newserverheader" 911 onchange="goto('/server/newheader/', 'newserverheader');"/> 912 </td> 913 </tr> 914 </xsl:template> 915 916 <xsl:template match="*"/> 917 918 </xsl:stylesheet>