I need to add RegexValidator to URLField. It works, but I want to customize it's message.
I added parameter message with my custom text, but it still shows
Enter a valid URL." instead of my text
Django version: 2.1.5
class ExampleModel(models.Model):
url_address = models.URLField(
validators=[RegexValidator('https://www.google.com/.*', message='This is not a Google URL')])
code='invalid_url'as your last parameter of RegexValidator.