Hi there,
I have been trying to solve one problem for some time but it looks like I am still far from the solution so perhaps someone could help a little. The problem is actually that I know very little about arrays still.
Here is what I need to do:
Let's say there are 3 files in a directory named:
something1.html
something2.html
something3.html
...and I want to rename them via php script to:
something_else1.html
something_else2.html
something_else3.html
Any ideas how to do this? I know how strip the number at the end and move it into array and vice versa but how do I accomplish that the script reads only the right files (filters them) from the directory ignoring the other files and then rename them to the new filename leaving the right number at the end?
I am still relatively new to php but have done some scripts already. My webhost's server has PHP 4.3.3.
Thanks for any ideas!
Tomas