Hi
How can I add a .htaccess to any Syntax definition file? Under configure -> Document classes I have already add the file "*.htaccess".
If I renamed .htaccess to text.htaccess, the Syntax is highlighted. But in the right file .htaccess it doesn't work.
Greetings
Lost
Syntax definition file for .htaccess?
Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard
-
- Posts: 39
- Joined: Fri Apr 22, 2005 8:15 am
- Location: N. Ireland
- Contact:
I think this might be a Windoze issue more than a TP issue.
I have .htaccess files that I have FTPed from websites, but I can't rename a file to .htaccess in Windoze - it simply won't allow me.
The problem comes from the fact that the OS uses file extensions to recognise filetypes whereas *NIX (including Macs) looks at the file and works it out.
I think
I have .htaccess files that I have FTPed from websites, but I can't rename a file to .htaccess in Windoze - it simply won't allow me.
The problem comes from the fact that the OS uses file extensions to recognise filetypes whereas *NIX (including Macs) looks at the file and works it out.
I think
It should work if you use the commandline. (Start->run->"cmd") Just type "ren [filename].[extension] .htaccess". Notepad can save files as .htaccess, too.PeteTheBloke wrote:I have .htaccess files that I have FTPed from websites, but I can't rename a file to .htaccess in Windoze - it simply won't allow me.
By the way: I tried syntax highlighting for .htaccess files and it works perfectly.
Are you _sure_, that you added ".htaccess" _without_ the "*"? Because this sounds like you did not:lost wrote:Under configure -> Document classes I have already add the file "*.htaccess".
lost wrote:If I renamed .htaccess to text.htaccess, the Syntax is highlighted.
Yes, I'm sure that I have only .htaccess without the * (I know, I had written in my first post with * )BenjaminB wrote:Are you _sure_, that you added ".htaccess" _without_ the "*"? Because this sounds like you did not:
I use the Syntax definition file "php-js-css-html.syn". In this file, I have added "RewriteRule", but nothing happens in the .htaccess. Only http-Links are blue.
Please open that syntax file.
What does it say in the first few lines?
Is there a
HTML = 1
?
If so, syntax coloring does only take place between < and > as far as I know (you could verify that by putting <RewriteRules> for a test in your file)
I do not understand why you chose a syntax file that is for html + css + php + js for something totally unrelated like Apache configuration - why not use one of the Apache syntax files from http://www.textpad.com/add-ons/syna2g.html ?
What does it say in the first few lines?
Is there a
HTML = 1
?
If so, syntax coloring does only take place between < and > as far as I know (you could verify that by putting <RewriteRules> for a test in your file)
I do not understand why you chose a syntax file that is for html + css + php + js for something totally unrelated like Apache configuration - why not use one of the Apache syntax files from http://www.textpad.com/add-ons/syna2g.html ?
Check if you have "*." as a wildcard associated with another document class (I think the Text class has this by default).
If you remove this association, Textpad seems to allow other document classes to have members like ".htaccess" where the filename starts with a dot. Otherwise, they are all grabbed by the Text class.
If you remove this association, Textpad seems to allow other document classes to have members like ".htaccess" where the filename starts with a dot. Otherwise, they are all grabbed by the Text class.