Il nome utente o la password che hai inserito non sono corretti.

Iscrizione

Purtroppo questo nome utente esiste gia'!

Questo indirizzo e-mail esiste gia!

Il codice di verifica non coincide

Tutti i campi sono obbligatori

RSJoomla! Forum :: Topic: validation with default value exclusion (1/1)

Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: validation with default value exclusion

validation with default value exclusion 1 year 5 months ago #15669

Hello,

for some fields I use additional attributes like
onblur="if(this.value == '') { this.value='name'}" onfocus="if (this.value == 'name') {this.value=''}"

The default value is „name“. How can I exclude this value from the validation? In other words: If there is the default value, this field should be sign as an error after form send. Thanks for reply.
The administrator has disabled public write access.

Re: validation with default value exclusion 1 year 5 months ago #15676

I find the solution by myself. To exclude the default value, use the "Regex Validation Rule" with the following syntax:
'^(?!name)'

In this case "name" is the default value. To match two words, use "your.name" instead of "name".
The administrator has disabled public write access.

Re: validation with default value exclusion 1 year 6 days ago #17410

  • PreArt
  • PreArt's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 3
  • Thank you received: 1
I'm looking for the same, but I don't know how to use it

'^(?!name)'

Could You please help me, where i should put code?
The administrator has disabled public write access.
  • Page:
  • 1
Powered by Kunena Forum
Feedback