All pastes #98568 Raw Edit

Anonymous

public text v1 · immutable
#98568 ·published 2006-07-24 16:47 UTC
rendered paste body
;;Modes
(global-font-lock-mode 1)

;;PHP Files
(autoload 'php-mode "~/.emacs.d/php-mode" "PHP editing mode" t)
(add-to-list 'auto-mode-alist '("\\.php\\'" . php-mode)) ;;Main PHP Files
(add-to-list 'auto-mode-alist '("\\.phps\\'" . php-mode));;PHP Source Files
;;(add-to-list 'php-mode 'pear-php-mode-hook)





;;SNIP




;;I need the following function to run when opening a .php file
(defun pear-php-mode-hook ()
  (setq tab-width 4
        c-basic-offset 4
        c-hanging-comment-ender-p nil
        indent-tabs-mode
  (not
    (and (string-match "/\\(PEAR\\|pear\\)/" (buffer-file-name))
      (string-match "\.php$" (buffer-file-name))))))