URL Script linked to Dialog Box?

Nee help with this one.
Can a application script be written to do the following:

We have to test many logos to see if they were uploaded correctly to the web. We have a URL path that can be used to test if the file was uploaded correctly. The URL is always the same, except for the last part of the URL that is associated with the filename in question.

For example: http://www.xxxxxxxxx/xxxxxxx/xxxxxx/3124567847362.jpg

I was wondering if a script could throw up a dialog box that says:

“Enter the 13 digit logo number” then hit return.

This number entered would then get combined, added to the end of the URL path (+ “.jpg”), and pasted into Safari’s URL path.?

Is this possible? This would be a very nice thing!!!
Any advice?

Thanks,

jeff

Hi Jeff,

This is without error checking (if Safari is the default browser):

set baseUrl to "http://www.xxxxxxxxx/xxxxxxx/xxxxxx/" -- Correct this!
set myNum to text returned of (display dialog "Enter the 13 digit logo number, then hit return" default answer "")
open location (baseUrl & myNum & ".jpg")

Or in one line:

open location ("http://www.xxxxxxxxx/xxxxxxx/xxxxxx/" & (text returned of (display dialog "Enter the 13 digit logo number, then hit return" default answer "")) & ".jpg")

Best wishes

John M

This is way too amazing!!! It works like a charm :slight_smile:
This will change things in our workflow in such a “Great Way”.
Many thanks!!!

jeff