Max length limit for URL attributes


In the attribute setting page for an ad, I can’t find how to limit the characters to enter for a URL.
I tried in functions.php to add $form[‘fields’][‘fieldcustomised’][‘max_length’] = 50; But it does not work. For the default Title and Description fields, it works.

Can you help me ?

Thanks a lot

Best regards


It’s possible, but requires code customizations for the hivepress/v1/fields/url filter hook. I don’t recommend this because URLs have a standard max width of 2048 characters, it’s a common restriction on the web.