Click to See Complete Forum and Search --> : filenames


wlebargy
04-29-2003, 12:51 PM
Can you change a filename on your server via a javascript form?

Jona
04-29-2003, 12:52 PM
No. You must use a PHP, ASP, or CGI/Perl script.

wlebargy
04-29-2003, 01:05 PM
How do I do it with PHP?

Jona
04-29-2003, 01:05 PM
First find out or make sure that your server supports PHP, and that you can run PHP scripts.

wlebargy
04-29-2003, 01:11 PM
I can, I know that, but I need the code tochange a filename.

Jona
04-29-2003, 01:21 PM
Try looking at http://php.net/ or http://zend.com/

Bootsman123
04-29-2003, 01:27 PM
http://www.php.net/manual/nl/function.rename.php

pyro
04-29-2003, 01:32 PM
It's quite simple...

rename ("dir/oldfilename.ext", "dir/newfilename.ext");

Jona
04-29-2003, 01:39 PM
Originally posted by pyro
It's quite simple...

Give me a break.... I just started learning PHP... I could've figured it out... BTW, that chatpost.php file you made... I've added a bunch to it, and made it a lot better--even fixed a bunch of security bugs and stuff. ;) (You can check it out online at http://jona.t35.com/mjdimick.html )

pyro
04-29-2003, 01:42 PM
Originally posted by Jona
Give me a break....Sorry... All I meant was that it didn't take much code... ;)

Cheers!

Jona
04-29-2003, 01:43 PM
I know. :)