[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[cobalt-developers] siteAdd.cgi script changes



I have made the following modifications to the below specified files.
These changes were made to keep <index.html> from taking precedence over a
clients index page name in the event that the filename is index.htm or
default.htm etc..

-----------------------------------------------------------------------
The following changes were also made to 
/usr/admserv/cgi-bin/.cobalt/siteAdd/siteAdd.cgi

system( "mv -f $Htgroup_dir/$groupName/$Webdir/index.html
$Htgroup_dir/$groupName/$$
-----------------------------------------------------------------------

       # substitute variable names
        my $idxin = "$Htgroup_dir/$groupName/$Webdir/index.html";
        my $idxout = "/etc/locks/index.html.$groupName";
        if (-f $idxin) {
            open(IN,"$idxin");
            open(OUT,">$idxout");
            while( <IN> ) {
                s/\[DOMAIN\]/$hostName/go;
                print OUT;
            }
            close( IN );
            close( OUT );
            system( "mv -f $idxout $idxin" );

chown($WWWuid,(getgrnam($groupName))[2],"$Htgroup_dir/$groupName/$Webdir/ind
ex.html");

            chmod(0664,"$Htgroup_dir/$groupName/$Webdir/index.html");


            # The following line was added by JLY on 2000-03-25       
            system( "mv -f $Htgroup_dir/$groupName/$Webdir/index.html
$Htgroup_dir/$groupName/$Webdir/welcome.html");
        }

-----------------------------------------------------------------------
The following changes were also made to /etc/httpd/conf/srm.conf

**I added the 'welcome.html' at the end of the DirectoryIndex line **
-----------------------------------------------------------------------

# DirectoryIndex: Name of the file or files to use as a pre-written HTML
# directory index.  Separate multiple entries with spaces.

DirectoryIndex index.html index.htm index.shtml default.htm home.html
home.htm welcome.html

-----------------------------------------------------------------------

Does anyone know of any problems this change could cause? Everything seems
to be working the same on the surface.  I am also considering using this
same method to create symlinks for clients to 
use our SSL certificate.  Please advise with any info.

-Jason L. Youmans
-Webmaster
-Sage Web Design
-webmaster@xxxxxxxxxxxxxxxxx