Computer Magic
Software Design Just For You
 
 



Publish Via Email?!

Now here is a cool new feature. The WordPress software that I am using for my WebBlog supports submitting articles via Email. This is a first attempt, so if you aren’t reading this, it didn’t work. (revision: this is actually my 12th attempt… some debugging ensued on the mail import script, see below).

I am one of those guys that likes to get my hands dirty and do things the hard way.. as long as I can do it efficiently. I don’t use Front Page (shudder) to create web content, I open up a text editor on steroids and work with the HTML directly. It doesn’t mean that I won’t use a GUI tool if an acceptable one is available and appropriate for the situation (VStudio, DreamWeaver), but I need to be able to get down into the code and manipulate things via a programming language which generally doesn’t mix well with automated tools (except in VStudio!). I am the first one to use VB though for most applications as the RAD (Rapid Application Development) interface lets me draw the GUI with a mouse and cuts down your design time for the interface significantly.

Having said all this, when publishing a Blog, the last thing you want to do is fight with HTML. You simply want to write your meaningless article and be done. Using a setup like WordPress is just more efficient than creating static pages for each article (think about linking and archiving also!).

Adding the feature to let me send articles via email is another example of efficiency. By using Outlook, I don’t even have to log into the Blog software and I can take advantage of things like spell checking in Outlook. Over the next few years, you will see new advances in Information Management that will enhance your efficiency in new ways. Instead of trying to add new features in Word (most of which you don’t use now) you will see that it will be more interoperable with other technologies (did you know that MS Office documents can now use XML as its file format?). The idea is to eliminate some of the complexity of moving information around. Wouldn’t it be nice if you didn’t have to worry about things like zipping files and email attachments being rejected when you send a document? The industry is finally moving in a direction where users can be productive on a computer without having to be a certified tech.

Now, on to some certified tech stuff…. For those who want their own blog, the email processing script in WordPress has a few disadvantages. Because of the nature of the web, you have to go to a url to get it to process your emails. The best thing to do is setup a CRON job on your server to do this for you. Once the script runs though, it leaves some nasty formatting issues. It is actually not the scripts fault, but given the state of email clients, it should deal with things appropriately. Got to love open source! Check out the original software at http://wordpress.org.

A little background. When writing your email, you need to set your email client to create text only message. Any HTML messages sent to this tool will come out all messed up. I am sure it could be modified to accept this, but I am too busy to do it today, so I won’t. The next issue is that many/most email clients limit the size of your lines in your email messages. This is a holdover from the dark ages of computing, but is a very real issue. Your client doesn’t just wrap your writing for display, it actually puts real line feeds in your message before sending them out. Because of this, you end up with nasty line breaks in places where they don’t belong.

The solution? My modifications to the wp-mail.php file process the line feeds and tries to figure out which are your line feeds, and which are artificial line feeds injected by the email client. You can download my changes at https://www.cmagic.biz/wordpress/wp-mail.zip. Unzip this file and place it in your wordpress directory (yes to overwrite). It does a pretty good job.

Lastly, this also fixes an error you will get if you use the ‘ character in your article anywhere. I looked on the wordpress site for a place to submit the changes to the original author, but could not easily find a place/email and I am too lazy to register on yet another site. If he wants to include these changes into the main code branch, great, but I am too lazy to do the leg work today.

Don’t think that this is a poor product just because there is a bug or two. I have been impressed by its ability to offer such versatility and power while retaining the ease of use you would expect from a content management system. Way to go guys!

Ray Pulsipher

Owner

Computer Magic And Software Design

Comments are closed.


Home | My Blog | Products | Edumed | About Us | Portfolio | Services | Location | Contact Us | Embedded Python | College Courses | Quick Scan | Web Spy | EZ Auction | Web Hosting
This page has been viewed 829571 times.

Copyright © 2005 Computer Magic And Software Design
(360) 417-6844
computermagic@hotmail.com
computer magic