home *** CD-ROM | disk | FTP | other *** search
/ Excalibur 71 / Excalibur_71_cd2.bin / Microsoft_Internet_50 / ieak5.exe / RCDATA / CABINET / reconfg4.pl < prev    next >
Perl Script  |  1999-02-24  |  4KB  |  116 lines

  1. #!/usr/bin/perl
  2. # Written by Edward C Kubaitis
  3.  
  4.  
  5. # The host URL of the Signup Files
  6. $hostURL="http://myserver";
  7.  
  8.  
  9.     @pairs = split(/&/, $ENV{'QUERY_STRING'});
  10.  
  11.     foreach $pair (@pairs) {
  12.        ($name, $value) = split(/=/, $pair);
  13.     $BACKURL=$BACKURL+"$name=$value\&";
  14.        # Un-Webify plus signs and %-encoding
  15.        $value =~ tr/+/ /;
  16.           $value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg;
  17.           $value =~ s/<!--(.|\n)*-->//g;
  18.           if ($allow_html != 1) {
  19.           $value =~ s/<([^>]|\n)*>//g;
  20.           }
  21.          if ($value eq ""){$value=" ";}
  22.        $FORM{$name} = $value;
  23.  
  24.     }
  25. chop($BACKURL);
  26.  
  27.  
  28. open (FILE, ">/myserver/fileshare/ieak.ins");
  29.     print FILE "[Entry]\n";
  30.     print FILE "Entry_Name = IEAK Sample\n";
  31.     print FILE "[Phone]\n";
  32.     print FILE "Dial_As_Is = No\n";
  33.     if ($FORM{'POPSELECTION'} == 1){
  34.         print FILE "Phone_Number = 5555555\n";
  35.         print FILE "Area_Code = 800\n";
  36.         print FILE "Country_Code = 1\n";
  37.         print FILE "Country_Id = 1\n";
  38.     }
  39.     if ($FORM{'POPSELECTION'} == 2){
  40.         print FILE "Phone_Number = 5555555\n";
  41.         print FILE "Area_Code = 206\n";
  42.         print FILE "Country_Code = 1\n";
  43.         print FILE "Country_Id = 1\n";
  44.     }
  45.     if ($FORM{'POPSELECTION'} == 3){
  46.         print FILE "Phone_Number = 5555555\n";
  47.         print FILE "Area_Code = 425\n";
  48.         print FILE "Country_Code = 1\n";
  49.         print FILE "Country_Id = 1\n";
  50.     }
  51.     if ($FORM{'POPSELECTION'} == 4){
  52.         print FILE "Phone_Number = 5555555\n";
  53.         print FILE "Area_Code = 800\n";
  54.         print FILE "Country_Code = 1\n";
  55.         print FILE "Country_Id = 1\n";
  56.     }
  57.     if ($FORM{'POPSELECTION'} == 5){
  58.         print FILE "Phone_Number = 5555555\n";
  59.         print FILE "Area_Code = 206\n";
  60.         print FILE "Country_Code = 1\n";
  61.         print FILE "Country_Id = 1\n";
  62.     }
  63.     if ($FORM{'POPSELECTION'} == 6){
  64.         print FILE "Phone_Number = 5555555\n";
  65.         print FILE "Area_Code = 425\n";
  66.         print FILE "Country_Code = 1\n";
  67.         print FILE "Country_Id = 1\n";
  68.     }
  69.     print FILE "[Server]\n";
  70.     print FILE "Type = PPP\n";
  71.     print FILE "SW_Compress = Yes\n";
  72.     print FILE "PW_Encrypt = Yes\n";
  73.     print FILE "Negotiate_TCP/IP = Yes\n";
  74.     print FILE "Disable_LCP = No\n";
  75.     print FILE "[TCP/IP]\n";
  76.     print FILE "Specify_IP_Address = No\n";
  77.     print FILE "Specify_Server_Address = No\n";
  78.     print FILE "IP_Header_Conpress  = Yes\n";
  79.     print FILE "Gateway_On_Remote = Yes\n";
  80.     print FILE "[User]\n";
  81.     print FILE "Name = john.doe\n";
  82.     print FILE "Password = mypassword\n";
  83.     print FILE "Display_Password = Yes\n";
  84.     print FILE "[Internet_Mail]\n";
  85.     print FILE "Email_Name = John Doe\n";
  86.     print FILE "Email_Address = john.doe\@ieaksample.net\n";
  87.     print FILE "POP_Server = mail.ieaksample.net\n";
  88.     print FILE "POP_Server_Port_Number = 110\n";
  89.     print FILE "POP_Logon_Name = john.doe\n";
  90.     print FILE "POP_Logon_Password = mypassword\n";
  91.     print FILE "SMTP_Server = mail.ieaksample.net\n";
  92.     print FILE "SMTP_Server_Port_Number = 25\n";
  93.     print FILE "Install_Mail = 1\n";
  94.     print FILE "[Internet_News]\n";
  95.     print FILE "NNTP_Server = news.ieaksample.net\n";
  96.     print FILE "NNTP_Server_Port_Number = 119\n";
  97.     print FILE "Logon_Required = No\n";
  98.     print FILE "Install_News = 1\n";
  99.     print FILE "[URL]\n";
  100.     print FILE "Help_Page = http://www.ieaksample.net/helpdesk\n";
  101.     print FILE "[Favorites]\n";
  102.     print FILE "IEAK Sample \\ IEAK Sample Help Desk.url = http://www.ieaksample.net/support/helpdesk.asp\n";
  103.     print FILE "IEAK Sample \\ IEAK Sample Home Page.url = http://www.ieaksample.net/default.asp\n";
  104.     print FILE "[URL]\n";
  105.     print FILE "Home_Page = http://www.ieaksample.net\n";
  106.     print FILE "Search_Page = http://www.ieaksample.net/search\n";
  107.     print FILE "Help_Page = http://www.ieaksample.net/helpdesk\n";
  108. close FILE;
  109.  
  110. print "Location: HTTP://myserver/ieak.ins\n";
  111. print "\n\n";
  112.  
  113. exit(0);
  114.  
  115.  
  116.