Skip to content

Commit ceed225

Browse files
committed
Merge branch '4.0' into 'main'
2 parents 9ce1295 + 34366de commit ceed225

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

docs/administration.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,8 @@ time with all the relevant data of the specific entry. The meaning of the fields
9696
The content is an answer to the question or a solution for a problem. The content can be edited with the included
9797
WYSIWYG (**W**hat **Y**ou **S**ee **I**s **W**hat **Y**ou **G**et) editor when JavaScript is enabled. You can place
9898
images where you want with the integrated image manager. The Editor can be disabled in the configuration if you want.
99+
One important thing to remember is that you need to allow external hosts for images or videos in the configuration if
100+
you want to use images from external sources.
99101

100102
- **Language**
101103
You can select the language of your FAQ. By default, the selected language saved in the configuration will be chosen.

phpmyfaq/admin/assets/src/utils/session.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,9 @@ const toggleSessionWarningModal = (toggle: string | null): void => {
4343
};
4444

4545
const reloadCurrentPage = (): void => {
46-
const reloadButton = document.getElementById('pmf-button-reload-page');
46+
const reloadButton = document.getElementById('pmf-button-reload-page') as HTMLButtonElement;
4747
if (reloadButton) {
48-
reloadButton.addEventListener('click', () => {
48+
reloadButton.addEventListener('click', (): void => {
4949
location.reload();
5050
});
5151
}

phpmyfaq/src/phpMyFAQ/Controller/Administration/Api/ImageController.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,7 @@ public function upload(Request $request): JsonResponse
9696

9797
// Accept upload if there was no origin, or if it is an accepted origin
9898
$fileName = $timestamp . '_' . $file->getClientOriginalName();
99+
$fileName = str_replace(' ', '_', $fileName);
99100
$file->move($uploadDir, $fileName);
100101

101102
// Add to the list of uploaded files

0 commit comments

Comments
 (0)