quote message for url inclusion in Django middleware

Avoid error in Django middleware when building redirect URL message parameter.