Why password element is not red if omitted?

I mean:
If an element is mandatory but omitted, after confirm form it is displayed in red; but this don't happen for password element.

I use the same form for not registered users (so it has to be inserted, red if omitted) and for registered (so it has to be optional).
What I wrong?
 
I use the same form for
  • a) user registration
  • b) user improvement (from Simpatizzante to Socio).
Case a)
Password mandatory (obvious); if the user don't insert it, it has to be displayed in red.

Case b)
Password not mandatory (but the user can change it); if the user don't insert it, it has to be displayed normally.

If I don't set validation and the user don't insert it, in the case a) it is not displayed in red.

I tried to use the validation "not empty" and conditional validation:
return '{fabrik_table___id_user_last_modification}' =='';​
id_user_last_modification is a user plugin Update on edit (it has no value in the case a) because the user is not logged in)​
but in the case a) if the user don't insert it, it is not displayed in red.
 
The password element is not "per se" mantadory, you have to set the notempty validation.

Not sure if you can use element placeholders in validations. At least the tooltip for the php validation code says "This element's value is in $data. Other element values can be found in $_REQUEST (use JFactory::getApplication()->input->get() to access)."

But you can use {$my->id} (0 for guests, userid for logged in users)
So try a condition
return '{$my->id}' == '0';
 
You've probably seen some members of the original Python cast in movies, like maybe John Cleese.

They had a huge influence on British (and to a certain extent American) comedy, and my generation (and several after that) can recite entire Monty Python comedy sketches from memory.

They are also well known for their social satire, and taking on subjects which most comedians wouldn't. The clip I linked to is from their movie "The Life of Brian", which offended a lot of people, but is (IMHO) one of the funniest movies ever made. It's about a man who gets mistaken for the Messiah ... but as his mother says in that clip, "He's not the Messiah, he's just a very naughty boy".

-- hugh
 
Ok,
  1. You are a very naughty boy. :)
  2. You convinced me: I will search on the web some Monty Python's comedy (in Italian language: I'm not very familiar with the English language as my sons).
If I will come in the US, I definitely want to meet you.
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top