Support

  1. Laurent Zotto
  2. General
  3. Monday, October 17 2016, 03:30 PM
Hello

I have implemented EaysProfile successfully.
I'm now wondering if I can add an allowed pattern for a profile field, i.e.: PHONE must begin with a country code, like (+33, +1, +352) .. and make this appear in the resulting error message if this is not the case.

For now, on my web page the PHONE filed without a country code is not allowed, bu when entering a phone numeber like "12 34 567" I simple get the message "wrong field PHONE".

I there a solution to this? Thank you in advance

Regards
Laurent
Accepted Answer
Laurent Zotto Accepted Answer
Good, I was already wondering what this is for...
$Thank you, I will try so.
  1. more than a month ago
  2. General
  3. # Permalink
admin Accepted Answer
Admin
Hi,
unfortunately we not have control about phone validation (it comes from HTML5 + Joomla validation).

Anyway you can use a Text field type and add your custom format. see screenshots.

Something like

[0-9 ]+
should allow numbers and spaces
Attachments (1)
  1. more than a month ago
  2. General
  3. # 1
Laurent Zotto Accepted Answer
Obviously the validation works, but the message is not clear on what is wrong!
  1. more than a month ago
  2. General
  3. # 2
admin Accepted Answer
Admin
I know, but message comes from Joomla, not Easy Profile, JForm API of Joomla not allow natively to add error messages on client validation.
Keep in mind that Easy Profile extends Joomla user management (not replace), so registration form is the same of Joomla and it uses Joomla validator.

You need to write some javascript function to customize your message.

Or more simple:
- add description in phone field (this will be shown as tip, see screenshot)
- add HTML delimiter after phone field to describe valid format
Attachments (2)
  1. more than a month ago
  2. General
  3. # 3
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.

Request Support

Support is currently Online

Support Availability

Working days: Monday to Friday. The support staff is not available on weekends; in the most of cases tickets will not be answered during that time.

Reply time: Depending on the complexity of your support issue it's usually between a few minutes and 24 hours for paid members and about one week for free members. When we expect longer delays we will notify you.

Guidelines

Before you post: read the documentation and search the forums for an answer to your question.

When you post: include Site Details if you request a support (you can use the form below the reply in Site Details tab).

Auto Solved Question: If after a week the author of the post does not reply to a request by moderator, the question will be marked as resolved.

Language: only English

Search Users

Easy Profile® is not affiliated with or endorsed by Open Source Matters or the Joomla Project. Joomla is Free Software released under the GNU/GPL License.