Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

File extension is change upper case to lower case in codeigniter

I am uploading file in codeigniter using

$this->upload->do_upload('image')

but when file moves to particular path the file extension is changed (it's changed to lower case)

for example if I upload file "profile.JPG" it's changes to "profile.jpg"

like image 482
Mukund Bhut Avatar asked May 20 '16 10:05

Mukund Bhut


People also ask

Can file extensions be uppercase?

Windows is intentionally case-insensitive (by default) when it comes to file names and extensions. It doesn't matter what casing you use. This was a primary design decision that Microsoft made previous to Windows in their original OS (MS-DOS) and file-system(s), to separate themselves from Unix.

Is PHP extension case sensitive?

PHP is not case sensitive with file extensions.

How do I change a lowercase file to uppercase extension?

Within Windows Explorer, right click on the file name, click on “Rename” and change the file extension to . bak and then again change it to uppercase/lowercase. In this example “. bak” extension is just an example.


1 Answers

please change CI system library

default in CI upload library $file_ext_tolower = FALSE.

.system\libraries\upload.php

public $file_ext_tolower = TRUE;
like image 193
Jaydip Satvara Avatar answered Oct 30 '22 23:10

Jaydip Satvara