Batch URL renamer script

Hi all!,

First and formost it is great to find a community of people interested in helping (people like me) with scripting! Thank you so much!

Getting to my issue at hand, basically I am trying to share files from my FTP server. In order for me to share these files I need to add my username to the url that cyberduck gives me. The thing is that I have way to many files to manually edit these in text edit.

It would be great if someone has a script that can do this or maybe someone can point me in the right direction on how to write one myself.

I appreciate everything!

natural.mystic

Model: 13" macbook prp
Browser: Chrome
Operating System: Mac OS X (10.6)

You basically need to know how to add strings together. Use “&” to do that. So if you have the url (which is a string) and your username (which is a string) then you can add them like this…

set string1 to "some"
set string2 to "text"
set addedString to string1 & string2

set userName to "Name"
set userPass to "thepassword"
set theHostDir to "[url=ftp://ftp.somehost.com/thedir/]ftp.somehost.com/thedir/[/url]"

set fullURL to "ftp://"&userName&":"&userPass&"@"&theHostDir