Skip to content

Commit a4601ae

Browse files
committed
build: updated version strings to 4.2
1 parent bf78178 commit a4601ae

File tree

12 files changed

+52
-105
lines changed

12 files changed

+52
-105
lines changed

CHANGELOG.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
1-
# phpMyFAQ 4.1
1+
# phpMyFAQ 4.2
22

3-
**Codename "Porus"**
3+
**Codename "Palaimon"**
44

55
## CHANGELOG
66

77
This is a log of major user-visible changes in each phpMyFAQ release.
88

9+
### phpMyFAQ v4.2.0-dev - unreleased
10+
11+
- n/a
12+
913
### phpMyFAQ v4.1.0-RC - 2025-12-29
1014

1115
- fixed security vulnerabilities (Thorsten)

docker-compose.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ services:
148148
- pnpm
149149

150150
pnpm:
151-
image: node:22-alpine
151+
image: node:24-alpine
152152
restart: 'no'
153153
command: sh -c "corepack enable && corepack prepare pnpm@latest --activate && pnpm install && pnpm build"
154154
working_dir: /app
@@ -195,7 +195,7 @@ services:
195195

196196
elasticsearch:
197197
image: elasticsearch:8.16.5
198-
container_name: phpmyfaq-41_elasticsearch-v8
198+
container_name: phpmyfaq-42_elasticsearch-v8
199199
restart: always
200200
environment:
201201
- cluster.name=phpmyfaq-cluster

docs/update.md

Lines changed: 35 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,29 @@
11
# 5. Updating phpMyFAQ
22

3-
First, please download the latest package of phpMyFAQ. Upgrading to phpMyFAQ 4.1 is possible from the following
3+
First, please download the latest package of phpMyFAQ. Upgrading to phpMyFAQ 4.2 is possible from the following
44
versions:
55

6-
- phpMyFAQ 3.0.x
76
- phpMyFAQ 3.1.x
87
- phpMyFAQ 3.2.x
98
- phpMyFAQ 4.0.x
109
- phpMyFAQ 4.1.x
1110

1211
If you're running an older version of phpMyFAQ than listed above, we recommend a new and fresh installation. If you need
13-
support for updating an old FAQ from the 1.x or 2.x series, [please email us](mailto:thorsten_AT_phpmyfaq_DOT_de).
12+
support for updating an old FAQ from the 1.x, 2.x, or 3.0 series, [please email us](mailto:thorsten_AT_phpmyfaq_DOT_de).
1413

1514
Please note that the requirements of phpMyFAQ have to be fulfilled.
1615

1716
## Before you upgrade
1817

1918
Please make sure that you're running at least PHP 8.3, otherwise the upgrade won't work.
2019

21-
## Upgrading from phpMyFAQ 3.0.x
20+
## Upgrading from phpMyFAQ 3.1.x
2221

23-
Upgrading from 3.0.x is a major upgrade.
24-
Your existing templates will not work with phpMyFAQ 4.1.
22+
Upgrading from 3.1.x is a major upgrade.
23+
Your existing templates will not work with phpMyFAQ 4.2.
2524
Please make a full backup before you run the upgrade!
2625
First, log in as admin into the admin section and enable the maintenance mode.
26+
(Configuration >> Edit Configuration >> Set FAQ in maintenance mode)
2727
Second, you have to delete all files **except**:
2828

2929
- in the directory **config/**
@@ -40,10 +40,10 @@ URL in your browser:
4040

4141
Click the button of the update script, your version will automatically be updated.
4242

43-
## Upgrading from phpMyFAQ 3.1.x
43+
## Upgrading from phpMyFAQ 3.2.x
4444

45-
Upgrading from 3.1.x is a major upgrade.
46-
Your existing templates will not work with phpMyFAQ 4.1.
45+
Upgrading from 3.2.x is a major upgrade.
46+
Your existing templates will not work with phpMyFAQ 4.2.
4747
Please make a full backup before you run the upgrade!
4848
First, log in as admin into the admin section and enable the maintenance mode.
4949
(Configuration >> Edit Configuration >> Set FAQ in maintenance mode)
@@ -52,6 +52,7 @@ Second, you have to delete all files **except**:
5252
- in the directory **config/**
5353
- keep the file **database.php**
5454
- only if using LDAP/ActiveDirectory support also keep the file **ldap.php**
55+
- only if using EntraID support also keep the file **azure.php**
5556
- the directory **attachments/**
5657
- the directory **data/**
5758
- the directory **images/**
@@ -63,31 +64,25 @@ URL in your browser:
6364

6465
Click the button of the update script, your version will automatically be updated.
6566

66-
## Upgrading from phpMyFAQ 3.2.x
67+
## Upgrading from phpMyFAQ 4.0.x
68+
69+
### Manual upgrade
6770

68-
Upgrading from 3.2.x is a major upgrade.
69-
Your existing templates will not work with phpMyFAQ 4.1.
7071
Please make a full backup before you run the upgrade!
7172
First, log in as admin into the admin section and enable the maintenance mode.
7273
(Configuration >> Edit Configuration >> Set FAQ in maintenance mode)
7374
Second, you have to delete all files **except**:
7475

75-
- in the directory **config/**
76-
- keep the file **database.php**
77-
- only if using LDAP/ActiveDirectory support also keep the file **ldap.php**
78-
- only if using EntraID support also keep the file **azure.php**
79-
- the directory **attachments/**
80-
- the directory **data/**
81-
- the directory **images/**
76+
- all files in the directory **content/**
8277

83-
Download the latest phpMyFAQ package and copy the contents into your existing FAQ directory, then open the following
78+
Download the latest phpMyFAQ package and copy the contents into your existing FAQ directory, the open the following
8479
URL in your browser:
8580

8681
`http://www.example.com/faq/update`
8782

8883
Click the button of the update script, your version will automatically be updated.
8984

90-
## Upgrading from phpMyFAQ 4.0.x
85+
## Upgrading from phpMyFAQ 4.1.x
9186

9287
### Manual upgrade
9388

@@ -105,7 +100,24 @@ URL in your browser:
105100

106101
Click the button of the update script, your version will automatically be updated.
107102

108-
## Upgrading from phpMyFAQ 4.1.x
103+
### Online update (Experimental feature)
104+
105+
If you're running phpMyFAQ 4.0.0 or later, you can use the built-in online update feature.
106+
Log in as admin into the admin section and enable the maintenance mode.
107+
(Configuration >> Edit Configuration >> Set FAQ in maintenance mode)
108+
Then go to the "phpMyFAQ Update" page in the configuration section and click through the update wizard:
109+
110+
1. Check for System Health: this checks if your system is ready for the upgrade
111+
2. Check for Updates: this checks if there is a new version of phpMyFAQ available
112+
3. Download of phpMyFAQ: this downloads the latest version of phpMyFAQ in the background, this can take some seconds
113+
4. Extracting phpMyFAQ: this extracts the downloaded archive, this can take a while
114+
5. Install downloaded package: first, it creates a backup of your current installation, then it copies the downloaded
115+
files into your installation, and in the end, the database is updated
116+
117+
Note:
118+
The online update feature is experimental and might not work in all environments.
119+
120+
## Upgrading from phpMyFAQ 4.2.x
109121

110122
### Manual upgrade
111123

@@ -140,7 +152,7 @@ Then go to the "phpMyFAQ Update" page in the configuration section and click thr
140152
Note:
141153
The online update feature is experimental and might not work in all environments.
142154

143-
## Modifying templates for phpMyFAQ 4.1
155+
## Modifying templates for phpMyFAQ 4.2
144156

145157
We recommend you take a look at the main [Bootstrap documentation](https://getbootstrap.com/).
146158
Please remember that the style sheets are written with [SCSS](https://sass-lang.com/).

mkdocs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
site_name: phpMyFAQ v4.1
1+
site_name: phpMyFAQ v4.2
22
theme:
33
name: readthedocs
44
highlightjs: true

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@thorsten/phpmyfaq",
3-
"version": "4.1.0-RC",
3+
"version": "4.2.0-dev",
44
"description": "phpMyFAQ",
55
"repository": "git://github.com/thorsten/phpMyFAQ.git",
66
"author": "Thorsten Rinne",

phpmyfaq/src/phpMyFAQ/Setup/AbstractSetup.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,11 @@ public function checkMinimumPhpVersion(): bool
4040
}
4141

4242
/**
43-
* We only support updates from 3.0.0 and later.
43+
* We only support updates from 3.1.0 and later.
4444
*/
4545
public function checkMinimumUpdateVersion(string $version): bool
4646
{
47-
return version_compare(version1: $version, version2: '3.0.0', operator: '>');
47+
return version_compare(version1: $version, version2: '3.1.0', operator: '>');
4848
}
4949

5050
/**

phpmyfaq/src/phpMyFAQ/Setup/Installer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,7 @@ class Installer extends Setup
268268
'main.enableUserTracking' => 'true',
269269
'main.metaDescription' => 'phpMyFAQ should be the answer for all questions in life',
270270
'main.metaPublisher' => '__PHPMYFAQ_PUBLISHER__',
271-
'main.titleFAQ' => 'phpMyFAQ Codename Porus',
271+
'main.titleFAQ' => 'phpMyFAQ Codename Palaimon',
272272
'main.enableWysiwygEditor' => 'true',
273273
'main.enableWysiwygEditorFrontend' => 'false',
274274
'main.enableMarkdownEditor' => 'false',

phpmyfaq/src/phpMyFAQ/Setup/Update.php

Lines changed: 0 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -158,12 +158,6 @@ public function checkInitialRewriteBasePath(Request $request): bool
158158
*/
159159
public function applyUpdates(): bool
160160
{
161-
// 3.1 updates
162-
$this->applyUpdates310Alpha();
163-
$this->applyUpdates310Alpha3();
164-
$this->applyUpdates310Beta();
165-
$this->applyUpdates310RC();
166-
167161
// 3.2 updates
168162
$this->applyUpdates320Alpha();
169163
$this->applyUpdates320Beta();
@@ -243,68 +237,6 @@ private function executeQueries(): void
243237
}
244238
}
245239

246-
private function applyUpdates310Alpha(): void
247-
{
248-
if (version_compare($this->version, '3.1.0-alpha', '<')) {
249-
// Add is_visible flag for user data
250-
if ('sqlite3' === Database::getType()) {
251-
$this->queries[] = sprintf(
252-
'ALTER TABLE %sfaquserdata ADD COLUMN is_visible INT(1) DEFAULT 0',
253-
Database::getTablePrefix(),
254-
);
255-
} else {
256-
$this->queries[] = sprintf(
257-
'ALTER TABLE %sfaquserdata ADD is_visible INTEGER DEFAULT 0',
258-
Database::getTablePrefix(),
259-
);
260-
}
261-
262-
// Remove RSS support
263-
$this->configuration->delete('main.enableRssFeeds');
264-
265-
// Add API-related configuration
266-
$this->configuration->add('api.enableAccess', true);
267-
$this->configuration->add('api.apiClientToken', '');
268-
269-
// Add passlist for domains
270-
$this->configuration->add('security.domainWhiteListForRegistrations', '');
271-
}
272-
}
273-
274-
private function applyUpdates310Alpha3(): void
275-
{
276-
if (version_compare($this->version, '3.1.0-alpha.3', '<')) {
277-
// Add "Login with email address" configuration
278-
$this->configuration->add('main.loginWithEmailAddress', false);
279-
}
280-
}
281-
282-
private function applyUpdates310Beta(): void
283-
{
284-
if (version_compare($this->version, '3.1.0-beta', '<')) {
285-
$this->queries[] = match (Database::getType()) {
286-
'mysqli' => sprintf(
287-
'CREATE TABLE %sfaqcategory_order
288-
(category_id int(11) NOT NULL, position int(11) NOT NULL, PRIMARY KEY (category_id))',
289-
Database::getTablePrefix(),
290-
),
291-
'pgsql', 'sqlite3', 'sqlsrv' => sprintf(
292-
'CREATE TABLE %sfaqcategory_order
293-
(category_id INTEGER NOT NULL, position INTEGER NOT NULL, PRIMARY KEY (category_id))',
294-
Database::getTablePrefix(),
295-
),
296-
};
297-
}
298-
}
299-
300-
private function applyUpdates310RC(): void
301-
{
302-
if (version_compare($this->version, '3.1.0-RC', '<')) {
303-
$this->configuration->delete('records.autosaveActive');
304-
$this->configuration->delete('records.autosaveSecs');
305-
}
306-
}
307-
308240
private function applyUpdates320Alpha(): void
309241
{
310242
if (version_compare($this->version, '3.2.0-alpha', '<')) {

phpmyfaq/src/phpMyFAQ/Setup/UpdateRunner.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,6 @@ private function withProgress(SymfonyStyle $io, callable $fn): bool
249249
};
250250

251251
try {
252-
/** @var bool $result */
253252
$result = (bool) $fn($setProgress);
254253
} finally {
255254
$progressBar->finish();

phpmyfaq/src/phpMyFAQ/System.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ class System
4444
/**
4545
* Minor version.
4646
*/
47-
private const int VERSION_MINOR = 1;
47+
private const int VERSION_MINOR = 2;
4848

4949
/**
5050
* Patch level.
@@ -54,7 +54,7 @@ class System
5454
/**
5555
* Pre-release version.
5656
*/
57-
private const string VERSION_PRE_RELEASE = 'RC';
57+
private const string VERSION_PRE_RELEASE = 'dev';
5858

5959
/**
6060
* API version.

0 commit comments

Comments
 (0)