home *** CD-ROM | disk | FTP | other *** search
/ PC World 2000 July / PCWorld_2000-07_cd.bin / Komunik / sambar / _SETUP.1 / register.pl < prev    next >
Text File  |  1999-06-28  |  2KB  |  63 lines

  1. print "<html><head><META HTTP-EQUIV=\"Pragma\" CONTENT=no-cache><title>Create your own .REG for your Windows 9x</title>";
  2. print "<body>";
  3. my $fhandle = undef ;
  4. my $filename = "SambarService.reg" ;
  5.  
  6.  
  7. $local = $ENV{'DOCUMENT_URI'};
  8. $local =~ s/\//\\/g;
  9. $local =~ s/register.pl//g;
  10.  
  11. $count = $ENV{'DOCUMENT_ROOT'};
  12. $count =~ s/\//\\\\/g;
  13. $count =~ s/docs/bin/g;
  14.  
  15. $sahome = $count;
  16. $sahome =~ s/\\\\bin\\\\//g;
  17. $sahome =~ s/\\\\/\\/g;
  18.  
  19. print "<center><H2>For automatic Windows 9x Registry Update</center><BR>Check data below</h2>";
  20.  
  21. print "<code>";
  22. print "REGEDIT4<BR>";
  23. $text00 = "REGEDIT4\n";
  24.  
  25. print "; Contributor: Jorge Somers<BR>";
  26. $text10 = "; Contributor: Jorge Somers\n";
  27.  
  28. print "; E-Mail: JHSomers\@Somers\.com\.br<BR>";
  29. $text11 = ";              JHSomers\@Somers\.com\.br\n";
  30.  
  31. print "; Date: Jun 22, 1999<BR>";
  32. $text20 = "; Date:        Jun 18, 1999\n";
  33.  
  34. print "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\RunServices]<BR>";
  35. $text30 = "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\RunServices]\n";
  36.  
  37. print "\"Sambar\"\=\"",$count,"server.exe -t\"<BR>";
  38. $text40 = "\"Sambar\"\=\"";
  39. $text50 = $count;
  40. $text60 = "server.exe -t\"\n";
  41. print "</code>";
  42.  
  43. print "<h3>Just click over the file <code><font point-size=10>",$sahome,$local,$filename,"</font></code></h3>";
  44.  
  45.  
  46. print "<H2>Don't forget to place at your <I>autoexec.bat</i></h2>";
  47.  
  48. print "<code>SET SAHOME=",$sahome,"</code>";
  49.  
  50. open( OUT, ">$filename" ) or die "Error Preparing .REG file" ;
  51. print OUT "$text00\n";
  52. print OUT "$text10";
  53. print OUT "$text11";
  54. print OUT "$text20\n";
  55. print OUT "$text30";
  56. print OUT "$text40";
  57. print OUT "$text50";
  58. print OUT "$text60";
  59.  
  60. close(OUT);
  61. print "</body>";
  62. print "</html>";
  63.