Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#49 2005-11-10 08:13:21

darrepac
Member
Registered: 2005-09-26
Posts: 64
Website

Re: Posts Via Email

Ok it’s time to start the thing… I am not a coder but I could start by proposing a first draft of format for the email message.
“=>” is explanation of above line if needed

Email :
whatever pop accessible email

Subject of the email:
!!!Title of the article
=>”!!!” should be user configurable code to detect Txp email from others (spam for example)

Body of the message:
***mandatory parameters***

Login
=>name of the publisher, he should have the necessary privilege
Password
=>Check password of the publisher, could be remove if no such high security is needed. If keeped, the email should be deleted by the plugin itself in order to not be able for anyone to read it and so read the password
Section name
Category1 name

***Article***

START ART
Article
=>article could be written directly in html with inline photos.
END ART

***Optional parameters***

START EXC
Excerpt
END EXC
Category2 name
Post date
=>in YYYYMMDDHHMMSS (for example), date of the email is default (not the date when the email is downloaded)
Message Status
=>sticky, live,… live is default

Here it is. For the techinical side, I do not know the xml-rpc interface. But from what I have seen on other CMS, an interesting idea to check email was to do it each time a person load the website. It avoids to need particular tools on server side, like cron or to ask external tools like webcron. Each time someone go to your pages, a small script check the email adress….

Here is what I can do to see this feature comes true…. And I am sure, it is really needed!
Some could also check inside other CMS to see how it is handled, like easymoblog…

Pascal

Offline

#50 2005-11-14 22:44:00

alannie
Member
From: Minnesota, USA
Registered: 2005-09-15
Posts: 150

Re: Posts Via Email

Just wanted to point out a few more reasons for this feature, beyond simple convenience:

1) Some mobile web browsers mangle the Textpattern interface. My T-mobile Sidekick shows an article text field that is only 1-3 characters wide (!!).

2) Mobile web browsers tend to be SLOW. Sending email is a lot faster.

3) Textpattern’s interface isn’t accessible to some users. A friend of mine is deafblind (meaning, he’s blind and can’t use voice screenreaders) and he has a hard time with any online form that doesn’t have all elements aligned with the left margin. He looks at the screen very close up and so he sees only a small part of it at once. Imagine looking at a screen through a small cardboard tube and how easy it would be to get “lost” on the page. For people like him, using their own trusty and familiar email client would be a much easier way to post.

I think what Pascal (darrepac) posted is a great start, and I’d like to contribute an example. Backpack has a system for posting notes, to-do items, etc via email. http://backpackit.com/weblog/archives/tips_tricks/pages_adding_content_to_a_page_via_email.php

Backpack determines the type of item to post by looking at the first word in the email’s subject line. A note, for example, has a subject that looks like “note: Title of Note”.

Perhaps something similar could be done with the subject line of an email, with Textpattern section names. Example: “news: My First Emailed Article” would create a posting in the news section with the title of “My First Emailed Article”.

I know there are other parameters to figure out here but this is a start. :)

Last edited by alannie (2005-11-14 22:48:02)

Offline

#51 2005-11-22 15:35:42

darrepac
Member
Registered: 2005-09-26
Posts: 64
Website

Re: Posts Via Email

Yeah! shame that real coder do not see interest in this feature… do not see why? It is really annoying to me to no have it and clearly when I have jumped to textpattern I was thinking it was in as it sounds quite basic feature now…

Pascal

Offline

#52 2006-01-12 21:45:20

powerwade
New Member
From: Budapest / HUNGARY
Registered: 2005-12-13
Posts: 4
Website

Re: Posts Via Email

Hi guys,

Today I wrote a working version of my python script that can fetch email from any pop3 account and insert it into a textpattern based blog. Unfortunately I had no time to write the wap interface, but I’ll do it soon.

A little and quick & dirty howto:

- Send an email to a separated pop3 account with a subject like this:
“category_name This is my first post with this shit”.
- This script should be run from crontab – for example every 10 minutes, and makes a post into your blog and deletes the email from server
- If there is more than 1 message or no message in your pop3 account the script won’t run (you should dedicate that email address for this)
- At the moment the script can’t check the senders email (allowed_from variable is exists but not used)

requirements for running this script: linux, python 2.3.5 (with mysql support), textpattern

download the script from: here

Please note that I’m not a real programmer and this in only a pre-beta version and I did it for myself. Feel free to use and modify. The source is uncommented and maybe there are some unused variables.

Comments and ideas are welcomed.

Offline

#53 2006-01-13 21:11:37

powerwade
New Member
From: Budapest / HUNGARY
Registered: 2005-12-13
Posts: 4
Website

Re: Posts Via Email

unfortunately the server will be down for 3 days :(

Offline

#54 2006-01-18 09:20:53

powerwade
New Member
From: Budapest / HUNGARY
Registered: 2005-12-13
Posts: 4
Website

Re: Posts Via Email

the server is up again, so if you want to “test” my lil script just do it :)

Offline

#55 2006-06-05 15:55:13

jonhicks
Member
From: Oxfordshire UK
Registered: 2004-03-22
Posts: 256
Website

Re: Posts Via Email

Thanks – I hope to try this out soon!

BTW: Does the recent XML-RPC addition to TXP make any difference to implementing this?


Cheers,
Jon VC#9

Offline

Board footer

Powered by FluxBB