Skip to content

Repository files navigation

Earthly Eats

Earthly Eats is a PHP and MySQL wellness platform with separate user and admin areas. It covers account management, BMI tracking, personalized diet and yoga planning, shopping and order flow, payment handling, reports, analytics, and Chatbase-assisted support on the user dashboard when configured.

Stack

  • PHP with PDO/MySQL
  • Plain JavaScript
  • CSS with shared styles in css/
  • Bundled vendor assets:
    • vendor/phpqrcode
    • vendor/chart.umd.min.js
    • vendor/jspdf.umd.min.js

Project Structure

  • index.php, privacy.php, terms.php: public pages
  • config.php: bootstrap, security headers, session handling, env-backed config, shared helpers
  • user/: user authentication, dashboard, plans, orders, classes, payment, profile
  • user/api/: authenticated user endpoints
  • admin/: admin authentication, dashboard, catalog management, orders, reports, analytics
  • admin/api/: authenticated admin endpoints
  • css/, js/, images/: shared frontend assets
  • temp/: runtime-generated QR codes and rate-limit storage
  • uploads/avatars/: uploaded user avatars
  • database.infinityfree.sql: schema and seed data

Features

  • User signup, signin, profile management, and session protection
  • Admin login and admin activity logging
  • BMI and BMR calculation with saved user metrics
  • Diet template management and generated 7-day diet plans
  • Yoga template management, scheduled classes, and generated yoga plans
  • Shopping list, order placement, payment flows, and order tracking
  • Reports, analytics, visitor counting, and referral support
  • Chatbase integration on the user dashboard when configured

Local Setup

  1. Copy .env.example to .env.
  2. Set your database credentials and application values in .env.
  3. Create a MySQL database.
  4. Import database.infinityfree.sql.
  5. Make sure PHP can write to:
    • temp/qrcodes/
    • temp/security/
    • uploads/avatars/
  6. Serve the project from your PHP web root.

Example local URL:

http://localhost/website

If you host the project in a subdirectory, set APP_URL to that full base URL.

Environment Variables

The app reads configuration from .env and falls back to safe repository defaults.

Required for real use:

  • DB_HOST
  • DB_NAME
  • DB_USER
  • DB_PASS

Common optional settings:

  • APP_URL: explicit base URL
  • APP_HOST: trusted host override
  • APP_ENV: development or production
  • EE_FORCE_HTTPS: 1 in production behind HTTPS, otherwise 0
  • CHATBASE_CHATBOT_ID: enables the dashboard chatbot
  • SUPPORT_EMAIL: replaces hardcoded support/contact email addresses
  • UPI_PAYEE_ID: UPI receiver ID shown on the payment page
  • UPI_PAYEE_NAME: UPI receiver display name

Database Seed Notes

The SQL file includes a demo admin account for first login:

  • Email: admin@example.com
  • Password: ChangeMe123!

Change this immediately after import.

GitHub Readiness Notes

This repository is prepared so environment secrets and runtime files stay out of Git:

  • .env is ignored
  • generated avatar uploads are ignored
  • generated QR images are ignored
  • rate-limit JSON files are ignored

Keep production secrets only in .env or server environment variables.

Suggested First Git Commands

git init
git add .
git status
git commit -m "Initial commit"

Then create a GitHub repository and connect it:

git remote add origin <your-github-repo-url>
git branch -M main
git push -u origin main

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages