fossasia/wpfa-mailconnect
关于
将电子邮件连接功能集成到网站的 WordPress 插件
网站与应用开发可以做什么
- WordPress-compatible plugin bootstrap (wpfa-mailconnect.php)
- Standard directories for admin UI, public hooks, and shared includes
- Translation domain and language folder
- uninstall.php stub to keep data cleanup explicit
实测星标增长
- 24小时
- 0
- 7天
- +3
- 15天
- +2
- 1个月
- 正在收集历史
各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。
README.md
原文WPFA Mail Connect
A WordPress plugin scaffold by FOSSASIA to integrate email connectivity into sites and other WPFA plugins.
It ships with a standard, maintainable structure (admin/, includes/, public/, languages/) and an uninstall routine, ready for adding SMTP/API providers, settings screens, and helper functions.
Licensed under Apache-2.0.
Current stable release: 1.0.0.
Features
Current repository status: minimal plugin skeleton prepared for adding mail connectivity features.
What’s included out of the box:
- WordPress-compatible plugin bootstrap (
wpfa-mailconnect.php) - Standard directories for admin UI, public hooks, and shared includes
- Translation domain and language folder
uninstall.phpstub to keep data cleanup explicit
Note: Provider integrations (SMTP/API), settings pages, and email helpers can be implemented inside the existing structure.
Requirements
- WordPress 6.0+ (recommended)
- PHP 7.4+ (PHP 8.x compatible recommended)
Install
Using Git (recommended for contributors)
From your WordPress root:
cd wp-content/plugins
git clone https://github.com/fossasia/wpfa-mailconnect.git
Manual (ZIP)
- Download the repository as ZIP.
- In the WordPress admin go to Plugins → Add New → Upload Plugin and select the ZIP.
Activate
Go to Plugins in the WP admin and activate WPFA MailConnect.
Configure
Once features are implemented, a settings page (e.g. under Settings → WPFA MailConnect) can expose:
- Connection method (SMTP / Provider API)
- Host / Port / Encryption
- Authentication (username/password or token)
- From address and name
- Test-email utility
The repository already contains
admin/for an options page scaffold. Hook your settings there.
Project structure
wpfa-mailconnect/
├─ admin/ # Admin screens, settings, assets
├─ includes/ # Core classes, loaders, helpers
├─ languages/ # .po/.mo translation files
├─ public/ # Public-facing hooks/assets
├─ index.php
├─ uninstall.php # Cleanup stub
└─ wpfa-mailconnect.php # Main plugin bootstrap
This layout follows common WordPress plugin practices and matches the current repository contents.
Localization (i18n)
- Text domain:
wpfa-mailconnect - Translation files live in
languages/. Add/update.po/.mofiles as usual.
Uninstall behavior
The repository includes uninstall.php. Extend it to remove plugin options and custom data on uninstall to keep sites clean.
Development
- Create feature classes in
includes/(e.g., loaders, mail adapters). - Register admin screens in
admin/(settings API, capability checks). - Add public hooks/assets in
public/(should you expose shortcodes or public forms). - Wire everything from
wpfa-mailconnect.php(activation/deactivation, loaders).
Suggested next tasks:
- Implement a
MailAdapterInterfaceand concrete adapters (SMTP, provider APIs) - Add a settings page with the WordPress Settings API
- Provide a Send Test Email action to verify connectivity
- Optionally, add a logging mechanism (WP_Logging or custom table) guarded by capability checks
- Write unit tests for adapters (mock transport)
Coding standards
- Follow WordPress PHP coding standards
- Escape output (
esc_html,esc_attr,wp_kses) and sanitize input (sanitize_text_field, etc.) - Use nonces and capability checks for all admin actions
- Prefix everything with
wpfa_mailconnect_orWPFA_MailConnect_to avoid collisions
Contributing
Contributions are welcome! Please:
- Fork the repository and create a feature branch
- Keep commits focused and add tests where possible
- Open a Pull Request with a clear description and screenshots of admin UI changes
License
Apache License 2.0. See LICENSE.txt.
探索相关项目
加载中…