[wp-hackers] wp-mail major update
John B.Hewitt
blade at lansmash.com
Wed Jun 16 03:57:23 UTC 2004
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hiya guys
Started using Wordpress a few days ago and love the clean
look/design/code. But it got me thinking about photos, I love photos
but hate having to upload stuff and linking to it (CMS style). In fact
I'm so lazy, I decided to have a hack at wp-mail.php
What I ended up doing was replacing most of the code in wp-mail.php for
wordpress 1.2, didn't anticipate that when I first started but the
results are nice.
This hack is a 'drop in' replacement for the current wp-mail.php. It
uses pear as a mime compliant email 'decoder'. What's cool is that you
can attach images inline in your email messages and they'll be shown as
an image in your wordpress article. It does this by decoding the image
attachments and writing them to 'wp-photos' directory (not in default
wp install).
It has all the abilities of the current wp-mail.php plus:
- Allows image attachments (posts inline)
- Checks if user email address is in the database (otherwise discards
message)
- Allows other file attachments (zip's, exe's, etc)
- Fairly good cleaner for removing excessive line breaks
I'm planning on more updates, but would love to see this update
included in future wordpress releases. Would be happy to maintain it
to, I'm fairly sure it complies with most of the coding guidelines I've
read on the wordpress website.
To install you grab the zip file.
- - Drop the two files (wp-mail.php & mailmimedecode.php) into a
wordpress 1.2 root directory
- - Create the directories 'wp-photos' and 'wp-filez' in the wordpress
root directory(with writing permissions (probably 0777).
You can grab a copy here: http://blade.lansmash.com
Let me know what you guys think!
John B. Hewitt
blade.lansmash.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (Darwin)
iD8DBQFAz8UjnI3ieTedGU0RAjBfAJ9em8BY/3UuCK3VxMgjCgVMMbtiqACfVARP
a3yD/k1CaafLMMqBao1c/dU=
=e1SB
-----END PGP SIGNATURE-----
More information about the hackers
mailing list