I wrote before about configuring Emacs to ease development in Ruby and Rails. But that is just a small part of the web-developer community out there.
Most websites out there still use PHP for their daily dose of web-development. In order to get the most out of Emacs in this situations there are a couple of modes that becomes a must-have:
- Tramp mode
- TRAMP uses remote shells to access files on remote servers. For instance opening a file using the following command C-x C-f /192.168.1.2:public_html/test.php will actually ask you for a password on 192.168.1.2 (if necessary) and will utilize ssh/scp to retrieve the test.php file. Any changes you perform on the file are stored directly on the server.
- nXhtml mode
- nXhtml mode is an extension on nxml-mode which allows you to edit xhtml files interleaved with other code fragments, like CSS, Javascript and PHP. Through the use of multiple major modes (MuMaMo) it makes the mode associated with each code fragment the major mode when editing that particular area so you can utilize the full power of those modes, for instance CSS’s attribute expansion.
Also the ability to edit XHTML fragments with full validation becomes extremely useful when writing blog posts
The nXhtml website has some great screenshots.
- Mewde
- I personally have not tried this mode yet, however judging from the website it promises great power and usability to the web-developer so I did not want to leave it out. If you have used Mewde, please let me know how you liked it.
- Snippet
- Also utilized in the Ruby modes, snippet allows you to define commonly used structures and utilize them as abbreviations, much like the TextMate snippets work, a must have module for any developer really.
These are but a few modes that make my life easier when doing web-development. If you know of more, then please leave a comment below.
2 Comments
Do we have a snippet for java and xml/html? i tried the snippet in the ruby on rails, it’s really cool, and if we can have the same snippet for the java and xml/html, just like the TextMate do, that’ll be really great!
umm, I currently have no snippets for java funnily enough….
I will start making some for the stuff I use daily… if you also have some we can make them available as a package for others to utilize…
Arjen