Account Statement WHMCS Addon
WHMCS addon module for generating comprehensive financial statements for clients. Consolidates invoices, transactions, and credits into detailed account statements with PDF and CSV export, scheduled generation, bulk processing, and client area self-service access.
- Description
- Changelog
- Installation and Update
- Dashboard
- Generate Statement
- Saved Statements
- Bulk Generate
- Schedules
- Schedule Editor
- PDF Style
- Settings
- Client Area
Description
Account Statement addon WHMCS
Order now | Download | FAQ
PUQ Account Statement — WHMCS Addon
PUQ Account Statement is an addon module for WHMCS that generates comprehensive financial statements for clients. It consolidates invoices, transactions, and credits into detailed account statements with PDF and CSV export, scheduled automatic generation, bulk processing, and client area self-service access.
Key Features
- Statement Generation — generate detailed financial statements for any client with customizable date ranges and filters
- Clear Outstanding Balance — the closing balance shows exactly how much the client owes (negative = owed) and ties out with the Debit/Credit columns; Account Credit is shown as a separate figure
- Multilingual Statements — PDF, preview, and CSV are generated in the client's own language (falling back to system language, then English), translated across 25 languages
- WHMCS Date Format — statement dates follow your WHMCS Global Date Format
- Multiple Export Formats — export statements as PDF or CSV files
- Customizable PDF Templates — choose from multiple PDF layouts (Classic, Modern, Detailed) in Portrait or Landscape orientation
- PDF Style Editor — customize typography, colors, display options, header/footer text, and custom CSS
- Saved Statements Archive — save generated statements for future reference with search and filter capabilities
- Bulk Generation — generate statements for multiple clients at once, filtered by client group, country, or unpaid invoices
- Scheduled Generation — automate statement generation with configurable schedules (daily, weekly, monthly, quarterly, yearly)
- Client Area Access — allow clients to view, generate, and download their own statements
- Email Delivery — send statements to clients via email with PDF attachment using customizable WHMCS email templates
- Public Shareable Links — generate expiring public links to share statements externally
- Aging Report — include overdue invoice aging analysis in statements
- Invoice Filtering — filter by payment status (paid, unpaid, refunded), payment methods, and product groups
- Transaction & Credit Tracking — include transactions and credit entries in statements
- Quick Period Selection — one-click date range presets (This Month, Last Month, This Year, Last Year)
- Dashboard — overview with key metrics, quick generate, recent statements, and upcoming schedules
- License system — online/offline license verification with graceful degradation (dashboard remains accessible without a license)
- Multilingual interface — admin and client area available in 25 languages
System Requirements
| Requirement | Minimum |
|---|---|
| WHMCS | 8.x, 9.x |
| PHP | 7.4, 8.1, 8.2+ |
| ionCube Loader | v13 or newer (v14, v15) |
The module ships as separate ionCube-encoded builds per PHP version. Pick the build that matches your PHP:
| WHMCS | Supported PHP | Build to use |
|---|---|---|
| WHMCS 8 | 7.4, 8.1, 8.2 | php74, php81, or php82 (match your PHP) |
| WHMCS 9 | 8.2+ | php82 |
For any PHP 8.2 or newer, always use the
php82build.
Links
- Product page: https://puqcloud.com/
- Documentation: https://doc.puq.info/books/account-statement-whmcs-addon
- Support: https://puqcloud.com/submitticket.php
- Community: https://community.puqcloud.com/
Changelog
Account Statement addon WHMCS
Order now | Download | FAQ
v1.2 — 2026-06-05
The clarity update. Your customers now see, at a glance, exactly how much they owe — in their own language and in your date format.
New Features
-
Real outstanding balance. The Closing Balance now reflects what the customer actually owes (negative = owed), and it ties out perfectly with the Debit and Credit columns of the statement. No more confusing
$0.00closing balances when there are unpaid invoices. - Account Credit shown separately. Statements now display both the client's Account Credit and the amount owed, so the two are never mixed up.
- Carry-forward opening balance. The Open Balance now includes outstanding invoices from before the statement period — perfect for statements that start mid-history.
- Multilingual statements. PDF, on-screen preview, and CSV exports are now generated in the client's own language, with automatic fallback to your system language and then English. Fully translated across 25 languages.
- "Show Open Balance" setting. Hide the Open Balance line entirely if you only want to show the amount owed.
Improvements
-
Dates follow your WHMCS Global Date Format. Statement dates now respect the format configured in WHMCS (e.g.
DD/MM/YYYY) instead of a fixed format. - Smarter client search. The admin client search now matches first name + last name together (in any order), as well as company, email, or client ID.
- Client area language. The client area now displays in the logged-in customer's own language.
- CSV summary fixed & expanded. The CSV summary section now shows correct values (including Account Credit and amount owed) and is included with emailed/attached exports.
Bug Fixes
- Fixed the running-balance column in the Detailed PDF template (it previously never updated and used the wrong sign).
- Fixed mixed-language output where the statement preview and PDF stayed in English regardless of the selected language.
v1.1 — 2026-02-25
Bug Fixes
- Fixed "Call to undefined function puq_account_statement_LoadLang()" error on customer profile page
Improvements
- All monetary values now consistently display with 2 decimal places (e.g.,
0.00,5.10instead of0or5.1) - Removed currency symbol from the Total column in statements for uniform formatting with Debit and Credit columns
New Features
- Added "Show Payment Method" setting to control visibility of the Payment Method column in statements
- When disabled, the Payment Method column is hidden across all views: admin preview, PDF exports, and CSV exports
v1.0 — 2026-02-18
First release.
New Features
- Statement generation for individual clients with customizable date ranges
- Invoice filtering by status: Paid, Unpaid, Refunded
- Transaction and credit entry inclusion in statements
- Payment method and product group filtering
- Quick period presets: This Month, Last Month, This Year, Last Year
- PDF export with multiple templates: Classic, Modern, Detailed (Portrait & Landscape)
- CSV export for data analysis
- PDF Style editor: typography, colors, display options, header/footer text, custom CSS
- Saved statements archive with search, filter, and pagination
- Bulk generation for multiple clients with progress tracking
- Client filters for bulk: All Clients, By Client Group, By Country, With Unpaid Invoices
- Scheduled automatic statement generation (Daily, Weekly, Monthly, Quarterly, Yearly)
- Schedule management: create, edit, toggle, run now, delete
- Client area self-service: view, generate, and download statements
- Client area configurable permissions: PDF download, CSV download
- Email delivery with PDF attachment using WHMCS email templates
- Public shareable links with configurable expiry
- Aging report for overdue invoice analysis
- Dashboard with key metrics, quick generate, recent statements, upcoming schedules
- Auto-cleanup of old saved statements
- Configurable per-page pagination
- Add to Billing Menu option for client area
- AJAX-based interface with loading spinners on all actions
- License verification system with online/offline modes
- Dashboard accessible without active license, other pages restricted
- Error logging via WHMCS
logModuleCall - English language interface
Installation and Update
Account Statement addon WHMCS
Order now | Download | FAQ
System Requirements
| Requirement | Minimum |
|---|---|
| PHP | 7.4, 8.1, 8.2 or newer |
| WHMCS | 8.x, 9.x or newer |
| ionCube Loader | v13 or newer (v14, v15) |
Note: The module uses ionCube encoding. Make sure ionCube Loader is installed and active on your server.
Which build do I need?
The module is distributed as separate ionCube-encoded builds, one per PHP version. The PHP version determines which build you download — an archive encoded for one PHP version will not run on another.
| WHMCS | Supported PHP | Build to download |
|---|---|---|
| WHMCS 8 | 7.4, 8.1, 8.2 | php74, php81, or php82 — match the PHP your WHMCS runs on |
| WHMCS 9 | 8.2 or newer | php82 |
Rule of thumb: for any PHP 8.2 or newer, always use the
php82build. Usephp74/php81only if your server still runs PHP 7.4 or 8.1 (WHMCS 8 only).
Download
The module can be ordered and downloaded from PUQ Cloud:
- Order / Download: https://puqcloud.com/store/whmcs-addon-modules
- FAQ: https://community.puqcloud.com/
- Direct download links:
PHP 7.4 (WHMCS 8 only):
wget https://download.puqcloud.com/WHMCS/addons/PUQ_WHMCS-Account-Statement/php74/PUQ_WHMCS-Account-Statement-latest.zip
PHP 8.1 (WHMCS 8 only):
wget https://download.puqcloud.com/WHMCS/addons/PUQ_WHMCS-Account-Statement/php81/PUQ_WHMCS-Account-Statement-latest.zip
PHP 8.2+ (WHMCS 8 and 9):
wget https://download.puqcloud.com/WHMCS/addons/PUQ_WHMCS-Account-Statement/php82/PUQ_WHMCS-Account-Statement-latest.zip
All versions are available at: https://download.puqcloud.com/WHMCS/addons/PUQ_WHMCS-Account-Statement/
After downloading, extract the archive:
unzip PUQ_WHMCS-Account-Statement-latest.zip
Installation
Step 1: Upload Files
Extract the module archive and upload the puq_account_statement directory to the WHMCS addons directory:
/your-whmcs/modules/addons/puq_account_statement/
Directory structure after upload:
modules/addons/puq_account_statement/
puq_account_statement.php
hooks.php
whmcs.json
version
logo.png
lib/
puqAccountStatement.php
StatementGenerator.php
PdfGenerator.php
CsvGenerator.php
lang/
english.php
templates/
...
templates/pdf/
classic.tpl
modern.tpl
detailed.tpl
...
templates/client/
statement.tpl
Step 2: Activate the Module
- Log in to the WHMCS admin panel
- Go to Setup > Addon Modules
- Find PUQ Account Statement in the list
- Click Activate
On activation, the module creates four database tables:
puq_acc_st_settings,puq_acc_st_statements,puq_acc_st_schedules, andpuq_acc_st_templates.
Step 3: Configure the License Key
- After activation, click Configure next to the module
- Enter your license key in the License key field
- Select admin role groups that should have access to the module
- Click Save Changes
After saving, a verification status will appear below the license key field (e.g., success: 2027-02-18T01:32:13+01:00).
01-addon-config-license.png
Step 4: Access the Module
Go to Addons > PUQ Account Statement to access the dashboard.
Update
Step 1: Backup
Before updating, we recommend backing up:
- Your WHMCS database
- Module files in
modules/addons/puq_account_statement/
Step 2: Upload New Files
Extract the new version and overwrite all files in:
/your-whmcs/modules/addons/puq_account_statement/
Step 3: Re-activate (if needed)
If the update adds new database columns, deactivate and re-activate the module:
- Go to Setup > Addon Modules
- Click Deactivate, then Activate again
This is safe — the module only creates tables/columns if they don't already exist. Your settings and saved statements are preserved.
Step 4: Verify
- Go to Addons > PUQ Account Statement
- Check the version number in the top-right corner of the navigation bar (e.g.,
v1.0.0)
Deactivation
- Go to Setup > Addon Modules
- Click Deactivate next to PUQ Account Statement
- Confirm the deactivation
Warning: Deactivation drops the module's database tables (
puq_acc_st_settings,puq_acc_st_statements,puq_acc_st_schedules,puq_acc_st_templates). All your saved statements, schedules, templates, and settings will be lost. Export your data before deactivating if you want to preserve it.
License
The module requires an active license for full functionality. The license is verified through the PUQ Cloud license server.
How License Verification Works
- The module periodically checks license validity at
https://license.puqcloud.com/ - Verification results are cached in the database for 5 days
- If the license server is temporarily unreachable, the module uses the last cached result
Without an Active License
- Dashboard (Home page) remains fully accessible
- All other pages (Generate, Saved, Bulk, Schedules, PDF Style, Settings) display a license required page
- All AJAX controllers (except Dashboard) return a 403 error
After Activating a License
Purchase a License
https://puqcloud.com/store/whmcs-addon-modules
https://puqcloud.com/submitticket.php
Dashboard
Account Statement addon WHMCS
Order now | Download | FAQ
The Dashboard is the home page of the module, available at: Addons > PUQ Account Statement > Dashboard
It provides a complete overview of your statement activity — key metrics, quick generation, recent statements, and upcoming schedules.
02-dashboard.png
Key Metrics
The top section displays summary cards with color-coded borders:
| Metric | Description |
|---|---|
| This Month Statements | Number of statements generated in the current month |
| Total Statements | Total number of saved statements in the archive |
| Active Schedules | Number of currently active automatic schedules |
| Next Scheduled Run | Date and time of the next scheduled statement generation |
Quick Generate
A search panel for quickly generating a statement for a specific client:
- Start typing a client name or email in the search field
- Select the client from the dropdown results (powered by Select2 with AJAX search)
- Click Generate to navigate to the Generate page with the client pre-selected
Recent Statements
A table showing the 10 most recently generated statements:
| Column | Description |
|---|---|
| Date | When the statement was generated |
| Client | Client full name |
| Period | Statement date range (from — to) |
| Generated By | How the statement was created: manual, schedule, or bulk |
| Actions | View button to open the saved statement |
Upcoming Schedules
A table showing up to 5 active schedules with their next run times:
| Column | Description |
|---|---|
| Name | Schedule name |
| Frequency | How often it runs (Daily, Weekly, Monthly, Quarterly, Yearly) |
| Next Run | Date and time of the next execution |
| Status | Badge: Active (green) or Inactive (gray) |
Generate Statement
Account Statement addon WHMCS
Order now | Download | FAQ
The Generate page is available at: Addons > PUQ Account Statement > Generate
This is the main page for creating individual account statements for a specific client.
03-generate.png
Generate from a Client's Profile
You can also start a statement directly from a client's profile. Open Clients > select a client, and on the Summary tab use the Account Statement panel and click Generate Account Statement. This opens the Generate page with the client pre-selected.
21-admin-client-profile.png
Statement Parameters
Client Selection
Use the search field to find a client by first name, last name (or both together), company, email, or client ID. The field uses Select2 with AJAX search — start typing to see results. Searching a full name such as "John Smith" matches first name + last name in any order.
Tip: You can navigate here from the Dashboard's Quick Generate feature, which pre-selects the client.
Date Range
Set the date range for the statement using:
- Date From / Date To — manual date inputs
-
Quick Period buttons — one-click presets:
- This Month — first to last day of current month
- Last Month — first to last day of previous month
- This Year — January 1 to December 31 of current year
- Last Year — January 1 to December 31 of previous year
Include Options
Select which financial data to include in the statement:
| Option | Description |
|---|---|
| Paid | Include paid invoices |
| Unpaid | Include unpaid/outstanding invoices |
| Refunded | Include refunded invoices |
| Transactions | Include payment transactions |
| Credits | Include credit entries |
Advanced Filters
| Filter | Description |
|---|---|
| Payment Methods | Filter invoices by payment gateway (multi-select). Leave empty for all |
| Product Groups | Filter invoices by product group (multi-select). Leave empty for all |
Actions
View Statement
Click View Statement to generate and display the statement preview inline on the page. The preview shows the rendered HTML statement with all sections.
Reading the balance: The summary shows two distinct figures — Account Credit (the credit available on the client's WHMCS account) and the Closing Balance, which is the outstanding amount. A negative Closing Balance means the client owes that amount, and it always ties out with the Debit and Credit columns. The Open Balance line carries forward any unpaid invoices from before the statement period and can be hidden via Settings → Show Open Balance.
Language & dates: Statements (preview, PDF, and CSV) are generated in the client's own language when available — falling back to the system language, then English. Dates follow your WHMCS Global Date Format.
Download PDF
Click Download PDF to generate and download the statement as a PDF file. The PDF uses the template configured in the Settings page.
Download CSV
Click Download CSV to generate and download the statement data as a CSV file for import into spreadsheets or accounting software.
Statement Preview Actions
After viewing a statement, additional action buttons appear in the preview header:
| Action | Description |
|---|---|
| Save to Archive | Save the statement to the saved statements archive for future reference |
| Send to Client | Send the statement to the client via email with PDF attachment |
| Generate Link | Generate a public shareable link (copied to clipboard automatically) |
04-generate-preview.png
Saved Statements
Account Statement addon WHMCS
Order now | Download | FAQ
The Saved Statements page is available at: Addons > PUQ Account Statement > Saved Statements
This page shows all previously saved account statements with filtering, pagination, and management tools.
05-saved-statements.png
Filters
The top panel provides search and filter options:
| Filter | Description |
|---|---|
| Client | Search for a specific client by name or email (Select2 AJAX search) |
| Date From | Filter statements created from this date |
| Date To | Filter statements created up to this date |
| Generated By | Filter by generation method: All, Manual, Schedule, or Bulk |
Click Filter to apply the filters and reload the results.
Statements Table
The main table lists saved statements with the following columns:
| Column | Description |
|---|---|
| # | Statement ID |
| Client | Client name, company name, and email |
| Period | Statement date range (from — to) |
| Generated By | How the statement was created: manual, schedule, or bulk |
| Generated At | Timestamp when the statement was generated |
| Status | Badge: Active (green) or expired status |
| Actions | Action buttons (see below) |
Actions Per Statement
Each statement row has the following action buttons:
| Button | Icon | Description |
|---|---|---|
| file-pdf | Download/view the statement as PDF (opens in new tab) | |
| CSV | file-csv | Download the statement data as CSV |
| Send | envelope | Send the statement to the client via email with PDF attachment |
| Copy Link | link | Generate a public shareable link and copy it to clipboard |
| Delete | trash | Delete the saved statement (requires confirmation) |
Pagination
When there are more statements than the configured per-page limit (default: 25), pagination controls appear at the bottom of the table with page numbers and previous/next navigation.
Auto-Cleanup
Saved statements can be automatically deleted after a configurable number of days. This is set in Settings > Auto Cleanup Days. Set to 0 to disable auto-cleanup.
Bulk Generate
Account Statement addon WHMCS
Order now | Download | FAQ
The Bulk Generate page is available at: Addons > PUQ Account Statement > Bulk Generate
This page allows you to generate statements for multiple clients at once with a single operation.
06-bulk-generate.png
Client Filter
Choose which clients to generate statements for:
| Option | Description |
|---|---|
| All Clients | Generate for every client in the system |
| By Client Group | Filter by WHMCS client group (dropdown appears for selection) |
| By Country | Filter by client country (dropdown appears for selection) |
| With Unpaid Invoices | Only clients that have outstanding unpaid invoices |
When selecting By Client Group or By Country, a dropdown field appears to select the specific group or country.
Date Range & Options
Date Range
Set the statement period using:
- Date From / Date To — manual date inputs
- Quick Period buttons — same presets as the Generate page (This Month, Last Month, This Year, Last Year)
The default period is set to Last Month.
Include Options
Same checkboxes as the Generate page:
- Paid, Unpaid, Refunded, Transactions, Credits
Actions
Choose what to do with each generated statement:
| Action | Description |
|---|---|
| Save to Archive | Save each statement to the saved statements archive (checked by default) |
| Send Email | Send each statement to the respective client via email with PDF attachment |
Workflow
Step 1: Count Clients
Click Count Clients to see how many clients match your filter criteria. The result appears next to the button (e.g., "42 clients matched").
Step 2: Start Bulk Generate
After counting, the Start Bulk Generate button becomes enabled. Click it and confirm the operation.
Step 3: Monitor Progress
A progress bar appears showing:
- Visual progress bar with percentage
- Text counter: "X / Y clients processed"
The bulk operation processes clients in batches of 10 for optimal performance and to avoid timeouts.
Step 4: Review Results
After completion, a results panel shows:
| Metric | Description |
|---|---|
| Clients Processed | Total number of clients processed |
| Statements Generated | Number of statements successfully created |
| Emails Sent | Number of emails sent (if email option was enabled) |
| Errors | Number of errors encountered during processing |
Schedules
Account Statement addon WHMCS
Order now | Download | FAQ
The Schedules page is available at: Addons > PUQ Account Statement > Schedules > All Schedules
This page manages automated statement generation schedules. Schedules run automatically via WHMCS cron.
07-schedules.png
Schedules Table
The table lists all configured schedules with the following columns:
| Column | Description |
|---|---|
| Name | Schedule name for identification |
| Frequency | How often it runs: Daily, Weekly, Monthly, Quarterly, Yearly |
| Client Filter | Target clients: All, By Group, By Country, or With Unpaid Invoices |
| Next Run | Date and time of the next scheduled execution |
| Last Run | Date and time of the most recent execution |
| Status | Badge: Active (green) or Inactive (gray) |
| Actions | Action buttons (see below) |
Actions Per Schedule
| Button | Icon | Description |
|---|---|---|
| Edit | edit | Open the schedule editor to modify settings |
| Run Now | play | Execute the schedule immediately without waiting for the next scheduled time |
| Toggle | power-off | Enable or disable the schedule |
| Delete | trash | Delete the schedule (requires confirmation) |
Creating a New Schedule
Click the Add New button at the top or go to Schedules > Add Schedule in the navigation menu.
See the Schedule Editor page for details on configuring a schedule.
How Schedules Work
Schedules are executed by the WHMCS cron job. When a schedule's next run time is reached:
- The module identifies matching clients based on the schedule's client filter
- For each client, a statement is generated for the configured period
- Depending on the schedule's output settings, statements are saved to archive and/or emailed to clients
- The schedule's next run time is updated based on its frequency
- Execution details are logged for reference
Schedule Editor
Account Statement addon WHMCS
Order now | Download | FAQ
The Schedule Editor page is available at: Addons > PUQ Account Statement > Schedules > Add Schedule (or click Edit on an existing schedule)
This page allows you to create or edit an automated statement generation schedule.
08-schedule-edit.png
General Settings
| Setting | Description |
|---|---|
| Name | A descriptive name for the schedule (e.g., "Monthly Client Statements") |
| Frequency | How often the schedule runs: Daily, Weekly, Monthly, Quarterly, Yearly |
| Period Type | What period the statement covers: Last Month, Last Quarter, Last Year, or Custom |
Client Filter
Choose which clients receive statements when the schedule runs:
| Filter | Description |
|---|---|
| All Clients | Generate for every client |
| By Client Group | Only clients in a specific WHMCS client group |
| By Country | Only clients from a specific country |
| With Unpaid Invoices | Only clients with outstanding invoices |
When selecting By Client Group or By Country, a text field appears to enter the filter value.
Include Options
Configure what financial data to include in the generated statements:
- Paid — include paid invoices
- Unpaid — include unpaid invoices
- Refunded — include refunded invoices
- Transactions — include payment transactions
- Credits — include credit entries
Advanced Filters
| Filter | Description |
|---|---|
| Payment Methods | Only include invoices paid via specific gateways (multi-select, leave empty for all) |
| Product Groups | Only include invoices for specific product groups (multi-select, leave empty for all) |
Output
Configure what happens with each generated statement:
| Option | Description |
|---|---|
| Save to Archive | Save the statement to the saved statements archive (checked by default) |
| Send Email | Send the statement to the client via email with PDF attachment |
Saving
Click Save Schedule to create or update the schedule. After saving a new schedule, the page reloads with the schedule ID in the URL for future editing.
Click Cancel to return to the schedules list without saving.
PDF Style
Account Statement addon WHMCS
Order now | Download | FAQ
The PDF Style page is available at: Addons > PUQ Account Statement > Configuration > PDF Style
This page allows you to customize the appearance and content of generated PDF statements.
09-pdf-style.png
General
An informational note that PDF layout and orientation are determined by the PDF template selected in the Settings page. The Style editor controls visual appearance within the selected template.
Typography
| Setting | Description |
|---|---|
| Font Family | Choose the PDF font: Helvetica, Times, Courier, DejaVu Sans, Free Serif |
| Font Size | Base font size in points (6–24, default: 10) |
Tip: Use DejaVu Sans or Free Serif for full Unicode character support (Cyrillic, Asian characters, etc.).
Colors
| Setting | Description |
|---|---|
| Primary Color | Main color used for headings, table headers, and accents (default: #337ab7) |
| Secondary Color | Secondary color for subtitles and less prominent text (default: #555555) |
| Header Background | Background color for table header rows (default: #f5f5f5) |
Display Options
Toggle which sections appear in the generated PDF:
| Option | Description |
|---|---|
| Show Logo | Display the company logo at the top of the statement |
| Company Details | Show company name, address, and contact information |
| Client Details | Show client name, address, and contact information |
| Summary | Show the financial summary section (totals for invoices, transactions, credits) |
| Aging Report | Show the aging report section for overdue invoice analysis |
| Statement Table | Show the detailed statement table with individual line items |
| Balance | Show the running balance and final balance totals |
Custom Content
| Setting | Description |
|---|---|
| Header Text | Custom text displayed at the top of the statement (below the logo/company info) |
| Footer Text | Custom text displayed at the bottom of the statement |
| Custom CSS | Additional CSS styles applied to the PDF. Use for fine-tuning fonts, spacing, borders, etc. |
Preview
Click the Preview button to generate a sample PDF with the current (unsaved) settings. This opens the PDF in a new browser tab so you can review changes before saving.
Note: The preview uses current unsaved settings, allowing you to experiment without affecting live statements.
Saving
Click Save Template to save all style settings. These settings apply globally to all PDF statements generated by the module.
PDF Template Examples
The module includes several built-in PDF templates. The template is selected in Settings > PDF Template.
Classic (Portrait)
Traditional bank statement layout with bordered table and alternating rows.
12-pdf-classic.png
Classic (Landscape)
Same classic layout in landscape orientation, showing more columns.
13-pdf-classic-landscape.png
Modern (Portrait)
Clean modern design with color-coded summary cards and running balance column.
14-pdf-modern.png
Detailed (Portrait)
Comprehensive layout with full company details, client information, and detailed transaction table.
15-pdf-detailed.png
Modern (Landscape)
Modern layout in landscape orientation with expanded column space.
16-pdf-modern-landscape.png
Summary (Landscape)
Executive summary format with color-coded totals and compact transaction table.
17-pdf-summary-landscape.png
Custom PDF Templates
You can create custom PDF templates by adding .tpl files to the templates/pdf/ directory.
18-pdf-templates-tree.png
Each template file must start with a PHP comment header that defines its metadata:
<?php
// Template: My Custom Template
// Orientation: P
// Paper: A4
// Description: My custom statement layout
19-pdf-template-code.png
Template Header Fields
| Field | Description |
|---|---|
| Template | Display name shown in the Settings dropdown |
| Orientation | P for Portrait, L for Landscape |
| Paper | Paper size: A4, Letter, etc. |
| Description | Optional description shown as tooltip |
Available Template Variables
Templates receive the following variables:
| Variable | Description |
|---|---|
$config |
Style settings (colors, fonts, display options) from the PDF Style page |
$company |
Company details (name, address, logo, tax info) |
$statement |
Statement data (client info, period, invoices, transactions, credits, summary) |
After adding a new template file, it automatically appears in the Settings > PDF Template dropdown.
Settings
Account Statement addon WHMCS
Order now | Download | FAQ
The Settings page is available at: Addons > PUQ Account Statement > Configuration > Settings
This page controls the module's global settings including client area access, defaults, PDF template selection, email configuration, and advanced options.
10-settings.png
General
| Setting | Description |
|---|---|
| Enable Client Area | Allow clients to access the Account Statement page in the client area |
| Add to Billing Menu | Show an "Account Statement" link in the client area billing navigation menu |
| Show Payment Method | Show the payment method / gateway column in statements (admin preview, PDF, and CSV). Disable to hide it everywhere |
| Show Open Balance | Show the Open Balance line on statements. Disable to show only the Account Credit and Closing (amount owed) figures |
Defaults
Default Date Range
Set the default date range preset that is used when a client opens the statement page:
| Option | Period |
|---|---|
| This Month | First to last day of the current month |
| Last Month | First to last day of the previous month |
| This Quarter | First day of current quarter to today |
| Last Quarter | First to last day of the previous quarter |
| This Year | January 1 to December 31 of current year |
| Last Year | January 1 to December 31 of previous year |
Default Include Options
Set which financial data types are included by default when generating statements:
- Paid
- Unpaid
- Refunded
- Transactions
- Credits
PDF Template
| Setting | Description |
|---|---|
| PDF Template | Select the PDF layout template for generating statements. Available templates include Classic, Modern, Detailed — in Portrait or Landscape orientation |
The dropdown is dynamically populated from template files in the templates/pdf/ directory. Each option shows the template name and orientation.
Client Area
| Setting | Description |
|---|---|
| Client Area URL | The direct link to the client area statement page (read-only, with copy button) |
| Client Can Download PDF | Allow clients to download PDF versions of their statements |
| Client Can Download CSV | Allow clients to download CSV versions of their statements |
| Setting | Description |
|---|---|
| Email Template | Select which WHMCS email template to use when sending statements to clients |
| Create (+) | Click the + button to create the default "Account Statement" email template in WHMCS if it doesn't exist yet |
The dropdown is populated with all available WHMCS General email templates.
Email Example
When a statement is sent to a client (manually, via bulk, or via schedule), they receive an email with a PDF attachment and a summary of the statement:
20-email-statement.png
The email includes:
- PDF statement as attachment
- Statement period
- Summary table with paid/unpaid invoices, credits, account credit, and the closing balance (amount owed)
- Link to view the statement online
Advanced
| Setting | Description |
|---|---|
| Statement Expiry Days | Number of days before shared statement links expire. Set to 0 for links that never expire (default: 30) |
| Auto Cleanup Days | Automatically delete saved statements older than this many days. Set to 0 to disable auto-cleanup (default: 90) |
| Per Page | Number of records per page in statement lists (5–100, default: 25) |
Saving
Click Save Settings to save all configuration changes.
Client Area
Account Statement addon WHMCS
Order now | Download | FAQ
This page describes the client-facing Account Statement functionality available in the WHMCS client area.
Accessing the Client Area Page
Clients can access their Account Statement page in two ways:
Note: The client area page is only available when "Enable Client Area" is checked in the module Settings.
When "Add to Billing Menu" is enabled, clients reach the page from Billing > Account Statement in the client area navigation:
22-client-billing-menu.png
11-client-area.png
Generate Statement
The top section allows clients to generate their own account statements:
Date Range
- Date From / Date To — manual date pickers
- Quick Period buttons — one-click presets: This Month, Last Month, This Year, Last Year
Include Options
Checkboxes to select what financial data to include:
- Paid, Unpaid, Refunded, Transactions, Credits
Action Buttons
| Button | Description | Visibility |
|---|---|---|
| View | Generate and display the statement preview inline | Always visible |
| Download PDF | Download the statement as a PDF file | Only if "Client Can Download PDF" is enabled in Settings |
| Download CSV | Download the statement data as a CSV file | Only if "Client Can Download CSV" is enabled in Settings |
Statement Preview
After clicking View, the generated statement is displayed inline below the form. The preview shows the same rendered HTML statement that administrators see.
23-client-area-preview.png
Saved Statements
The bottom section shows the client's previously saved statements (generated by admin, schedule, or bulk operations):
| Column | Description |
|---|---|
| Date | When the statement was generated |
| Period | Statement date range (from — to) |
| Generated By | How the statement was created: manual, schedule, or bulk |
| Actions | Download buttons and view link |
Actions Per Saved Statement
| Button | Description | Visibility |
|---|---|---|
| Download the statement as PDF | Always visible | |
| CSV | Download the statement as CSV | Only if "Client Can Download CSV" is enabled |
| View | Open the statement via public link (if available) | Only if statement has an access hash |
Pagination
When there are multiple pages of saved statements, pagination controls appear below the table with page numbers and previous/next navigation.
Important Notes
- Clients can only see their own statements — all requests are filtered by the logged-in client's ID
- The client area uses Bootstrap 4 styling (WHMCS client area) rather than Bootstrap 3 (admin area)
- Download buttons (PDF/CSV) respect the permission settings configured in the admin Settings page
- The statement is generated with the client's configured currency