I've never even considered this before, but one of my clients is trying to name a file starting with a $; $template.php.
Is this allowed?
I'd like to be able to give him a reason if it's no allowed?
Thanks!
That depends entirely on what filesystem you're using. You can start a filename with $
on all of the major filesystems I know of — FAT, FAT32, NTFS, ext2, ext3, ext4, ... (Huh. My experience of file systems is actually quite limited. Interesting.)
Remember that if you're doing this from PHP, you need to be sure you're not using a string literal in double quotes, because within a string literal in double quotes, $
introduces a variable. If you're using a literal $
, either use single quotes or escape it with a backslash.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With