From: Jeff D. <da...@da...> - 2001-08-28 18:47:33
|
On Aug 28, 2001, Steve Wainstead sai> On Tue, 28 Aug 2001, Reini Urban wrote: > > I tried this .emacs file on netbsd and red hat linux, and it flat out does > not work. So something is missing either from php-mode-099 or the .emacs > file. You're defining the php-mode-hook as a function. That looks wrong. php-mode-hook is a variable which contains a list of functions to run. (Note also that in your code, indent-tabs-mode always gets set true, since (buffer-file-name) can't match both "\.php$" and "\.phtml$".) (I've also added a call to (c-set-mode) to ensure the correct defaults.) Try this (untested, of course): ... (defun my-php-mode-hook-func () (c-set-mode "gnu") (setq tab-width 4 c-basic-offset 4 c-hanging-comment-ender-p nil indent-tabs-mode nil)) (add-hook 'php-mode-hook 'my-php-mode-hook-func) ... Jeff. |