Making scripts https compatible