Questions tagged [validation]
For questions related to Sitecore item and field validation rules within the Sitecore Client
80
questions
0
votes
1
answer
37
views
Validate Date entered is in yyyy/mm/dd format in Sitecore Forms
I have a text field in the Sitecore form where the user needs to enter a Date.
Currently, I am using Regex Validator that check date in mm/dd/yyyy format.
Need support to check if the date is in yyyy/...
3
votes
1
answer
57
views
Sitecore Form with multiple page displaying the field values in consequent page entered in previous page
I would like to know if the following situation is possible to handle with Sitecore Forms.
Situation: The first page contains a form, the user clicks a button under the form and it is validated, but ...
0
votes
2
answers
62
views
Sitecore Form Regex Validation to check if date is in mm/dd/yyyy format
I am using Single line Text field where user is entering date.
How to perform check if value entered is in mm/dd/yyyy format using Sitecore Regex Validation.
It should also consider leap year ...
1
vote
1
answer
95
views
Sitecore Forms upload fileType Validation
We are working on sitecore 10.3 XM. We want to apply a validation in the file upload field so that it takes only the .pdf extension files with size less than 2MB.
I was trying to implement the ...
1
vote
2
answers
206
views
Disable Form Submit button if Password and confirm password field not filled
I am trying to disable submit button if 2 fields i.e Password and Confirm Password are not filled.
However when I am trying to add condition I see Password fields are disabled and I cannot select them ...
2
votes
3
answers
224
views
Sitecore Form references non-existing JQuery version in Sitecore 10.2 during the page load
When loading a page containing a Sitecore form, the console displays exceptions related to the version of JQuery. (Note that the form in question includes validation for some of the fields.) I'm not ...
1
vote
2
answers
132
views
Disable HTML validation on a single RichText field
We have some integration running that's adding html with necessary data attributes to a RichText field, the validator is flashing this as invalid when it is valid in this use case.
How to disable the ...
0
votes
3
answers
332
views
Regex Validation For Checkbox in Sitecore Form
Is there a way to create a validation with regex pattern in Sitecore Form to check whether a checkbox is checked or not?
0
votes
0
answers
25
views
Update Validation message for Checkbox in Sitecore Forms [duplicate]
I have 2 checkbox in Sitecore Form marked as mandatory.
I need different Validation message for 2 Checkbox
Checkbox1 is required(default message)
Checkbox2 must be selected.
How to achieve different ...
1
vote
2
answers
212
views
Item Name Validation rule for hyphens
I have been successful in creating a field validation rule where the Title should not have hyphens by using a regex validation. That is working as expected. Now, I need to validate the items while ...
0
votes
1
answer
109
views
Regex validator on display name for hyphen(-) value
I need to create a regex field validator on display name such that it should not have hyphen(-) unless if there is any date in the name.
Display Name
Validation Error/ Allowed
This is a Display Name
...
1
vote
1
answer
283
views
Regex field validator does not work in Sitecore
I created a validation rule that should use regular expressions for checking if a field contains leading and trailing spaces. If it contains a space at the start or end of the field value, I expect it ...
1
vote
1
answer
386
views
Regex based string length validation in Sitecore Rich Text Editor not working
I applied one regex in the validation field to check if the entered characters in the RTE are less than 520 characters only, otherwise, it shows the error.
I've setup the validation as follows:
But ...
2
votes
2
answers
98
views
How do you get and display the Validation Rule Text field?
I'm currently implementing a custom validation logic, and I'm planning to leverage the existing fields of the Validation Rule template such as the Text field to be used as an error message. Is this ...
2
votes
1
answer
75
views
How to show validation message to the workflow window , if language checkbox not checked?
I have a requirement to show the validation message for language checkbox if no language is selected. I have used below code. It shows the alert message box but closes the workflow window. Is there a ...
2
votes
2
answers
393
views
Sitecore forms required validation is not working for dropdownlist
We have upgraded to Sitecore 10.1 from Sitecore 8.7. In Sitecore forms, dropdownlist required validation is not working.
The required validation is working for all simple type fields but not for ...
1
vote
1
answer
214
views
Sitecore Next.js Sitecore Forms Validation
I faced several issues getting the validation running with Sitecore Forms in combination with Next.js.
Issue 1: backend validation is not executed
Issue 2: backend validation was not showing up as ...
1
vote
1
answer
204
views
Field validation not working in Rendering Parameter Template for MVC form
I've assigned a Parameter Template in the MVC form rendering called Redirect Parameters (/sitecore/layout/Renderings/System/Forms/Mvc Form) as shown in below screnshot
Within this template, I've ...
0
votes
2
answers
563
views
Validation rules not working
I have applied some validation rules in template standard value as below.
When I am trying to create data item based on this template, rules are not kicking in and data is saved with empty Title ...
1
vote
1
answer
147
views
Validation problem with checkbox when using Rules Validation Rule
I've created an item rule using the Rules Validation Rule template. The rule ensures that there is a value provided for EITHER a specific text field OR a specific checkbox field.
The rule works fine ...
2
votes
1
answer
314
views
Sitecore Forms string length validator not working for other languages text
I am using a Sitecore Forms string length validator which is working perfectly fine for English content, however if I am providing content in say Japanese language then in that case it is not working.
...
0
votes
1
answer
43
views
Adding validations to marketing automation activity type parameters
I'm using Sitecore 9.3
Is it possible to add Sitecore validations to the parameters of a marketing automation activity type? I have a parameter called "Title" for example, and I'd like to ...
0
votes
1
answer
78
views
Update validation for SXA items
I am using Sitecore with SXA and I want to add validation for the SXA promo item. I need to know the best way to do this.
For more clarification, I want to add required field validation on the "...
0
votes
0
answers
61
views
How can I auto detect current form's id in Sitecore
I want to create a custom email validator to check if email exists or no to do that I must know the form's id so that to get its data I can do that using this code
ID ID = new ID("{form id}")...
1
vote
1
answer
237
views
Create Validation Rules via JSS
I'm working on a Sitecore 9.2 JSS project that needs a required field that results to FatalError. The default required field in Sitecore is using CriticalError.
I can create it manually in Sitecore ...
1
vote
1
answer
110
views
Show Multiple Validation Failures Of The Same Type In Experience Editor
I have created a few custom field validators in Sitecore and I'm running into an issue when testing them in the experience editor. For each error, I only see one banner at a time showing a failed ...
1
vote
1
answer
280
views
Enforce Site-Wide Alternate Text Validation On General Link Fields
I am working on Sitecore version 9.1. When attempting to insert a link using the general link field, the user is prompted to enter the following information:
In an effort to enforce accessibility on ...
0
votes
1
answer
154
views
Custom CSS for Validation Message in webform for marketers 8
I want to styling validation message in webform for marketers. But I can't find where I can define CSS class or CSS for validation message.
0
votes
2
answers
906
views
Apply validation rule to a specific item in content tree
I need to apply a regex based validation to see the number entered by content author is between 1 and 5 only. Problem is the validation should be applied to only specific content item only. ANy idea ...
1
vote
0
answers
74
views
Sitecore Form with Salesforce Connect - Custom validations for postcode using external API
The custom validation for the postcode validation using Sitecore forms for a simple contact form which connects to salesforce.
I have seen multiple articles for the custom validation and also ...
1
vote
0
answers
94
views
On Item Creation: Warning/Confirmation dialog for invalid Item Name
I want to create a Warning/Confirmation dialog when certain items do not pass our custom item name validation rules. The user can still override the warning dialog via OK/Cancel Buttons.
I've tried ...
3
votes
2
answers
963
views
Dynamic DataSource for Droplist in Content Editor
I have a Droplist for Approvers and the DataSource of Droplist to /SharedData/Approvers.
I don't want the current user to have his own name in the list.
For example, DataSource List is having A, B ...
2
votes
0
answers
229
views
Run Validation Item on Save in Experience Editor
I have created a custom Rule in /sitecore/system/Settings/Validation Rules/Item Rules
When I press the validate button, I can see the Rule and its result, so far so good. But the Validation Button is ...
0
votes
2
answers
849
views
Allow all characters in ItemNameValidation setting
Trying to install a package which has the item names with characters like (', '.', ').
How can I temporarily disable ItemNameValidation setting? Tried changing the setting to '.*' which did not help....
1
vote
1
answer
1k
views
How to remove the blank field for Sitecore Droplink and Droplist
In Sitecore 9.0, when I create a Droplink or Droplist Sitecore generates a "blank" selection. For example I have a Droplink from Monday to Sunday, the first option will be a blank selection.
How can ...
2
votes
1
answer
168
views
Hide components in preview mode when there are field validation errors
I am using Sitecore 9.0.2 with SXA 1.8.0.
I extended the Required Field validator with the Result=CriticalError parameter, so the authors can see an alert each time they edit a page in Experience ...
1
vote
2
answers
355
views
When validating an item in a workflow action, null reference error?
So, I have an item with a couple of fields that have required validation rules.
I've added a validation action when executing a workflow action (submitting to admin for approval). When I do this a ...
1
vote
1
answer
171
views
Users can publish even when item has blank fields marked with required validation rule
I have Sitecore 8.2, have the template for my item assigned to our custom workflow, I have all validation rules set to Required for the fields in question.
Yet I can move the item through the ...
2
votes
1
answer
142
views
Validation error displayed on custom experience dialog incorrectly
In an SXA site I have cloned link list with item, and added a link custom editor button to allow editing of the list item fields. These fields have required validation. But I find that when I add ...
0
votes
0
answers
67
views
FatalError Required validation not working in sitecore 9.1 [duplicate]
i'm using sitecore 9.1 with SXA 1.8, i had the same problem in the this question, i tried to follow the solution mentioned there, i created a new user and gave him some read/write permissions while it'...
2
votes
1
answer
172
views
How to prevent an item from being moved to another folder accidentally?
I have 3 items in a folder based on the same template. Is there any functionality provided by Sitecore to prevent these items from being moved to another folder accidentally or deliberatively? Or we ...
2
votes
0
answers
730
views
FatalError Required validation not working
I am using SXA 1.8, and Sitecore 9.1
I am trying to add a validation for a Date type field where it is required, and the user cannot save the item unless this field has a value, I have copied ...
2
votes
2
answers
7k
views
'IServiceProvider' does not contain a definition for 'GetService'
This is the first time i deal with custom validations, but I need to create a unique email validation using sitecore 9.0.2 and SXA 1.7.1 so i was following this tutorial
http://sitecoresolution....
3
votes
2
answers
3k
views
Make one of two sitecore content fields required?
I've been trying to find a way to make one of two fields valid and haven't come up with much. Is there a way to do this with custom field validators or is that just relevant to individual fields? ...
6
votes
1
answer
647
views
Remove Alt Required validation from image
I need to remove Alt required validation from Alt field in Image template, I removed Alt required validation from template image in path /sitecore/templates/System/Media/Unversioned/Image
But when i ...
2
votes
2
answers
817
views
How does Image Size validator work?
I wanted to set image size validation for an image field for example the image field should not accept any image more than 2 mb. For this I tried using Image Size validator available in Sitecore.
...
6
votes
1
answer
244
views
"Linked Item Has Allowed Template" Field Validation XP 8.2
We're trying to validate a Droptree field to only allow a certain template type be selected. We've found the /sitecore/system/Settings/Validation Rules/Field Rules/System/Linked Item Has Allowed ...
0
votes
1
answer
598
views
How to add required field validation to SXA Tags field?
I created SXA Tags in the Sitecore and I know how to add this tag to an item but I want to add the required field validation to the Tag fields, so I can not save the items without adding tag to it.
...
2
votes
0
answers
169
views
WFFM - Custom validation class on form not being hit
Using Sitecore 8.2
I have a form and I'm trying to add custom validation to the email field to block forbidden domains. I created the validation item in Sitecore and added it to my field:
and I ...
8
votes
1
answer
841
views
Standard Required field validation reporting field is empty after upgrade to Sitecore 9.0 Update-2
We're getting an interesting validation error after upgrading from Sitecore 8.2 Update-6 to Sitecore 9 Update-2.
We have the standard Required validator on a field (item name of the field is Title). ...