Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

Input form - avoiding special characters in text field

Avatar

Avatar
Validate 10
Level 3
Partha18
Level 3

Likes

19 likes

Total Posts

29 posts

Correct Reply

2 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile

Avatar
Validate 10
Level 3
Partha18
Level 3

Likes

19 likes

Total Posts

29 posts

Correct Reply

2 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile
Partha18
Level 3

19-06-2020

Hi Team,

In a custom input form, we have a text field. Here we need to avoid few special characters like @ $ % etc.,

How can i make it possible?

 

For example,

<input xpath="@textField"/>

 

Thanks and regards,

ParthaSarathy.

View Entire Topic

Avatar

Avatar
Contributor
MVP
wodnicki
MVP

Likes

935 likes

Total Posts

1,061 posts

Correct Reply

495 solutions
Top badges earned
Contributor
Shape 1
Give Back 100
Give Back 50
Give Back 25
View profile

Avatar
Contributor
MVP
wodnicki
MVP

Likes

935 likes

Total Posts

1,061 posts

Correct Reply

495 solutions
Top badges earned
Contributor
Shape 1
Give Back 100
Give Back 50
Give Back 25
View profile
wodnicki
MVP

19-06-2020

Hi,

 

You can check on form save/close with:

<check expr="@textField not like '%@%' and ..."><error>Invalid character</error></check>

 

To replace *all* special characters with '_', at a schema level, use dataPolicy="identifier" on the attribute- no form work needed.

 

Thanks,

-Jon