LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-09-2004, 11:25 PM   #1
Zaius
Member
 
Registered: Jan 2004
Location: Canada
Posts: 68

Rep: Reputation: 15
saving changes to apache2/conf/httpd.conf file


i've just installed apache and i want to make a few changes to the httpd.conf file... who knew... but once opened with 'vi' i don't know how to save the changes i've made.. how do i do this?
 
Old 01-09-2004, 11:29 PM   #2
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 269Reputation: 269Reputation: 269
Several ways in fact.

In command mode (ESC) you can do:

:wq!

Stands for write and then quit

Or you can simply do a <Shift + ZZ>

Cheers.
 
Old 01-09-2004, 11:31 PM   #3
Kovacs
Member
 
Registered: Jul 2003
Distribution: FreeBSD 8.2 RELEASE
Posts: 607

Rep: Reputation: 32
To save the file press [ESCAPE] then :w [ENTER]
to save and quit :wq [ENTER]
to quit without saving :q! [ENTER]

(the colon is part of the command that you type in)

to go back to insert mode press I, to get back to command mode press escape

Last edited by Kovacs; 01-09-2004 at 11:32 PM.
 
Old 01-09-2004, 11:32 PM   #4
Kovacs
Member
 
Registered: Jul 2003
Distribution: FreeBSD 8.2 RELEASE
Posts: 607

Rep: Reputation: 32
Beat me to it trickykid
 
Old 01-09-2004, 11:32 PM   #5
alar
Member
 
Registered: Sep 2003
Location: Canada
Distribution: Fedora 30
Posts: 341

Rep: Reputation: 37
I would change the wording there trickykid

In command mode you can do:

Hit <esc> to take you out of edit mode then enter

:wq!

Stands for write and then quit

i always forget about the
<Shift + ZZ>

 
Old 01-09-2004, 11:44 PM   #6
Zaius
Member
 
Registered: Jan 2004
Location: Canada
Posts: 68

Original Poster
Rep: Reputation: 15
so.. <esc> gets me to the command prompt and then i type :wq! to save and quite

or within the VI i can just press <shift + z z> and it saves it and i continue on my marry way editng..
 
Old 01-09-2004, 11:45 PM   #7
alar
Member
 
Registered: Sep 2003
Location: Canada
Distribution: Fedora 30
Posts: 341

Rep: Reputation: 37
yup
did it work?

Last edited by alar; 01-10-2004 at 01:31 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
2 httpd.conf file, which one is being used? newlinuxnewbie Linux - General 2 11-27-2005 04:43 PM
Allow file upload in httpd.conf? @ngelot Linux - Newbie 2 05-13-2005 08:07 AM
Apache httpd.conf file?? matux Mandriva 2 01-28-2005 09:20 AM
httpd.conf & ssl.conf kevinm2 Linux - Security 12 08-31-2004 01:25 PM
httpd.conf File? HappyDude Linux - Software 3 08-16-2003 12:38 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:52 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration