substitute the result for trail. call the function escape with an argument url, substitute the result for url, call the function escape with an argument trimmed,
url , trimmed = escape ( url ) , escape ( trimmed )