Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

space in filename problem

Options
  • 01-10-2004 12:36pm
    #1
    Closed Accounts Posts: 798 ✭✭✭


    Hi

    Know this should be in web hosting but I see its closed posted in computers but this art looks better.

    Got a problem with a site, the thing looks great happy with it etc
    Except for one big problem.
    The guys who made it saved many of the files used with spaces and capitals in the file names. This means that the site can't be seen on Linux machines or on browsers other than explorer.


    Does anyone know of a program that would automatically tidy this up changing the filenames and fixing the links. Or is there some trick or quick way of doing it?


    Would greatly appreciate any help or advice.

    Thanks


Comments

  • Registered Users Posts: 7,739 ✭✭✭mneylon


    Capitalisation won't cause issues, but the spacing will be painful.

    If you have access to a shell you should be able to use a regexp with mv to rename the files to something saner.


  • Closed Accounts Posts: 19,777 ✭✭✭✭The Corinthian


    blacknight wrote:
    Capitalisation won't cause issues, but the spacing will be painful.
    Capitalisation will be an issue on Apache if the filename and links don't share the same Capitalisation.

    You can use something like Edit Plus or Text Pad to open all the files and rename the links to match the new fileneames.


  • Registered Users Posts: 7,739 ✭✭✭mneylon


    Corinthian - I was working on the premise that the poster knew the difference between:
    WoRd and word

    :)


  • Closed Accounts Posts: 798 ✭✭✭bobbyjoe


    thanks guys
    there's a lot of pages on it so going to be a bit tedious,
    but at least I'll know next time!!!!


  • Registered Users Posts: 1,031 ✭✭✭buddy


    Frontpage is great for managing things like that. Once you've converted the folders to a Frontpage Web - it does it for you - then when you rename a page and remove the space it changes the path to that page in any other page that references it.

    <<< ---- FrontPage fan!


  • Advertisement
  • Registered Users Posts: 2,808 ✭✭✭Ste.phen


    i say go with textpad, you can open all the files at once (the most i've used at once was about 50?) and do a find/replace across the entire site,
    Get a script to rename the files with spaces to have an underscore, and convert everything else to lowercase.

    I did this myself with PHP for the "photo upload" part of my site, any capitalisation or spaces are taken out before i save the file to disk.


Advertisement