file.url_name

Archived from the Transloadit support forum. Originally posted on July 16, 2012; details may be outdated, see our docs for current behavior. Original thread

I would like to suggest that the url_name variable should be included in the notification JSON.

Currently i have my own regex to create a link for the file that i store with the file.url_name in my template.

If you change your regex to make url_name, i would have a mismatch in my links. If i instead could use a url_name variable that you have created (available in the JSON notification) then they would always be the same.

Hey rasmus,

do you have an example assembly that I can take a look at that contains the url_name variable, but not in the notification?

Thanks!
Tim

Hi Tim.
You can look at : REDACTED

I realize just now that i could extract the url_name from the url property, but i still think having the url_name property would be nice as well :slight_smile:

Added to todo, will discuss with my Co-founders.

In the meantime, here is the implementation:

s = s.replace(/ /g, '-'); s = s.replace(/[^A-Za-z0-9-_\.]/g, '');

Kind regards,
Tim

Hey rasmus,

sorry for the big delay on this. I have completed this now and it’s currently in review. Should go live tonight or tomorrow.

Kind regards,
Tim