Women in Technology

Hear us Roar

  Apache Web-Serving with Mac OS X, Part 4
Subject:   Can't create .htaccess file
Date:   2002-02-04 02:31:42
From:   markpalmer1

I'm following part 4 of the tutorial and find I can't create a file with the name .htaccess by saving from BBEdit - the save button is dimmed. If I save under another name and try to edit with the finder I am told that names begining with a dot "." are reserved for system use! Also trying to cp htaccess .htaccess in the command line just fails.

What am I missing here?


Full Threads Oldest First

Showing messages 1 through 3 of 3.

  • Morbus Iff photo Can't create .htaccess file
    2002-02-04 06:48:14  Morbus Iff | O'Reilly Author [View]

    You can't "cp htaccess .htaccess"? What sort of error message do you get? You're correct though - by default OS X doesn't let you create "dot files" from the Finder. There are ways around this (by turning on ShowDotFiles in your finder.plist).

    Have you tried creating and editing the .htaccess file within your Terminal only (like "pico .htaccess", editing within Pico, and then saving)?
    • Can't create .htaccess file
      2002-02-04 08:09:32  markpalmer1 [View]

      >> You can't "cp htaccess .htaccess"? What sort of error message do you get?

      I dont get any error, just a return to the prompt ls -l only list a file called htaccess!

      I then tried resaving as .htaccess using pico which works fine, although I did confuse myself for a while by doing ls -l without autheticating as su and of course I couldn't see anything, this I guess was my original problem.



      • Morbus Iff photo Can't create .htaccess file
        2002-02-04 10:57:53  Morbus Iff | O'Reilly Author [View]

        Ah yes, forgot to mention the most obvious. To see "dot files" in the Terminal, you need to do "ls -al", NOT "ls -l". The "-a" says "show all files, including dot files".