LMSouq
moodle-core Open

How to validate custom fields in moodle

ER
Ermanno Palmizio Salieri
1 month ago
3 views
Problem Description
is there a way to add regex validation in custom fields for signing up in moodle? I'm tricking with the signup_form.php and signup.php files but i can't manage to achieve it. I added some fields with the addelement() function and addrule() but it would be a problem in upgrading. How can i validate fields via lib.php? Really thanks for your answer

AI-Generated Solution

Powered by LMSouq AI · GPT-4.1-mini

✓ Solution Ready
Analyzing problem and generating solution…
Was this solution helpful?
Back to Knowledge Base