📋 Overview
The Email-to-Blog system allows you to create beautiful blog posts by simply sending an email to blogs@morsetrainerpro.com. The system automatically processes your email every 30 minutes and publishes it according to your specifications.
🚀 Quick Start
Basic Email Format
Subject: Your Amazing Blog Post Title
Body:
Attachments: Add 1 or more images (JPG, PNG, GIF, WEBP) - the first image becomes the featured image.
📝 Email Format Specification
Subject Line
The email subject becomes your blog post title:
You can also use pipes to separate title from additional info:
(Everything before the first | becomes the title)
Metadata Fields (Optional)
Add these fields at the beginning of your email body. Each field is optional:
Alternative Metadata Format
You can also wrap metadata in markers:
Or:
📷 Image Attachments
Featured Image
- Attach images (JPG, PNG, GIF, WEBP) to your email
- The first image automatically becomes the featured image
- Additional images are saved and available for future use
Supported Formats
- ✅ JPG/JPEG
- ✅ PNG
- ✅ GIF
- ✅ WEBP
File Naming
Images are automatically renamed with timestamps to prevent conflicts:
All images are saved to: /uploads/blog-images/
🎨 Content Formatting
Headings
Use hashtags for headings (Markdown-style):
Or use ALL CAPS on a single line (auto-converted to H2):
Paragraphs
Separate paragraphs with blank lines:
Line Breaks
Single line breaks within a paragraph are preserved:
Lists
Use standard formatting:
📧 Complete Email Examples
Example 1: Simple Published Post
To: blogs@morsetrainerpro.com
Subject: Getting Started with CW
Attachments: cw-diagram.jpg
Body:
Example 2: Scheduled Post
To: blogs@morsetrainerpro.com
Subject: Advanced CW Contest Techniques
Attachments: contest-setup.jpg
Body:
Example 3: Draft for Review
To: blogs@morsetrainerpro.com
Subject: Upcoming Morse Code Events 2025
Body:
⚙️ Configuration Setup
Environment Variables (.env file)
Add these to your .env file:
Gmail Setup (Recommended)
- Go to Gmail Settings and enable IMAP under "Forwarding and POP/IMAP"
- Go to Google Account Security
- Enable 2-Factor Authentication
- Create an App Password:
- Select "Mail" and your device
- Copy the generated password
- Use this password in
.envfile
❓ Troubleshooting
"Cannot connect to mailbox" Error
Solution:
- Verify IMAP is enabled in email settings
- Check firewall allows port 993
- Verify credentials in
.env - For Gmail, use App Password (not regular password)
"No blogger or admin user found" Error
Solution:
Make sure at least one user has blogger permissions:
Images Not Uploading
Solution:
- Check directory permissions:
chmod 755 /path/to/uploads/blog-images - Verify uploads directory exists
- Check disk space
PHP IMAP Extension Missing
Solution:
Install the IMAP extension:
🎯 Best Practices
Email Writing Tips
- Write clear subject lines - They become your titles
- Use metadata - Makes posts more discoverable
- Attach quality images - They enhance visual appeal
- Proofread before sending - No editing after email sent
- Use STATUS: draft - Review before publishing
Content Tips
- Break content into sections - Use headings
- Keep paragraphs short - Easier to read
- Add keywords - Helps with SEO
- Write compelling excerpts - Encourages clicks
- Schedule during peak times - Maximize engagement
Workflow Tips
- Draft in email app - Use rich text editor
- Save email templates - For consistent formatting
- Check logs regularly - Catch issues early
- Monitor blog analytics - See what works
- Back up regularly - Protect your content
📞 Support
For issues or questions:
- Check logs:
/logs/email-to-blog.log - Review this guide
- Contact: support@morsetrainerpro.com
🎉 Happy Blogging!
You're all set! Start sending emails and watch your blog grow automatically.
Remember: The system checks for new emails every 30 minutes, so your posts will appear within that timeframe.
Last Updated: January 2025
Morse Trainer Pro - Email-to-Blog System v1.0