upload fail for windows file with space in name [solved]
Archived from the Xataface Developers forum.
olivyeah — Sat Jul 31, 2010 5:11 am
Hi,
If you’ve got problems uploading windows files with space in the filename with the “widget=file & Type=container”, you can “patch” a little the Dataface/Formtool/file.php (line49):
- Code: Select all
- `//………
$filename = basename($val[‘name’]); // we use basename to guard against maliciously named files.//****add this ********************
$filename = str_replace(CHR(32),”_”,$filename);//***************************
$matches = array(); // ……..`
So all spaces in filenames becomes “_” … or whatever you want…
–
oliv
shannah — Wed Sep 01, 2010 10:55 am
Thanks. I’ve added this patch in svn rev. 1925. Will be included with next release.