[eluser]Bramme[/eluser]
Yup, and I figured out why ^^
On line 487, there's a preg_match that checks non required fields if they have a callback, it looks like this:
Code:
if (preg_match("/(callback_\w+)/", implode(' ', $rules), $match))
That \w "matches any word character (alphanumeric & underscore)". That cut off the param right away. I changed it into
Code:
if (preg_match("/(callback_.+)/", implode(' ', $rules), $match))
and now it works ^^
It's a quick and easy fix that might leave some security issues, it's possible a better regex should be written.
Maybe something along the lines of
Code:
preg_match("/(callback_[a-zA-Z0-9_\[\])/"...
No idea though if uppercase letters and or numbers are allowed in a callback (or function name, for that matter).