oregister/
├── oregister.php # Plugin bootstrap
├── uninstall.php # Cleanup on delete
│
├── includes/
│ ├── Core/
│ │ ├── Autoloader.php # PSR-4 class autoloader
│ │ ├── Plugin.php # Plugin singleton + boot
│ │ ├── DB.php # Table creation SQL
│ │ └── Installer.php # Activation: tables + pages + defaults
│ │
│ ├── Admin/
│ │ ├── AdminMenu.php # WP admin menu + all handlers
│ │ └── Controllers/
│ │ ├── UserController.php # User list + single user view
│ │ ├── BadgeController.php # Badge CRUD
│ │ ├── GamificationController.php # XP actions + levels + naming
│ │ ├── EmailController.php # Email template editor
│ │ └── SettingsController.php # All plugin settings
│ │
│ ├── Auth/
│ │ ├── AuthHandler.php # Login/logout AJAX + redirect
│ │ ├── MagicLink.php # Passwordless magic link
│ │ ├── TwoFactor.php # TOTP + email code 2FA
│ │ ├── BruteForce.php # Rate limiting + lockout
│ │ ├── SessionManager.php # Session tracking table
│ │ └── SocialAuth.php # Google, GitHub, LinkedIn OAuth
│ │
│ ├── Registration/
│ │ ├── RegistrationHandler.php # AJAX register + captcha + approval
│ │ └── FieldBuilder.php # Configurable registration fields
│ │
│ ├── Profile/
│ │ ├── ProfileController.php # Email verify + profile save + avatar
│ │ └── ProfileRepository.php # Profile data + completeness + privacy
│ │
│ ├── Gamification/
│ │ ├── XPEngine.php # Award XP + activity log + level sync
│ │ ├── BadgeEngine.php # Award badges + condition checking
│ │ ├── StreakEngine.php # Login streak tracking
│ │ ├── LevelEngine.php # Level calculation + progress
│ │ └── Leaderboard.php # Cached leaderboard query + shortcode render
│ │
│ ├── Notifications/
│ │ ├── NotificationEngine.php # In-plugin notifications (bell)
│ │ └── EmailNotifier.php # Transactional email send + templates
│ │
│ ├── UtilityBar/
│ │ └── UtilityBar.php # Frontend sticky bar (XP, streak, notifs, dropdown)
│ │
│ ├── Social/
│ │ ├── FollowSystem.php # Follow/unfollow + counts
│ │ └── Messaging.php # Direct user-to-user messaging
│ │
│ └── API/
│ └── RestController.php # /wp-json/oregister/v1/ endpoints
│
├── templates/
│ ├── admin/
│ │ ├── layout-header.php # Shared admin shell (brand bar + nav)
│ │ ├── users.php # User list with stats + filters
│ │ ├── user-view.php # Single user: profile, badges, activity, sessions
│ │ ├── badges.php # Badge list
│ │ ├── badge-edit.php # Badge create/edit form
│ │ ├── gamification.php # XP actions, levels, naming
│ │ ├── email-templates.php # Per-template email editor
│ │ └── settings.php # All settings grouped by section
│ └── frontend/
│ ├── sign-in.php # Login form (social + email + magic link + 2FA)
│ ├── create-account.php # Registration form
│ ├── forgot-password.php # Password reset request
│ ├── my-profile.php # Public profile page
│ └── my-dashboard.php # Logged-in dashboard
│
└── assets/
├── css/
│ ├── or-admin-v1.css # Admin UI (dark/light, matching OMailer)
│ └── or-frontend-v1.css # Frontend forms + utility bar + profile
└── js/
├── or-admin-v1.js # Admin interactions
└── or-frontend-v1.js # Frontend auth, profile, utility bar
Reference
