Re: [EMAIL PROTECTED] editing httpd.conf file through shell script

2008-06-20 Thread Agnello George
On 6/18/08, Mohit Anchlia <[EMAIL PROTECTED]> wrote: > > You can use head and tail commands in shell to do what you want to do. You > could do something like: > > x=`grep -n "DocumentRoot /websites/vodafone/web" httpd.conf` # gets the line > number > cat httpd.conf|head -$x > tmp.conf > echo "Add

Re: [EMAIL PROTECTED] editing httpd.conf file through shell script

2008-06-19 Thread Matus UHLAR - fantomas
On 18.06.08 19:09, Agnello George wrote: > i am trying to edit my httpd.comf file through a shell script .. (( > actually I trying to set up a control panel )) > now through a shell script i need to add mime type for domain > vodafone.com, i would need to add the following bellow "Doucm

Re: [EMAIL PROTECTED] editing httpd.conf file through shell script

2008-06-18 Thread Mohit Anchlia
You can use head and tail commands in shell to do what you want to do. You could do something like: x=`grep -n "DocumentRoot /websites/vodafone/web" httpd.conf` # gets the line number cat httpd.conf|head -$x > tmp.conf echo "AddType application/x-httpd-php .php" >> tmp.conf cat httpd.conf|tail +$x

Re: [EMAIL PROTECTED] editing httpd.conf file through shell script

2008-06-18 Thread Krist van Besien
On Wed, Jun 18, 2008 at 15:39, Agnello George <[EMAIL PROTECTED]> wrote: > now through a shell script i need to add mime type for domain vodafone.com > , i would need to add the following bellow "DoucmentRoot" > > AddType application/x-httpd-php .php > > AddType application/x-httpd-php-source .p

[EMAIL PROTECTED] editing httpd.conf file through shell script

2008-06-18 Thread Agnello George
hi i am trying to edit my httpd.comf file through a shell script .. (( actually I trying to set up a control panel )) my httpd.conf host directives for many domains , the file is something like this : ##START###rodney.com### http://192.168.0.244/>> Server