Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2007-02-01 15:09:22

canvasd
New Member
Registered: 2007-02-01
Posts: 6

can't see .htaccess...help!

I installed textpattern from OSX with transmit, and I never saw a .htaccess file. Now my clean URLs aren’t working, and I suspect it’s because the .htaccess file is gone…

Can anyone please copy what I’m supposed to have in there? Do I then save it as plain text?

Thanks!
kate wheeler

Offline

#2 2007-02-01 15:18:47

sthmtc
Member
From: CGN, GER
Registered: 2005-01-17
Posts: 586
Website

Re: can't see .htaccess...help!

transmit > view > show invisible files

Offline

#3 2007-02-01 15:36:42

canvasd
New Member
Registered: 2007-02-01
Posts: 6

Re: can't see .htaccess...help!

Thanks!

I now see a .htaccess file in the root folder of my site (where textpattern’s index.php is).

I’m on apache at site5… what do I need to add to get clean URL’s to work?

Offline

#4 2007-02-01 15:56:52

sthmtc
Member
From: CGN, GER
Registered: 2005-01-17
Posts: 586
Website

Re: can't see .htaccess...help!

in most situations it should work right out of the box, if not see this faq entry

Offline

#5 2007-02-01 16:09:56

canvasd
New Member
Registered: 2007-02-01
Posts: 6

Re: can't see .htaccess...help!

The problem is that in the installation ‘out of the box’ I can’t see the .htaccess in OS x… I downloaded the latest build and dragged it to my site’s root, but I’m not sure if the included .htaccess went in or not —

There is a htaccess file, as I said, in the root folder of my site, but when I open it through transmit in Text Edit or Dreamweaver, I see a completely blank file.

Does anyone have the original 4.0.4 install’s htaccess that I could copy into a txt file and re-upload?

And also, would it go in the root (public_html) folder, which is the one with index.php, or would it go in the /textpattern folder, the one with the php includes?

Thanks so much for your help! I’m sheepish; I don’t know anything about .htaccess files.

And now I am worried that I have to chmod something so I don’t get hacked… if there is no coded .htaccess does it mean I’m wide open?

Any Mac OS X users out there remember how to show hidden files?

Offline

#6 2007-02-01 16:20:41

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,349
Website GitHub Mastodon Twitter

Re: can't see .htaccess...help!

canvasd wrote:

The problem is that in the installation ‘out of the box’ I can’t see the .htaccess in OS x… I downloaded the latest build and dragged it to my site’s root, but I’m not sure if the included .htaccess went in or not —

There is a htaccess file, as I said, in the root folder of my site, but when I open it through transmit in Text Edit or Dreamweaver, I see a completely blank file.

Does anyone have the original 4.0.4 install’s htaccess that I could copy into a txt file and re-upload?

If you have transmot open it with transmit. Control click on the file and choose open with transmit. Textedit or dreamweaver can not ‘see’ it. Consider changing to BBEdit or textmate

And also, would it go in the root (public_html) folder, which is the one with index.php, or would it go in the /textpattern folder, the one with the php includes?

It should reside in the same folder as the textpattern folder (not in it)

Any Mac OS X users out there remember how to show hidden files?

It is not advisable as you will be littered with all the invisible files mac osX is producing. My suggestion would be to move to applications like bbedit or textmate which see all files starting with a dot…


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Online

#7 2007-02-01 16:35:19

canvasd
New Member
Registered: 2007-02-01
Posts: 6

Re: can't see .htaccess...help!

Thanks very much I’ll try to get my hands on a copy of TextMate… I’ll update just in case any other Mac-ies are having the same problem!

Offline

#8 2007-02-01 17:34:06

canvasd
New Member
Registered: 2007-02-01
Posts: 6

Re: can't see .htaccess...help!

Well, now thanks to TextMate I’ve got my .htaccess file visible and have uncommented the things at the top, but am still getting an error on clean urls in diagnostics:

Textpattern version: 4.0.4 (r1956)
Last Update: 2007-01-18 00:02:34/2007-01-18 00:02:34
Document root: /home/elixircc/public_html
$path_to_site: /home/elixircc/public_html
Textpattern path: /home/elixircc/public_html/textpattern
Permanent link mode: section_id_title
Temporary directory path: /home/elixircc/public_html/textpattern/tmp
Site URL: www.elixir.cc
PHP version: 4.4.4
Server Local Time: 2007-02-01 12:31:13
MySQL: 4.1.21-standard
Locale: en_GB.UTF-8
Server: Apache/1.3.37 (Unix) mod_fastcgi/2.4.2 mod_gzip/1.3.26.1a mod_auth_passthrough/1.8 mod_log_bytes/1.2 mod_bwlimited/1.4 FrontPage/5.0.2.2635.SR1.2 mod_ssl/2.8.28 OpenSSL/0.9.7a PHP-CGI/0.1b
PHP Server API: cgi
RFC 2616 headers:
Server OS: Linux 2.6.9-42.0.3.ELsmp
Active plugins: smd_slimbox-0.11, zem_nav-0.4, zem_ir-0.5, an7_img-0.3

Pre-flight check:
————————————
Clean URL test failed.
————————————

.htaccess file contents:
————————————
DirectoryIndex index.php index.html
Options +FollowSymLinks
RewriteBase /relative/web/path/

<IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{REQUEST_FILENAME} -f [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule ^(.+) – [PT,L]

RewriteRule ^(.*) index.php </IfModule>

#php_value register_globals 0

————————————

Offline

#9 2007-02-01 17:40:53

canvasd
New Member
Registered: 2007-02-01
Posts: 6

Re: can't see .htaccess...help!

SUCCESS!

After some trial and error, I’ve gotten it to work — now I can go to article names, and no 500 errors, and oh my. It’s lovely. All I had to do was change

RewriteBase/relative/web/path

to:

RewriteBase /

I use Site5 hosting — if anyone else is curious, here’s what I have for .htaccess:

.htaccess file contents:
————————————
#DirectoryIndex index.php index.html
#Options +FollowSymLinks
#RewriteBase /relative/web/path/
RewriteBase /
<IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{REQUEST_FILENAME} -f [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule ^(.+) – [PT,L]

RewriteRule ^(.*) index.php </IfModule>

#php_value register_globals 0
—————————————-

And I know I left the commended stuff in there — but it makes me feel safe. ;-)

Thanks to everyone for their help!

Offline

Board footer

Powered by FluxBB