mirror of
https://github.com/silverstripe/silverstripe-reports
synced 2024-10-22 11:05:53 +02:00
MINOR Remove use of deprecated ereg_replace() and use preg_replace() instead.
This commit is contained in:
parent
8166c26a8f
commit
1ab76865ea
@ -102,8 +102,8 @@ class FilesystemPublisher extends StaticPublisher {
|
|||||||
// perform similar transformations to SiteTree::generateURLSegment()
|
// perform similar transformations to SiteTree::generateURLSegment()
|
||||||
$urlSegment = str_replace('&','-and-',$urlSegment);
|
$urlSegment = str_replace('&','-and-',$urlSegment);
|
||||||
$urlSegment = str_replace('&','-and-',$urlSegment);
|
$urlSegment = str_replace('&','-and-',$urlSegment);
|
||||||
$urlSegment = ereg_replace('[^A-Za-z0-9\/-]+','-',$urlSegment);
|
$urlSegment = preg_replace('/[^A-Za-z0-9\/-]+/', '-', $urlSegment);
|
||||||
$urlSegment = ereg_replace('-+','-',$urlSegment);
|
$urlSegment = preg_replace('/-+/', '-', $urlSegment);
|
||||||
$urlSegment = trim($urlSegment, '/');
|
$urlSegment = trim($urlSegment, '/');
|
||||||
|
|
||||||
$filename = $urlSegment ? "$urlSegment.$this->fileExtension" : "index.$this->fileExtension";
|
$filename = $urlSegment ? "$urlSegment.$this->fileExtension" : "index.$this->fileExtension";
|
||||||
|
Loading…
Reference in New Issue
Block a user