PHP Classes

file names with special characters

Recommend this page to a friend!

      PHP SPL File Find  >  All threads  >  file names with special characters  >  (Un) Subscribe thread alerts  
Subject:file names with special characters
Summary:File names with special characters break the script
Messages:1
Author:Viktor Nagornyy
Date:2018-06-27 02:20:26
 

  1. file names with special characters   Reply   Report abuse  
Picture of Viktor Nagornyy Viktor Nagornyy - 2018-06-27 02:20:26
Not sure if you still support/update this script. It's very helpful, thank you!

I noticed that file names with special characters will break the script. This forum is converting special characters into html entities, so I can't post a good example. File names in errors below are not accurate because special characters were converted to html entities.

---
Fatal error: Uncaught RuntimeException: SplFileInfo::getSize(): stat failed for C:\wamp64\www\dev6\wp-content\uploads\2015\12\Stocking-Fillers-for-Kids-For-Under--�10-1000x560.jpg in C:\wamp64\www\dev6\find\Iterators\FileSizeIterator.php on line 26
---

---
RuntimeException: SplFileInfo::getSize(): stat failed for C:\wamp64\www\dev6\wp-content\uploads\2015\12\Stocking-Fillers-for-Kids-For-Under--�10-1000x560.jpg in C:\wamp64\www\dev6\find\Iterators\FileSizeIterator.php on line 26
---

I thought I'll let you know, in case you want to update the script.