[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
About: Re: Emacs and ASP major mode
From: |
Guillaume Cottenceau |
Subject: |
About: Re: Emacs and ASP major mode |
Date: |
12 Mar 2004 15:48:13 +0100 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 |
Hi,
I was looking for an asp-mode for Emacs. I've read the message by
"Jeffery B. Rancier" on Mon, 24 Feb 2003 17:23:27 -0500 who
suggested to use the visual-basic mode. I just wanted to share
with you something slightly better (I hope) that I'm using.
The asp-mode I'm using is based on using html-mode. If you don't
have it, google and download it.
Basically, it switches between the visual-basic-mode for parts
containing scriptlets, and html-mode for html. I've also added
the use of the java-mode when "<script" is encountered - however,
I'm no asp/html expert thus I don't know if we can safely assume
that stuff after "<script" is always javascript. Here's what I've
added in my .emacs to declare the asp-mode:
(defun asp-mode () (interactive)
(multi-mode 1
'html-mode
'("<%" visual-basic-mode)
'("<script" java-mode)
'("</script" html-mode)
'("%>" html-mode)))
Happy about it, I'm now switching to something similar for
editing PHP:
(defun gcphp-mode () (interactive)
(multi-mode 1
'html-mode
'("<?php" php-mode)
'("<?" php-mode)
'("<script" java-mode)
'("</script" html-mode)
'("?>" html-mode)))
See you.
--
Guillaume Cottenceau
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- About: Re: Emacs and ASP major mode,
Guillaume Cottenceau <=