cervlet.h

Go to the documentation of this file.
00001 /*
00002  * Copyright (C), 2000-2002 by Contributors to the monit codebase. 
00003  * All Rights Reserved.
00004  *
00005  * This program is free software; you can redistribute it and/or
00006  * modify it under the terms of the GNU General Public License as
00007  * published by the Free Software Foundation; either version 2 of the
00008  * License, or (at your option) any later version.
00009  *
00010  * This program is distributed in the hope that it will be useful, but
00011  * WITHOUT ANY WARRANTY; without even the implied warranty of
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00013  * General Public License for more details.
00014  * 
00015  * You should have received a copy of the GNU General Public License
00016  * along with this program; if not, write to the Free Software Foundation,
00017  * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
00018  */
00019 
00020 
00021 #ifndef CERVLET_H
00022 #define CERVLET_H
00023 
00024 #include <config.h>
00025 
00026 #include "monitor.h"
00027 
00028 #define HEAD_HTML \
00029 "<!DOCTYPE html PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\">"\
00030 "<html>"\
00031 "<head>"\
00032 "  <title>monit: process manager</title>"\
00033 "  <style type=\"text/css\">"\
00034 "  <!--"\
00035 "  BODY {"\
00036 "   margin: 0;"\
00037 "  }"\
00038 "  BODY, P, DIV, TD, TH, TR, FORM, OL, UL, LI, INPUT, TEXTAREA, SELECT, A {"\
00039 "   font-family: Tahoma, Arial, Helvetica, sans-serif;"\
00040 "  }"\
00041 "  A:hover {"\
00042 "   text-decoration: none;"\
00043 "  }"\
00044 "  A  {"\
00045 "   text-decoration: underline;"\
00046 "  }"\
00047 "  .grey {"\
00048 "        color: #666666;"\
00049 "  } "\
00050 "  -->"\
00051 "  </style>"\
00052 "<meta HTTP-EQUIV=\"REFRESH\" CONTENT=%d>"\
00053 "<meta HTTP-EQUIV=\"Expires\" Content=0>"\
00054 "<meta HTTP-EQUIV=\"Pragma\" CONTENT=\"no-cache\">"\
00055 "</head>"\
00056 "<body bgcolor=\"#ffffff\" link=\"#000000\" vlink=\"#000000\""\
00057 " alink=\"#000000\" text=\"#000000\">"\
00058 "<table cellspacing=\"0\" cellpadding=\"0\" width=\"100%%\" border=\"0\">"\
00059 " <tr bgcolor=\"#6F6F6F\">"\
00060 "  <td valign=\"bottom\"><img src=\"/_pixel\" width=\"1\" height=\"1\" alt=\"\"></td>"\
00061 "  </tr>"\
00062 "</table>"\
00063 "<table cellspacing=\"0\" cellpadding=\"10\" width=\"100%%\" border=\"0\">"\
00064 "  <tr bgcolor=\"#DDDDDD\">"\
00065 "    <td align=\"left\" valign=\"top\" width=\"221\" bgcolor=\"#DDDDDD\">"\
00066 "      </a><font color=\"#000000\"><a href=\"http://www.tildeslash.com\"><small><a href='/'>Home</a>&gt;"\
00067 "             <a href='/%s'>%s</a></small></a></font>"\
00068 "   </td>"\
00069 "    <td align=\"left\" valign=\"top\" width=\"918\" bgcolor=\"#DDDDDD\">"\
00070 "      <p align=\"right\">"\
00071 "      <small><a href='/_about'>monit " VERSION "</a></small>"\
00072 "   </td>"\
00073 "  </tr>"\
00074 "</table>"\
00075 "<table cellspacing=\"0\" cellpadding=\"0\" width=\"100%%\" border=\"0\">"\
00076 "  <tr bgcolor=\"#6F6F6F\">"\
00077 "    <td><img src=\"/_pixel\" width=\"1\" height=\"1\" alt=\"\"></td>"\
00078 "  </tr>"\
00079 "</table>"\
00080 "<center>"
00081 
00082 
00083 #define FOOT_HTML "</center>"\
00084 "<p>&nbsp;</p>"\
00085 "<p>&nbsp;</p>"\
00086 "<p><br>"\
00087 "</p>"\
00088 "<div align=\"center\"><font color=\"#666666\">"\
00089 "<small>"\
00090 "&copy; Copyright 2000-2002 by <a class=grey "\
00091 "href=\"http://www.tildeslash.com/monit/who.html\">Contributors</a> "\
00092 "to the monit codebase, All Rights Reserved.<br> </small></font></div><br>"\
00093 "</body>"\
00094 "</html>"
00095 
00096 
00097 #define HEAD(location, refresh) \
00098    out_print(res, HEAD_HTML, refresh, location, location);
00099 
00100 #define FOOT  out_print(res, "%s", FOOT_HTML);
00101 
00102 
00103 #define PIXEL_GIF "R0lGODlhAQABAIAAAP
00104 
00105 
00106 /* Public prototypes */
00107 void init_service();
00108 
00109 #endif