| 63 | | |
| 64 | | if (!is_online()) { |
| 65 | | /* No point re-directing them to the auth server if we haven't been able to talk |
| 66 | | * to it for a while */ |
| 67 | | httpdOutput(r, "<html><head><title>Currently unavailable</title></head><body><h1>Uh oh!</h1>"); |
| 68 | | httpdOutput(r, "We apologize, but it seems that we are currently unable to re-direct you to the login screen."); |
| 69 | | httpdOutput(r, "<p>"); |
| 70 | | httpdOutput(r, "The maintainers of this network are aware of this disruption. We hope that this situation will be resolved soon."); |
| 71 | | httpdOutput(r, "<p>"); |
| 72 | | httpdOutput(r, "Please try again another time."); |
| 73 | | httpdOutput(r, "</body></html>"); |
| 74 | | return; |
| 75 | | } |
| 91 | | if ((asprintf(&newlocation, "Location: %s://%s:%d%slogin?" |
| | 78 | if (!is_online()) { |
| | 79 | /* No point re-directing them to the auth server if we haven't been able to talk |
| | 80 | * to it for a while */ |
| | 81 | httpdOutput(r, "<html><head><title>Currently unavailable</title></head><body><h1>Uh oh!</h1>"); |
| | 82 | httpdOutput(r, "We apologize, but it seems that we are currently unable to re-direct you to the login screen."); |
| | 83 | httpdOutput(r, "<p>"); |
| | 84 | httpdOutput(r, "The maintainers of this network are aware of this disruption. We hope that this situation will be resolved soon."); |
| | 85 | httpdOutput(r, "<p>"); |
| | 86 | httpdPrintf(r, "In a while please <a href='%s'>click here</a> to try again.", url); |
| | 87 | httpdOutput(r, "</body></html>"); |
| | 88 | debug(LOG_INFO, "Sent %s an apology since I am not online - no point sending them to auth server", r->clientAddr); |
| | 89 | } |
| | 90 | else if ((asprintf(&newlocation, "Location: %s://%s:%d%slogin?" |