#include <stdio.h>
#include <string.h>
#include <time.h>


#include "global.h"


#include "manhat-lib/shared_util.h"
#include "manhat-lib/shared_super_util.h"
#include "manhat-lib/shared_cs_util.h"
#include "manhat-lib/shared_super_menu.h"

void
set_delete_url(const char *key)
{
  char url[MAX_PATH +1];

  snprintf(url, MAX_PATH +1, "%s?id=%s&amp;field=0&amp;users=3&amp;results=1&amp;sensitive=0&amp;sort=0&amp;where=0", "super_info", key);
  cs_set_value("delete_url", url);
  snprintf(url, MAX_PATH +1, "%s?id=%s", "super_admin_page", key);
  cs_set_value("back_url", url);
  cs_set_int_value("max_length", MAX_PATH);
}

int
main()
{
  char key[MAX_KEY +1];
  SESSION user;

  cs_cgi_init();
  read_param(key);                 /* shared_super_util.c */
  validate_super_key(key, &user);   /* shared_super_util.c */
  set_admin_page(&user, key, 0, "super_info_form");  /* shared_super_menu.c */

  set_delete_url(key);
  cs_cgi_display("super_info_form", 1);
  cs_cgi_destroy();
  return 0;
}
