mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
Doc
This commit is contained in:
parent
7cdfe05862
commit
95a125128e
|
|
@ -98,7 +98,7 @@ if (GETPOST('sendit', 'alpha') && !empty($conf->global->MAIN_UPLOAD_DOC) && !emp
|
|||
|
||||
// Check URL is external
|
||||
if (!getDolGlobalString('MAIN_ALLOW_SVG_FILES_AS_EXTERNAL_LINKS')) {
|
||||
if (!empty($newUrlArray['path']) && preg_match('/\.svg/i', $newUrlArray['path'])) {
|
||||
if (!empty($newUrlArray['path']) && preg_match('/\.svg$/i', $newUrlArray['path'])) {
|
||||
$error++;
|
||||
$langs->load("errors");
|
||||
setEventMessages($langs->trans('ErrorSVGFilesNotAllowedAsLinksWithout', 'MAIN_ALLOW_SVG_FILES_AS_EXTERNAL_LINKS'), null, 'errors');
|
||||
|
|
@ -106,7 +106,7 @@ if (GETPOST('sendit', 'alpha') && !empty($conf->global->MAIN_UPLOAD_DOC) && !emp
|
|||
}
|
||||
// Alow external links to svg ?
|
||||
if (!getDolGlobalString('MAIN_ALLOW_LOCAL_LINKS_AS_EXTERNAL_LINKS')) {
|
||||
// Test $newUrlAray['host'] to check link is external
|
||||
// Test $newUrlAray['host'] to check link is external using isIPAllowed()
|
||||
// TODO
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user