How iamsayanmanna/content-management-system works
PenSpace is a web-based CMS for discovering published stories and authoring and managing posts. Its main workflow runs from the home page into author registration or sign-in, then the dashboard and post editor; the frontend services call PHP endpoints, which use session checks and MySQL-backed data. The repository also contains public feature, template, pricing, and resource pages, plus profile management, uploads, and newsletter handling. The README describes the project as in progress, so some capabilities visible in the tree are not confirmed as complete.
Main entry points: AuthorDashboard.jsx Post dashboard · HomePage.jsx Home and reading · authService.js Auth service · App.jsx Route shell
Components 23
Web application
- Route shell
frontend/src/App.jsx - Home and reading
frontend/src/HomePage.jsx - Features page
frontend/src/pages/FeaturesPage.jsx - Templates page
frontend/src/pages/TemplatesPage.jsx - Pricing page
frontend/src/pages/PricingPage.jsx - Resources page
frontend/src/pages/ResourcesPage.jsx
Author workspace
- Author sign-in
frontend/src/pages/AuthorLogin.jsx - Author registration
frontend/src/pages/AuthorRegister.jsx - Post dashboard
frontend/src/pages/AuthorDashboard.jsx - Author profile
frontend/src/pages/AuthorProfile.jsx - Post editor
frontend/src/pages/CreatePost.jsx - Rich text editor
frontend/src/pages/RichTextEditor.jsx - Auth service
frontend/src/services/authService.js - Post service
frontend/src/services/postService.js
PHP API
- Account endpoints
backend/api - Post endpoint
backend/api/posts.php - Profile and uploads
backend/api - Newsletter endpoint
backend/api/newsletter.php - Session checks
backend/session.php - Payment config
backend/config/payment.php
Persistence
- MySQL database
backend/config/database.php
Other components
- Visitor
- Author
Connections 30
- Visitor → Home and reading: browses
- Author → Author sign-in: signs in
- Route shell → Home and reading: routes to
frontend/src/App.jsx - Route shell → Features page: routes to
frontend/src/App.jsx - Route shell → Templates page: routes to
frontend/src/App.jsx - Route shell → Pricing page: routes to
frontend/src/App.jsx - Route shell → Resources page: routes to
frontend/src/App.jsx - Home and reading → Author sign-in: renders
frontend/src/HomePage.jsx - Home and reading → Author registration: renders
frontend/src/HomePage.jsx - Home and reading → Post dashboard: renders
frontend/src/HomePage.jsx - Home and reading → Post service: loads posts
frontend/src/HomePage.jsx - Author sign-in → Auth service: authenticates via
frontend/src/pages/AuthorLogin.jsx - Author registration → Auth service: registers via
frontend/src/pages/AuthorRegister.jsx - Post dashboard → Auth service: checks session
frontend/src/pages/AuthorDashboard.jsx - Post dashboard → Auth service: logs out via
frontend/src/pages/AuthorDashboard.jsx - Post dashboard → Post service: manages posts
frontend/src/pages/AuthorDashboard.jsx - Post dashboard → Author profile: renders
frontend/src/pages/AuthorDashboard.jsx - Post dashboard → Post editor: renders
frontend/src/pages/AuthorDashboard.jsx - Author profile → Auth service: updates account
frontend/src/pages/AuthorProfile.jsx - Post editor → Post service: saves posts
frontend/src/pages/CreatePost.jsx - Post editor → Rich text editor: uses editor
frontend/src/pages/CreatePost.jsx - Auth service → Account endpoints: sends requests
frontend/src/services/authService.js - Post service → Post endpoint: sends requests
frontend/src/services/postService.js - Account endpoints → Session checks: checks session
backend/api/auth.php - Account endpoints → MySQL database: queries authors
backend/api/auth.php - Post endpoint → Session checks: checks session
backend/api/posts.php - Post endpoint → MySQL database: accesses posts
backend/api/posts.php - Profile and uploads → Session checks: checks session
backend/api/update-profile.php - Profile and uploads → MySQL database: accesses accounts
backend/api/update-profile.php - Newsletter endpoint → MySQL database: stores signup
backend/api/newsletter.php