Skip to content

MWBMPartners/Go2My.Link

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

45 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ”— Go2My.Link

A comprehensive URL shortening web service by MWBM Partners Ltd (t/a MWservices).

Successor to the internal "MWlink" service β€” now expanded into a full-featured, multi-domain platform.


πŸ“‹ Overview

Go2My.Link is a URL shortening platform comprising three interconnected web properties:

Domain Component Purpose
🌐 go2my.link 🏠 Main Website (A) Public face, sign-up, short link creation
πŸ”§ admin.go2my.link πŸ“Š Admin Dashboard (A) User/org dashboard, link management, settings
πŸ”— g2my.link πŸ”€ Redirect Engine (B) Default domain for shortened URLs
πŸ“„ lnks.page πŸ“‘ LinksPage (C) LinkTree-like customisable link listing pages

πŸš€ Features

βœ… Implemented

  • πŸ”— URL Shortening β€” Random short codes, anonymous + authenticated creation, copy-to-clipboard
  • πŸ”€ Redirect Engine β€” Fast redirect resolution via stored procedure, DNT respect, destination validation
  • πŸ”‘ Authentication β€” Registration, login (with adaptive CAPTCHA), logout, email verification, password reset
  • πŸ” Session Management β€” Database-backed sessions, multi-device tracking, remote revoke
  • πŸ–₯️ Admin Dashboard β€” Link CRUD (create/edit/list/delete), profile settings, password change, session management
  • 🎨 Dark/Light Mode β€” Bootstrap 5.3 colour modes, auto/light/dark toggle, FOUC prevention
  • β™Ώ Accessibility β€” WCAG 2.1 AA compliant, screen reader support, skip-to-content, ARIA live regions
  • 🌍 i18n β€” Translation-ready __() function, locale detection, interim Google Translate widget
  • πŸ”’ Security β€” Argon2id hashing, SHA-256 token storage, CSRF protection, account lockout, rate limiting
  • πŸ“§ Transactional Email β€” Multipart MIME (text/plain + AMP + HTML), dark mode, preheader text, modern headers
  • 🚨 Breach Response β€” GlobalAdmin mass credential reset, session revocation, ENCRYPTION_SALT rotation, batch notification emails
  • πŸ“ Static Pages β€” About, Features, Pricing, Contact (with email), Legal (Terms, Privacy, Cookies)
  • πŸ” URL Info β€” Public short code lookup with masked destination, status badges
  • πŸ“ JSON Schema Validation β€” Schema definitions (draft 2020-12) with pure-PHP validator for API responses and database JSON
  • 🏒 Organisations β€” Create/manage organisations, member invitations (email with tokenised accept), role enforcement, custom domain DNS verification, short domain management
  • πŸ›‘οΈ DNT/GPC β€” Do Not Track & Global Privacy Control detection, CSP headers, HSTS, custom error pages
  • πŸͺ Cookie Consent β€” GDPR opt-in/opt-out jurisdiction detection, consent banner, preferences modal, consent API
  • πŸ” Data Rights β€” GDPR Article 15-22 compliance: data export, deletion requests, anonymisation, privacy dashboard
  • πŸ“œ Legal Documents β€” Terms of Use, Privacy Policy, Cookie Policy, Copyright Notice, Acceptable Use Policy
  • πŸ“± PWA β€” Progressive Web App manifests and service workers for all 3 web properties
  • β™Ώ WCAG 2.1 AA β€” Full accessibility audit with 23+ files fixed: landmarks, ARIA, contrast, headings, forms
  • πŸ”’ Pre-Release Audit β€” Security hardening (XSS, SQLi, open redirect), WCAG refinements, W3C compliance, email template contrast
  • 🎨 Logo Integration β€” SVG + PNG <picture> fallback in navbar, footer, and all landing pages
  • 🌐 Landing Pages β€” Auto-refresh, countdown ring, dark mode, footer pinning, vertical centering

πŸ”œ Planned

  • 🌐 Custom Domain Integration β€” Finalise client domain setup flow, DNS verification automation, redirect engine integration, setup documentation (#91)
  • πŸ“‘ REST API β€” JSON/XML endpoints, API key auth, OpenAPI/Swagger docs (#75)
  • πŸ“Š Analytics β€” Click tracking, geographic maps, device breakdown, data export
  • πŸ“‘ LinksPage β€” Template system, WYSIWYG editor, custom domains, age verification
  • πŸ”€ Advanced Redirects β€” Scheduled, device-based, geo-based routing, age gates
  • πŸ” Advanced Auth (SIGNula) β€” Social login (Google/GitHub), 2FA (TOTP), passkeys (WebAuthn), SSO
  • πŸ’° Payments (SIGNula) β€” Subscription tiers, PayPal, Apple Pay, Google Pay, crypto

πŸ› οΈ Tech Stack

Layer Technology
🐘 Backend PHP 8.4+ / 8.5+ (MySQLi, prepared statements only)
πŸ—„οΈ Database MySQL 8.0+ (InnoDB, utf8mb4, stored procedures)
🎨 Frontend HTML5, CSS3, Bootstrap 5.3, jQuery 3.7, Font Awesome 6
πŸ“ˆ Charts Chart.js 4.4, Leaflet.js (planned)
🚒 Hosting Dreamhost Shared Hosting (no CLI/Composer)
πŸ€– CI/CD GitHub Actions (PHP lint, release, SFTP deploy)

πŸ“Š Build Progress

Phase Version Name Issues Status
βœ… 0 v0.1.0 Scaffolding 7 Complete
βœ… 1 v0.2.0 Database 5 Complete
βœ… 2 v0.3.0 PHP Framework 11 Complete
βœ… 3 v0.4.0 Core Product 10 Complete
βœ… 4 v0.5.0 User System: Auth & Dashboard 4 Complete
βœ… 5 v0.6.0 Organisation Management 1 Complete
βœ… 6 v0.7.0 Compliance, Legal & Pre-Launch 7/8 Complete
βœ… β€” v1.0.0-rc PRE-RELEASE CANDIDATE β€” Tagged
⏳ 7 v1.1.0 API & Analytics 8 In Progress
πŸ“‹ 8 v1.2.0 LinksPage 6 Post-Launch
πŸ“‹ 9 v1.3.0 Advanced Redirects 6 Post-Launch
πŸ“‹ 10 v1.4.0 Advanced Authentication (SIGNula) 4 Post-Launch
πŸ“‹ 11 v1.5.0 Payments & Subscriptions (SIGNula) 4 Post-Launch

59 of 89 issues complete (66%) β€” tracked on the GitHub Project Board

βœ… Phase 0 β€” Scaffolding (v0.1.0)

  • πŸ“ Full web/ directory structure for all 3 components
  • πŸ”’ Auth credentials templates with direct-access guards
  • πŸ“ Documentation framework (README, CHANGELOG, PROJECT_STATUS, DEV_NOTES, docs/)
  • πŸ—οΈ GitHub infrastructure (issues, milestones, project board, labels, Actions)
  • 🌐 "Coming Soon" landing pages for all 3 domains (auto-refresh, countdown ring, dark mode)
  • πŸ”€ .htaccess foundation (HTTPS, security headers, clean URLs, routing)
  • 🎨 Brand guidelines, logo assets, and full BrandKit (SVG/PNG logos, app icons, favicons, PWA icons)

βœ… Phase 1 β€” Database (v0.2.0)

  • πŸ—„οΈ 30-table schema (mwtools_Go2MyLink) with InnoDB + utf8mb4
  • ⚑ 3 stored procedures (lookupShortURL, logActivity, generateShortCode)
  • πŸ“¦ 6 migration scripts for existing MWlink data (480 URLs, 5 orgs, 7 users)
  • 🌱 Seed data (subscription tiers, settings, LinksPage templates, languages)

βœ… Phase 2 β€” PHP Framework (v0.3.0)

  • πŸ› οΈ 8 shared function files: DB connection/queries, settings, security, error handling, activity logging, i18n, routing
  • 🎨 Template engine: header, nav, footer with Bootstrap 5.3 CDN + local fallback
  • β™Ώ Accessibility helpers (formField, ARIA, skip-to-content)
  • 🌍 i18n with __() translation function + locale detection + language switcher
  • πŸ“¦ Third-party libraries: Bootstrap 5.3.3, jQuery 3.7.1, Font Awesome 6.5.1, Chart.js 4.4.7

βœ… Phase 3 β€” Core Product (v0.4.0)

  • πŸ”€ Redirect engine with resolver functions + stored procedure lookup
  • 🚫 Branded error pages (404, expired, validating) with countdown timers
  • πŸ€– Dynamic robots.txt + org-specific favicon handlers
  • ✨ Anonymous URL creation with rate limiting + CAPTCHA (Turnstile/reCAPTCHA)
  • πŸ“‘ Internal API (POST /api/create/) with CSRF + CAPTCHA + no-JS fallback
  • 🏠 Homepage with AJAX URL shortening form + copy-to-clipboard
  • πŸ“ Static pages: About, Features, Pricing, Contact, Legal
  • πŸ” URL info/preview page with status badges
  • 🎨 Dark/light mode theme system

βœ… Phase 4 β€” User System: Auth & Dashboard (v0.5.0)

  • πŸ”‘ Auth engine: register, login, logout, password reset/change, email verification
  • πŸ” Database-backed session management with multi-device tracking + revoke
  • πŸ“§ Transactional email system with 4 HTML templates
  • πŸ“ Auth pages: Register, Login, Forgot Password, Reset Password, Verify Email, Logout
  • πŸ–₯️ Admin dashboard: stats overview, link CRUD, profile + password change, session management
  • 🌱 14 database settings for auth, security, email, and password policy

βœ… Phase 5 β€” Organisation Management (v0.6.0)

  • 🏒 Organisation CRUD: create, edit settings, overview dashboard with stats
  • πŸ‘₯ Member management: invite (email with tokenised accept), role change (User ↔ Admin), remove
  • 🌐 Custom domain management: add, DNS TXT verification, remove
  • πŸ”— Short domain management: add, set default, remove
  • πŸ›‘οΈ Role enforcement: GlobalAdmin > Admin > User with canManageOrg() permission check
  • πŸ—„οΈ tblOrgInvitations schema + 12 org settings + JSON Schema

βœ… Phase 6 β€” Compliance, Legal & Pre-Launch (v0.7.0) β€” Complete

  • βœ… πŸ“œ Legal document templates β€” Terms, Privacy, Cookies, Copyright, AUP (#61)
  • βœ… πŸͺ Cookie consent system β€” jurisdiction-aware banner, preferences modal, consent API (#62)
  • βœ… πŸ” Data subject rights β€” GDPR export, deletion, anonymisation, privacy dashboard (#63)
  • βœ… πŸ›‘οΈ DNT/GPC support & production hardening β€” CSP headers, HSTS, error pages (#64)
  • βœ… πŸ“± PWA manifest & service worker β€” offline fallback, app icons for all 3 properties (#65)
  • βœ… β™Ώ WCAG 2.1 AA audit β€” 23 files fixed: landmarks, ARIA, contrast, headings, forms (#66)
  • βœ… πŸ—„οΈ Migration plan & dry-run SQL β€” 7-step process, rollback safeguards (#67)
  • πŸ”„ 🌍 Translation seed β€” en-GB baseline (~1,075 keys) done; 9 locales deferred post-launch (#71)
  • βœ… πŸ”’ Pre-release audit β€” security hardening, WCAG refinements, W3C compliance (20 files)

🏁 v1.0.0-rc β€” Pre-Release Candidate after Phase 6

πŸ“‹ Phases 7–11 (Post-Launch Enhancements)

  • Phase 7 β€” API & Analytics: REST API, OpenAPI/Swagger docs, API keys, analytics dashboard
  • Phase 8 β€” LinksPage: renderer, templates, WYSIWYG editor, custom domains
  • Phase 9 β€” Advanced Redirects: scheduled, device, geo, age gates
  • Phase 10 β€” Advanced Authentication (SIGNula): 2FA/TOTP, social login, SSO, passkeys
  • Phase 11 β€” Payments & Subscriptions (SIGNula): tiers, PayPal, Apple Pay, Google Pay, crypto

πŸ“ Repository Structure

Go2My.Link/
β”œβ”€β”€ 🎨 assets/BrandKit/          ← Full brand kit: logos, icons, favicons, PWA icons, press kit
β”œβ”€β”€ πŸ€– .claude/                  ← Claude AI context (project brief, plans, memory)
β”œβ”€β”€ πŸ€– .openai/                  ← OpenAI context
β”œβ”€β”€ βš™οΈ .github/workflows/        ← CI/CD (PHP lint, release, SFTP deploy)
β”œβ”€β”€ πŸ“š docs/                     ← ARCHITECTURE, DATABASE, API, DEPLOYMENT
β”œβ”€β”€ 🌐 web/
β”‚   β”œβ”€β”€ βš™οΈ _functions/           ← Shared PHP functions (13 files)
β”‚   β”œβ”€β”€ πŸ“¦ _includes/            ← Shared templates + email templates
β”‚   β”œβ”€β”€ πŸ“¦ _libraries/           ← Local fallback libraries (Bootstrap, jQuery, FA, Chart.js)
β”‚   β”œβ”€β”€ πŸ“ _schemas/             ← JSON Schema definitions (api, database, external)
β”‚   β”œβ”€β”€ πŸ—„οΈ _sql/                 ← Schema, migrations, seeds, stored procedures
β”‚   β”œβ”€β”€ 🏠 Go2My.Link/           ← Component A (Main Website + Admin Dashboard)
β”‚   β”‚   β”œβ”€β”€ public_html/         ← go2my.link web root (+ img/ for logos)
β”‚   β”‚   β”œβ”€β”€ public_html_landing/ ← "Coming Soon" landing page
β”‚   β”‚   └── _admin/public_html/  ← admin.go2my.link web root (+ img/ for logos)
β”‚   β”œβ”€β”€ πŸ”— G2My.Link/            ← Component B (Redirect Engine)
β”‚   β”‚   β”œβ”€β”€ public_html/         ← g2my.link web root (+ img/ for logos)
β”‚   β”‚   └── public_html_landing/ ← "Coming Soon" landing page
β”‚   └── πŸ“‘ Lnks.page/            ← Component C (LinksPage)
β”‚       β”œβ”€β”€ public_html/         ← lnks.page web root (+ img/ for logos)
β”‚       └── public_html_landing/ ← "Coming Soon" landing page
β”œβ”€β”€ πŸ“ CHANGELOG.md
β”œβ”€β”€ πŸ“Š PROJECT_STATUS.md
β”œβ”€β”€ πŸ—’οΈ DEV_NOTES.md
└── πŸ“‹ README.md

βš™οΈ Development

πŸ“Œ Prerequisites

  • 🐘 PHP 8.4+ or 8.5+
  • πŸ—„οΈ MySQL 8.0+
  • πŸ–₯️ Visual Studio Code (recommended) with FTP Sync extension
  • πŸ”€ Git

🏁 Getting Started

  1. Clone the repository:

    git clone https://github.com/MWBMPartners/Go2My.Link.git
  2. Copy the auth credentials template:

    cp web/_auth_keys/auth_creds.php web/_auth_keys/auth_creds.local.php
  3. Edit web/_auth_keys/auth_creds.local.php with your database credentials.

  4. Import the database schema from web/_sql/schema/.

  5. Run the seed scripts from web/_sql/seeds/.

  6. Point your web server document roots to the appropriate public_html/ directories.

🌿 Branch Strategy

  • main β€” Production-ready code
  • Feature branches for development, merged via pull request

πŸš€ Releasing

Releases are managed via GitHub Actions. Each component can be released independently:

  1. Go to Actions β†’ "πŸš€ Create Release" β†’ "Run workflow"
  2. Select the component (A, B, C, Admin, or All)
  3. Enter the version number (e.g., 0.5.0)
  4. Optionally mark as pre-release and add notes
  5. The workflow will lint PHP, create a Git tag, and publish a GitHub Release

Tag format:

Scope Tag Example
Full platform v0.5.0
Component A (Main Website) component-a/v0.5.0
Component A (Admin Dashboard) component-a-admin/v0.5.0
Component B (Redirect Engine) component-b/v0.5.0
Component C (LinksPage) component-c/v0.5.0

See DEV_NOTES.md for detailed release process documentation.


πŸ“‹ Project Management

  • πŸ“Œ GitHub Project: Go2My.Link Development
  • πŸ› Issues: 89 issues tracked with phase labels (phase-0 through phase-11)
  • 🏁 Milestones: v0.1.0 (Scaffold) through v1.5.0 (Payments), with v1.0.0-rc pre-release marker

βš–οΈ License

Proprietary β€” MWBM Partners Ltd. All rights reserved.

πŸ”— Links

About

A web URL Shortening service (successor to earlier MWlink)

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors