473,387 Members | 1,897 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

File Name case check

Hi,
Has anyone come across a utility to check the case of a filename versus a
php page? I develop locally on a windows machine (Know Know) then upload to
a Linux and everything works usually works fine. But I sure would like to
eliminate this headache.

--
God Bless you,
Al Kolff

Jul 17 '05 #1
7 3802
On Tue, 12 Jul 2005 19:57:32 GMT, "Al Kolff" <al*****@spam.sucks.earthlink.net>
wrote:
Has anyone come across a utility to check the case of a filename versus a
php page?
What do you mean?
I develop locally on a windows machine (Know Know) then upload to
a Linux and everything works usually works fine. But I sure would like to
eliminate this headache.


I don't understand what headache you are having.

Personally, I always use lowercase filenames, and so don't need to worry about
case-insensitive filesystems.

--
Andy Hassall / <an**@andyh.co.uk> / <http://www.andyh.co.uk>
<http://www.andyhsoftware.co.uk/space> Space: disk usage analysis tool
Jul 17 '05 #2

"Andy Hassall" <an**@andyh.co.uk> wrote in message
news:se********************************@4ax.com...
On Tue, 12 Jul 2005 19:57:32 GMT, "Al Kolff" <al*****@spam.sucks.earthlink.net> wrote:
Has anyone come across a utility to check the case of a filename versus a
php page?
What do you mean?
I develop locally on a windows machine (Know Know) then upload to
a Linux and everything works usually works fine. But I sure would like to
eliminate this headache.


I don't understand what headache you are having.

Personally, I always use lowercase filenames, and so don't need to worry

about case-insensitive filesystems.

--
Andy Hassall / <an**@andyh.co.uk> / <http://www.andyh.co.uk>
<http://www.andyhsoftware.co.uk/space> Space: disk usage analysis tool


Andy,
I also usually use all lowercase file names. But, I down loaded the
ISchoolAd scripts.
and in some pages the filenames are capitalized and in others they are not.
Same for folder names. Same for filenames.
Because I loaded and checked it on my Windows machine it worked fine .When I
uploaded it to the Linux based server there have been all kinds of
interesting things going on. So I thought someone else must have had the
same problem. And maybe they had written a search and replace that compared
file/folder names with scripts and corrected or highlighted them.
al

Jul 17 '05 #3
SOR
<comp.lang.php , Al Kolff , al*****@spam.sucks.earthlink.net>
<kZ*****************@newsread2.news.pas.earthlink. net>
<Tue, 12 Jul 2005 23:01:36 GMT>
I also usually use all lowercase file names. But, I down loaded the
ISchoolAd scripts.
and in some pages the filenames are capitalized and in others they are not.
Same for folder names. Same for filenames.
Because I loaded and checked it on my Windows machine it worked fine .When I
uploaded it to the Linux based server there have been all kinds of
interesting things going on. So I thought someone else must have had the
same problem. And maybe they had written a search and replace that compared
file/folder names with scripts and corrected or highlighted them.


It doesnt sound too hard to write .

- find a php display folders loop like the one on www.phpemail.co.uk and
adapt it to suit

- grab the filename of each file

- check for uppercase characters

- change to lowercase if needed and edit/save the filename

Somebody more experienced can tell you how to 'also' check the sub
folders if you want to do it that way .

Jul 17 '05 #4

"SOR" <we*******@sparesorrepair.co.uk.INVALID> wrote in message
news:MP************************@no-cancel.newsreader.com...
<comp.lang.php , Al Kolff , al*****@spam.sucks.earthlink.net>
<kZ*****************@newsread2.news.pas.earthlink. net>
<Tue, 12 Jul 2005 23:01:36 GMT>
I also usually use all lowercase file names. But, I down loaded the
ISchoolAd scripts.
and in some pages the filenames are capitalized and in others they are not. Same for folder names. Same for filenames.
Because I loaded and checked it on my Windows machine it worked fine ..When I uploaded it to the Linux based server there have been all kinds of
interesting things going on. So I thought someone else must have had the
same problem. And maybe they had written a search and replace that compared file/folder names with scripts and corrected or highlighted them.


It doesnt sound too hard to write .

- find a php display folders loop like the one on www.phpemail.co.uk and
adapt it to suit

- grab the filename of each file

- check for uppercase characters

- change to lowercase if needed and edit/save the filename

Somebody more experienced can tell you how to 'also' check the sub
folders if you want to do it that way .


I'm trying to do that right now and if I get it to work I'll upload to one
of the script sharing sites. Till then I had a flash - Why not just put two
copies of the file in the folder with different Test.gif and test.gif. It
sure isn't elegant but it works for now till I get the code cleaned up.

Thanks for the suggestion it kick started my brain.
al
Jul 17 '05 #5

"Al Kolff" <al*****@spam.sucks.earthlink.net> wrote in message
news:IC*****************@newsread2.news.pas.earthl ink.net...

"SOR" <we*******@sparesorrepair.co.uk.INVALID> wrote in message
news:MP************************@no-cancel.newsreader.com...
<comp.lang.php , Al Kolff , al*****@spam.sucks.earthlink.net>
<kZ*****************@newsread2.news.pas.earthlink. net>
<Tue, 12 Jul 2005 23:01:36 GMT>
> I also usually use all lowercase file names. But, I down loaded the
> ISchoolAd scripts.
> and in some pages the filenames are capitalized and in others they are not. > Same for folder names. Same for filenames.
> Because I loaded and checked it on my Windows machine it worked fine .When I > uploaded it to the Linux based server there have been all kinds of
> interesting things going on. So I thought someone else must have had
> the
> same problem. And maybe they had written a search and replace that compared > file/folder names with scripts and corrected or highlighted them.
>


It doesnt sound too hard to write .

- find a php display folders loop like the one on www.phpemail.co.uk and
adapt it to suit

- grab the filename of each file

- check for uppercase characters

- change to lowercase if needed and edit/save the filename

Somebody more experienced can tell you how to 'also' check the sub
folders if you want to do it that way .


I'm trying to do that right now and if I get it to work I'll upload to one
of the script sharing sites. Till then I had a flash - Why not just put
two
copies of the file in the folder with different Test.gif and test.gif. It
sure isn't elegant but it works for now till I get the code cleaned up.

Thanks for the suggestion it kick started my brain.
al


How about
strtolower -- Make a string lowercase

Also, there is the string comparison ignoring case.

Shelly
Jul 17 '05 #6

"Shelly" <sh************@asap-consult.com> wrote in message
news:xJ********************@comcast.com...

"Al Kolff" <al*****@spam.sucks.earthlink.net> wrote in message
news:IC*****************@newsread2.news.pas.earthl ink.net...

"SOR" <we*******@sparesorrepair.co.uk.INVALID> wrote in message
news:MP************************@no-cancel.newsreader.com...
<comp.lang.php , Al Kolff , al*****@spam.sucks.earthlink.net>
<kZ*****************@newsread2.news.pas.earthlink. net>
<Tue, 12 Jul 2005 23:01:36 GMT>

> I also usually use all lowercase file names. But, I down loaded the
> ISchoolAd scripts.
> and in some pages the filenames are capitalized and in others they are
not.
> Same for folder names. Same for filenames.
> Because I loaded and checked it on my Windows machine it worked fine

.When I
> uploaded it to the Linux based server there have been all kinds of
> interesting things going on. So I thought someone else must have had
> the
> same problem. And maybe they had written a search and replace that

compared
> file/folder names with scripts and corrected or highlighted them.
>

It doesnt sound too hard to write .

- find a php display folders loop like the one on www.phpemail.co.uk
and adapt it to suit

- grab the filename of each file

- check for uppercase characters

- change to lowercase if needed and edit/save the filename

Somebody more experienced can tell you how to 'also' check the sub
folders if you want to do it that way .


I'm trying to do that right now and if I get it to work I'll upload to

one of the script sharing sites. Till then I had a flash - Why not just put
two
copies of the file in the folder with different Test.gif and test.gif. It sure isn't elegant but it works for now till I get the code cleaned up.

Thanks for the suggestion it kick started my brain.
al


How about
strtolower -- Make a string lowercase

Also, there is the string comparison ignoring case.

Shelly


Thank you! That will make it work I think.
al
Jul 17 '05 #7
> I had a flash - Why not just put two copies of the file in the folder
with different Test.gif and test.gif.


You could use soft or hard linking. It's transparent for Apache and
this way you will not end up having "Test.gif" and "test.gif" being
different pictures.

Hilarion
Jul 17 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Abhas | last post by:
> > Hi, this is Abhas, > > I had made a video library program in C++, but was facing a problem. > > After entering 12 movies, i cannot enter any more movies. > > Something gibberish comes instead....
5
by: Chathu | last post by:
Hello everyone........... I have a problem on retriving a content of a binary file I wrote into. My program user structures, dynamic allocation of memory and files. I take the infomation into a...
5
by: Jefferis NoSpamme | last post by:
Hi all, I'm trying to limit the file size of an image submission and I keep running into various problems. I've got most of it working, but I'm stumped and I have a basic question as to WHY this...
1
by: laredotornado | last post by:
Hi, I'm using PHP 4.4.4 on Apache 2 on Fedora Core 5. PHP was installed using Apache's apxs and the php library was installed to /usr/local/php. However, when I set my "error_reporting"...
7
by: B. Williams | last post by:
I wrote a program that would simply output data to the screen, but now I am trying to have the data saved to a file. I don't have a problem creating the file or even outputting data to it when there...
5
by: B. Williams | last post by:
I need some assistance with random access file processing. I have a function that I would like to change from sequential file processing to random access. Thanks in advance. void...
8
by: ctiggerf | last post by:
I was hopeing someone could help me out here. Been stumped on this one all day. This function 1. Checks uploaded files. 2. Creates two resized images from each (a full size, and a...
21
nathj
by: nathj | last post by:
Hi, I am currently working on a new site that offers various files for download. The file information is stored in a MySQL database and the page is produced in PHP depending on how the user got...
1
by: shyaminf | last post by:
hi everybody! iam facing a problem with the transfer of file using servlet programming. i have a code for uploading a file. but i'm unable to execute it using tomcat5.5 server. kindly help me how to...
4
by: shaieen | last post by:
#include<stdio.h> #include<conio.h> #include<string.h> main(){ typedef struct info { char fname(void),mname(void),famname(void); int age,cont; char adr; }...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.