WickedShell / echelon

http://echelon.bigbrotherbot.net
14 stars 7 forks source link

Windows can't move config.php during setup #32

Open 82ndab-Bravo17 opened 13 years ago

82ndab-Bravo17 commented 13 years ago

Windows can't move the config.php during setup using rename because a config.php already exists in the inc folder.

Adding

            if(!rename('../inc/config.php', '../inc/config.org'))
                sendBack('Failed to rename config file');

at about line 109 solves it

WickedShell commented 13 years ago

If you can't move config.php... What are you using for a webserver? I was setup with a remote access to a windows IIS server and installed it without any issues.

ghost commented 13 years ago

Wickedshell, your account had the whole folders installed as chmod777 equivalent on windows. You would not have had any permissions issues.

WickedShell commented 13 years ago

Ah that makes sense... Argh. I'm not sure how to easily fix this. Can most webservers on windows write to they're directory's?

The only thing I can come up with is to require people to manually change the permissions before hand, which is fairly inconvenient.

82ndab-Bravo17 commented 13 years ago

I don't think that it is a permissions issue, I think it's that windows can't use rename on a file in order to move it to a place where another file of the same name exists. All I had to do was rename the original config.php file in the inc folder so that it no longer blocked the rename that moved the config.php from the install folder to the inc folder. (If that makes sense)

If you try to move the file in explorer it would be able to ask you if you were sure that you wanted to do it, but it can't do that within the program so I guess that it plays safe and stops you from doing it.