Checking file creation date on the web?

Bringing the internet highway into your project? Building FTP, HTTP, email, chat or other client solutions?

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am
Location: Palo Alto

Checking file creation date on the web?

Post by Simon » Wed May 09, 2007 2:17 am

Hi,
Was wondering if anybody had code for checking the creation date of a document (.pdf) on a website?
I'm trying to update the users documents to the most current version but want to compare the two dates before I download.

Thanks,
Simon

Mark Smith
Posts: 179
Joined: Sat Apr 08, 2006 11:08 pm
Location: London, UK
Contact:

Re: Checking file creation date on the web?

Post by Mark Smith » Mon May 28, 2007 2:46 pm

Simon, you can do this with ftp.

Say your web server's address is "someServer.com" and the file is in a directory "www/files", then

Code: Select all

put URL "ftp://someServer.com/www/files/" into fld "someField"
or, if authentication is needed

Code: Select all

put URL "ftp://username:password@someServer.com/www/files/" into fld "someField"

will put a list of the files in that directory into fld "someField"

The list will include the names of the files, their creation dates and stuff like their permissions. Just parse the list to get the info you need.


Best,

Mark

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am
Location: Palo Alto

Post by Simon » Tue May 29, 2007 5:12 am

Thanks again Mark!

Post Reply

Return to “Internet”