ICT:VisualEditor installation
VisualEditor Integration on AlmaLinux MediaWiki
Purpose
This page documents the exact VisualEditor configuration used on the AlmaLinux MediaWiki server behind the IIS reverse proxy. It is written for future administrators who need to:
- Understand how VisualEditor is enabled
- Verify the configuration after upgrades
- Troubleshoot REST/Parsoid issues
- Avoid historical detours that are no longer relevant
The key point: VisualEditor works out of the box because the stack is now clean, predictable, and standard.
Current Status
- VisualEditor: enabled and working
- REST/Parsoid: handled by MediaWiki’s built‑in REST interface
- Reverse proxy: no VisualEditor‑specific rules required
- AlmaLinux Apache: standard MediaWiki rewrite rules only
- No Synology/WebStation/nginx interference anymore
If MediaWiki works with clean URLs, VisualEditor works too.
Actual Configuration Snippet
This is the exact snippet currently active in LocalSettings.php:
#---VisualEditor -----------
wfLoadExtension( 'VisualEditor' );
$wgDefaultUserOptions['visualeditor-enable'] = 1;
$wgVisualEditorEnableWikitext = true;
$wgVisualEditorRestbaseURL = '/rest.php';
$wgVisualEditorFullRestbaseURL = 'https://mwiki.costasano.club/rest.php';
$wgVirtualRestConfig['modules']['parsoid'] = [
'url' => 'http://localhost/rest.php',
'domain' => 'localhost',
'forwardCookies' => true
];
#---end VisualEditor --------------
Explanation of Each Setting
Extension loading
wfLoadExtension( 'VisualEditor' );
Loads the VisualEditor extension.
Enable VisualEditor for all users
$wgDefaultUserOptions['visualeditor-enable'] = 1;
Ensures VisualEditor is enabled by default.
Enable wikitext mode inside VisualEditor
$wgVisualEditorEnableWikitext = true;
Allows switching between VisualEditor and wikitext.
RESTBase / Parsoid endpoints
$wgVisualEditorRestbaseURL = '/rest.php';
$wgVisualEditorFullRestbaseURL = 'https://mwiki.costasano.club/rest.php';
These define where VisualEditor finds the REST interface:
- Relative URL for internal calls
- Full URL for browser‑side calls
Virtual REST configuration
$wgVirtualRestConfig['modules']['parsoid'] = [
'url' => 'http://localhost/rest.php',
'domain' => 'localhost',
'forwardCookies' => true
];
This works because:
- MediaWiki calls Parsoid internally via
localhost - No HTTPS or hostname mismatch
- No reverse proxy involvement
- Cookies are forwarded for logged‑in editing
Why This Works Now
VisualEditor is sensitive to:
- protocol mismatches
- hostname mismatches
- broken reverse proxy rewrites
- missing REST endpoints
- inconsistent
$wgServer
Your environment is now:
- clean
- consistent
- predictable
- free of Synology nginx overrides
- free of DSM regeneration side effects
So VisualEditor finally behaves exactly as documented.
Verification Checklist
After upgrades or changes, verify:
/rest.phploads/api.phploads- Editing a page opens VisualEditor
- Saving works
- No errors in browser console
- No 403/404/502 errors in logs
If all of these pass, VisualEditor is healthy.
Troubleshooting (for future admins)
VisualEditor stuck on loading
- Check browser console for REST errors
- Verify
/rest.phpis reachable externally - Verify
http://localhost/rest.phpis reachable internally
403 or 404 errors
- Check Apache vhost
- Check SELinux (if enforcing)
- Check IIS reverse proxy rules
Mixed content errors
- Ensure
$wgServeruseshttps://mwiki.costasano.club
Change History
- 2025‑12‑27 — VisualEditor re‑enabled
- The VisualEditor snippet was restored after the MediaWiki environment was stabilized with clean URLs and a simplified reverse proxy.
- It worked immediately without any additional changes.