1
0
mirror of https://github.com/e107inc/e107.git synced 2025-01-17 04:38:27 +01:00

New parser filter added for file names.

This commit is contained in:
Cameron 2016-12-04 07:50:27 -08:00
parent 78e2d8f50a
commit c4d71631d8
3 changed files with 7 additions and 2 deletions

View File

@ -4369,6 +4369,11 @@ return;
return preg_replace('/[^\w\d ]/',"",$text);
}
if($type == 'file')
{
return preg_replace('/[^\w\d_\.-]/',"",$text);
}
if($validate == false)
{

View File

@ -83,7 +83,7 @@ class themeHandler
if(!empty($_POST['curTheme']))
{
$this->curTheme = e107::getParser()->filter($_POST['curTheme']);
$this->curTheme = e107::getParser()->filter($_POST['curTheme'],'file');
}
if(!empty($_POST['setUploadTheme']) && !empty($unzippedTheme))

View File

@ -47,7 +47,7 @@ else
}
else
{
$limit_start = $_POST['limit_start'];
$limit_start = intval($_POST['limit_start']);
}
$nl_count = $sql->count('newsletter', '(*)', "WHERE newsletter_parent='".$action_parent_id."' AND newsletter_flag='1'");
if ($nl_count > 0)