create_domains.pl
上传用户:xiao730204
上传日期:2007-01-04
资源大小:141k
文件大小:2k
源码类别:

WEB邮件程序

开发平台:

PHP

  1. #!/usr/bin/perl
  2. @tlds = (
  3.    "al",
  4.    "am",
  5.    "art",
  6.    "arts",
  7.    "at",
  8.    "az",
  9.    "ba",
  10.    "bank",
  11.    "be",
  12.    "bg",
  13.    "biz",
  14.    "by",
  15.    "ca",
  16.    "can",
  17.    "cc",
  18.    "cdn",
  19.    "ch",
  20.    "cn",
  21.    "com",
  22.    "corp",
  23.    "cx",
  24.    "cy",
  25.    "cz",
  26.    "dds",
  27.    "de",
  28.    "dir",
  29.    "dk",
  30.    "dz",
  31.    "edu",
  32.    "ee",
  33.    "eg",
  34.    "es",
  35.    "etc",
  36.    "faq",
  37.    "fi",
  38.    "film",
  39.    "fo",
  40.    "fr",
  41.    "fund",
  42.    "gallery",
  43.    "gb",
  44.    "ge",
  45.    "gmbh",
  46.    "gov",
  47.    "gr",
  48.    "help",
  49.    "hk",
  50.    "hotel",
  51.    "hr",
  52.    "hu",
  53.    "ie",
  54.    "il",
  55.    "is",
  56.    "isp",
  57.    "it",
  58.    "jp",
  59.    "k12",
  60.    "kr",
  61.    "li",
  62.    "list",
  63.    "llb",
  64.    "lt",
  65.    "lu",
  66.    "lv",
  67.    "ma",
  68.    "md",
  69.    "med",
  70.    "mil",
  71.    "mk",
  72.    "mt",
  73.    "mx",
  74.    "music",
  75.    "net",
  76.    "nic",
  77.    "nl",
  78.    "no",
  79.    "npo",
  80.    "org",
  81.    "php",
  82.    "pl",
  83.    "prices",
  84.    "pt",
  85.    "radio",
  86.    "ro",
  87.    "ru",
  88.    "se",
  89.    "sg",
  90.    "si",
  91.    "sk",
  92.    "sky",
  93.    "sm",
  94.    "sql",
  95.    "su",
  96.    "tj",
  97.    "tr",
  98.    "tw",
  99.    "ua",
  100.    "uk",
  101.    "us",
  102.    "va",
  103.    "video",
  104.    "xxx",
  105.    "y2k",
  106.    "yu",
  107.    "zine",
  108.    "zoo",
  109.    "666",
  110.    "800",
  111.    "888",
  112.    "int",
  113. );
  114. #
  115. # Most people will propbably just want :
  116. #
  117. # @tlds = (
  118. # "com",
  119. # "net",
  120. # "org",
  121. # );
  122. #
  123. foreach $tld ( @tlds ) {
  124.    $table_name = $tld . '_domains';
  125.    print <<"TLD_TABLE";
  126. CREATE TABLE
  127.    $table_name
  128. (
  129.    sqlId          BIGINT   NOT NULL             AUTO_INCREMENT,
  130.    domain_name    TEXT     DEFAULT ''           NOT NULL,
  131.    serial_number  BIGINT   DEFAULT '0'          NOT NULL,
  132.    refresh        BIGINT   DEFAULT '0'          NOT NULL,
  133.    retry          BIGINT   DEFAULT '0'          NOT NULL,
  134.    expire         BIGINT   DEFAULT '0'          NOT NULL,
  135.    min_ttl        BIGINT   DEFAULT '0'          NOT NULL,  
  136.    PRIMARY KEY( sqlId ),  
  137.    INDEX( sqlId )
  138. );
  139. TLD_TABLE
  140. }