# gnuboard/gnuboard5 architecture

> Architecture diagram of the GitHub repository gnuboard/gnuboard5, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-10). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/gnuboard/gnuboard5
- Repository: https://github.com/gnuboard/gnuboard5

## Overview

GNUboard5 is a PHP/MySQL CMS with member and bulletin-board management, packaged with the Youngcart shopping solution. The primary visitor workflow enters through the site homepage, which initializes shared application state and renders recent board content; shoppers have a separate storefront with configurable product collections. Administrators manage site and shop operations through distinct consoles. The README documents installation, database upgrades, and mobile-payment requirements. Many runtime files are unsampled, so links between those subsystems are omitted rather than inferred.

Main entry points: [`index.php`](https://github.com/gnuboard/gnuboard5/blob/master/index.php) (CMS homepage), [`shop/index.php`](https://github.com/gnuboard/gnuboard5/blob/master/shop/index.php) (Shop homepage), [`lib/shop_order_state.lib.php`](https://github.com/gnuboard/gnuboard5/blob/master/lib/shop_order_state.lib.php) (Orders and checkout), [`adm/index.php`](https://github.com/gnuboard/gnuboard5/blob/master/adm/index.php) (Admin console)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_site["CMS Site"]
  node_homepage["CMS homepage<br/>[index.php]"]
  node_mobile_site["Mobile site<br/>[index.php]"]
  node_theme_home["Theme homepage<br/>[index.php]"]
  node_site_layout["Site layout<br/>[head.php]"]
  node_site_footer["Site footer<br/>[tail.php]"]
end

subgraph group_community["Community Features"]
  node_boards["Boards and posts<br/>[board.php]"]
  node_membership["Member accounts<br/>[register.php]"]
  node_qa["Q&amp;A boards<br/>[qalist.php]"]
end

subgraph group_commerce["Youngcart Commerce"]
  node_shop_home["Shop homepage<br/>[index.php]"]
  node_mobile_shop["Mobile shop<br/>[index.php]"]
  node_product_data["Product collections<br/>[shop.data.lib.php]"]
  node_orders["Orders and checkout"]
  node_payments["Payment integrations"]
end

subgraph group_admin["Administration"]
  node_admin_console["Admin console<br/>[index.php]"]
  node_shop_admin["Shop administration<br/>[admin.shop.lib.php]"]
end

subgraph group_platform["Platform Services"]
  node_bootstrap["Shared bootstrap<br/>[common.php]"]
  node_database[("MySQL or MariaDB")]
  node_php_excel["PHPExcel library"]
  node_lg_payment_sdk["LG payment SDK<br/>[XPayClient.php]"]
end

node_visitor(("Site visitor"))

node_visitor -->|"opens"| node_homepage
node_homepage -->|"initializes"| node_bootstrap
node_homepage -->|"routes to"| node_theme_home
node_homepage -->|"routes to"| node_mobile_site
node_homepage -->|"renders"| node_site_layout
node_homepage -->|"renders"| node_site_footer
node_homepage -->|"loads latest"| node_boards
node_visitor -->|"opens"| node_shop_home
node_shop_home -->|"routes to"| node_mobile_shop
node_shop_home -->|"renders collections"| node_product_data
node_visitor -->|"registers"| node_membership
node_visitor -->|"uses"| node_qa
node_visitor -->|"administers"| node_admin_console
node_admin_console -.->|"offers shop management"| node_shop_admin
node_shop_home -.->|"supports orders"| node_orders
node_orders -.->|"uses gateway"| node_payments
node_lg_payment_sdk -.->|"supports payments"| node_payments
node_homepage -->|"uses"| node_database
node_shop_home -->|"uses"| node_database
node_php_excel -->|"not connected"| node_database

click node_homepage "https://github.com/gnuboard/gnuboard5/blob/master/index.php"
click node_mobile_site "https://github.com/gnuboard/gnuboard5/blob/master/mobile/index.php"
click node_theme_home "https://github.com/gnuboard/gnuboard5/blob/master/theme/basic/index.php"
click node_bootstrap "https://github.com/gnuboard/gnuboard5/blob/master/common.php"
click node_site_layout "https://github.com/gnuboard/gnuboard5/blob/master/head.php"
click node_site_footer "https://github.com/gnuboard/gnuboard5/blob/master/tail.php"
click node_boards "https://github.com/gnuboard/gnuboard5/blob/master/bbs/board.php"
click node_membership "https://github.com/gnuboard/gnuboard5/blob/master/bbs/register.php"
click node_qa "https://github.com/gnuboard/gnuboard5/blob/master/bbs/qalist.php"
click node_shop_home "https://github.com/gnuboard/gnuboard5/blob/master/shop/index.php"
click node_mobile_shop "https://github.com/gnuboard/gnuboard5/blob/master/mobile/shop/index.php"
click node_product_data "https://github.com/gnuboard/gnuboard5/blob/master/lib/shop.data.lib.php"
click node_orders "https://github.com/gnuboard/gnuboard5/blob/master/lib/shop_order_state.lib.php"
click node_payments "https://github.com/gnuboard/gnuboard5/tree/master/mobile/shop/inicis"
click node_admin_console "https://github.com/gnuboard/gnuboard5/blob/master/adm/index.php"
click node_shop_admin "https://github.com/gnuboard/gnuboard5/blob/master/adm/shop_admin/admin.shop.lib.php"
click node_php_excel "https://github.com/gnuboard/gnuboard5/tree/master/lib/PHPExcel"
click node_lg_payment_sdk "https://github.com/gnuboard/gnuboard5/blob/master/plugin/lgxpay/lgdacom/XPayClient.php"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_homepage,node_mobile_site,node_theme_home,node_site_layout,node_site_footer toneBlue
class node_boards,node_membership,node_qa toneAmber
class node_shop_home,node_mobile_shop,node_product_data,node_orders,node_payments toneMint
class node_admin_console,node_shop_admin toneRose
class node_bootstrap,node_database,node_php_excel,node_lg_payment_sdk,node_visitor toneIndigo
```

## Components

### CMS Site

- [CMS homepage](https://github.com/gnuboard/gnuboard5/blob/master/index.php): `index.php`
- [Mobile site](https://github.com/gnuboard/gnuboard5/blob/master/mobile/index.php): `mobile/index.php`
- [Theme homepage](https://github.com/gnuboard/gnuboard5/blob/master/theme/basic/index.php): `theme/basic/index.php`
- [Site layout](https://github.com/gnuboard/gnuboard5/blob/master/head.php): `head.php`
- [Site footer](https://github.com/gnuboard/gnuboard5/blob/master/tail.php): `tail.php`

### Community Features

- [Boards and posts](https://github.com/gnuboard/gnuboard5/blob/master/bbs/board.php): `bbs/board.php`
- [Member accounts](https://github.com/gnuboard/gnuboard5/blob/master/bbs/register.php): `bbs/register.php`
- [Q&A boards](https://github.com/gnuboard/gnuboard5/blob/master/bbs/qalist.php): `bbs/qalist.php`

### Youngcart Commerce

- [Shop homepage](https://github.com/gnuboard/gnuboard5/blob/master/shop/index.php): `shop/index.php`
- [Mobile shop](https://github.com/gnuboard/gnuboard5/blob/master/mobile/shop/index.php): `mobile/shop/index.php`
- [Product collections](https://github.com/gnuboard/gnuboard5/blob/master/lib/shop.data.lib.php): `lib/shop.data.lib.php`
- [Orders and checkout](https://github.com/gnuboard/gnuboard5/blob/master/lib/shop_order_state.lib.php): `lib/shop_order_state.lib.php`
- [Payment integrations](https://github.com/gnuboard/gnuboard5/tree/master/mobile/shop/inicis): `mobile/shop/inicis`

### Administration

- [Admin console](https://github.com/gnuboard/gnuboard5/blob/master/adm/index.php): `adm/index.php`
- [Shop administration](https://github.com/gnuboard/gnuboard5/blob/master/adm/shop_admin/admin.shop.lib.php): `adm/shop_admin/admin.shop.lib.php`

### Platform Services

- [Shared bootstrap](https://github.com/gnuboard/gnuboard5/blob/master/common.php): `common.php`
- **MySQL or MariaDB**
- [PHPExcel library](https://github.com/gnuboard/gnuboard5/tree/master/lib/PHPExcel): `lib/PHPExcel`
- [LG payment SDK](https://github.com/gnuboard/gnuboard5/blob/master/plugin/lgxpay/lgdacom/XPayClient.php): `plugin/lgxpay/lgdacom/XPayClient.php`

### Other components

- **Site visitor**

## Connections

- Site visitor → CMS homepage: opens (evidence: `README.md`)
- CMS homepage → Shared bootstrap: initializes (evidence: `index.php`)
- CMS homepage → Theme homepage: routes to (evidence: `index.php`)
- CMS homepage → Mobile site: routes to (evidence: `index.php`)
- CMS homepage → Site layout: renders (evidence: `index.php`)
- CMS homepage → Site footer: renders (evidence: `index.php`)
- CMS homepage → Boards and posts: loads latest (evidence: `index.php`)
- Site visitor → Shop homepage: opens (evidence: `README.md`)
- Shop homepage → Mobile shop: routes to (evidence: `shop/index.php`)
- Shop homepage → Product collections: renders collections (evidence: `shop/index.php`)
- Site visitor → Member accounts: registers (evidence: `README.md`)
- Site visitor → Q&A boards: uses (evidence: `README.md`)
- Site visitor → Admin console: administers (evidence: `README.md`)
- Admin console → Shop administration: offers shop management
- Shop homepage → Orders and checkout: supports orders
- Orders and checkout → Payment integrations: uses gateway
- LG payment SDK → Payment integrations: supports payments
- CMS homepage → MySQL or MariaDB: uses (evidence: `README.md`)
- Shop homepage → MySQL or MariaDB: uses (evidence: `README.md`)
- PHPExcel library → MySQL or MariaDB: not connected
