On my local environment I require_once publiccontroller.php
and it'll load publicController.php
Unfortunately when I go to production on HostGator it will fail because it's not loosely requiring/including files. Is this a PHP or Apache thing? I need my environments to be mirrored so I'd like to change my local setting to match my production server.
Filesystem case-sensitivity is not a PHP setting, but rather specific to the OS and filesystem. Windows filesystems tend to be case-insensitive, while most other operating systems prefer case-sensitive filesystems.
Since you cannot necessarily predict what OS your code will run on in the future, it is recommended to always code for case-sensitive fileystems.
If you are currently developing on Windows (or any other OS with case-insensitive filesystems), the best course of action is to return to your code and fix all the file paths to use the correct casing, matching what they are named on disk.
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