question about rename()

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
m3rajk
DevNet Resident
Posts: 1191
Joined: Mon Jun 02, 2003 3:37 pm

question about rename()

Post by m3rajk »

will it overwrite if there is already a file there? i need to know if a later thing i'm going to be doing needs to delete the file or not
User avatar
JAM
DevNet Resident
Posts: 2101
Joined: Fri Aug 08, 2003 6:53 pm
Location: Sweden
Contact:

Post by JAM »

On *nix, yes.
On win, no.

Because on *nic systems, the rename command first removes the 'link' then replaces it with the new (i think).

On Windows, well... Rename does whats its named.
Last edited by JAM on Sat Aug 09, 2003 7:31 pm, edited 1 time in total.
m3rajk
DevNet Resident
Posts: 1191
Joined: Mon Jun 02, 2003 3:37 pm

Post by m3rajk »

just another failure of winblows.

i'm developing on a LAMP environment and hope to find a LAMP environment to deploy on. my experience shows the posix family is actually stable, something windows will NEVER be able to claim at their current pace
User avatar
JAM
DevNet Resident
Posts: 2101
Joined: Fri Aug 08, 2003 6:53 pm
Location: Sweden
Contact:

Post by JAM »

m3rajk wrote:just another failure of winblows.
Cant agree... rename for me per se is just 'rename' as I can imagine most windows user think.

*nix is good, but is PHP just intended for *nix-users? Dont slap me for it, but a overwrite() function should be more properly describing... ;)
m3rajk
DevNet Resident
Posts: 1191
Joined: Mon Jun 02, 2003 3:37 pm

Post by m3rajk »

i have an issue with anyone who thinks winblows is meant for programming of any type.

how can you construct a solid program on a operating system that's full of memory leaks?


in all honesty, as someone i know that's done sys admin for about a decade once said "a computer should never NEED to be restarted short of a major kernel change, unless you're talking about windows"

the reason windows NEEDS it is the inherint memory leaks.

you cannot program on that and stop your memory leaks and make a solid program. you can port there and java makes that simple as pie, but don't create there.

(yeah, i started out a programmer, not a scripter.)
m3rajk
DevNet Resident
Posts: 1191
Joined: Mon Jun 02, 2003 3:37 pm

Post by m3rajk »

yes i know i'm on a winblows box. it's called being compatible with the world. this one is split. when i wanna talk to the world i'm on winblows. when i program i'm on linux. my development server is LAMP ... my development server for this site i'm working on is a seperate computer.
User avatar
JAM
DevNet Resident
Posts: 2101
Joined: Fri Aug 08, 2003 6:53 pm
Location: Sweden
Contact:

Post by JAM »

m3rajk wrote:yes i know i'm on a winblows box. it's called being compatible with the world....
I rest my case...
m3rajk
DevNet Resident
Posts: 1191
Joined: Mon Jun 02, 2003 3:37 pm

Post by m3rajk »

just becasue most people are way too stupid to use a well made operating system doesn't mean that the servers shouldn't be stable. i understand giving workstations as winblows when you're not in a development environment, but beyond that it's called "the people in charge are idiots" (ie: it's ripped outta dilbert)
User avatar
JAM
DevNet Resident
Posts: 2101
Joined: Fri Aug 08, 2003 6:53 pm
Location: Sweden
Contact:

Post by JAM »

What has stupidity got to do with what users prefer in an os?

And no, I cant agree otherwise.
macewan
Forum Commoner
Posts: 97
Joined: Mon Jul 07, 2003 8:27 pm

Post by macewan »

m3rajk wrote:i have an issue with anyone who thinks winblows is meant for programming of any type.
hehe.

windows is for programming and aol is for the internet.
Post Reply