Validation

7 replies · opened Apr 28, 2022

Jjaih2Apr 28, 2022

Hi!
Does the code provide validation for a phone number? Or is it a custom solution?

I found a notification about the wrong number in the plugins.form file.

number:"Please enter a valid number."

Jjaih2Apr 28, 2022

And how to trigger a notification on an invalid email, it highlights it but there is no notification, email:"Please enter a valid email address."

SSemicolon WebSTAFFApr 29, 2022

Hello,

  1. Currently Validation for the Phone Numbers is not included out of the box but can be enabled easily. Simply follow the steps below:
  1. To display an Error Message for the Invalid Email, simply add the .show-error-msg Class to the `` Tag. Example:
    [ch_pre][/ch_pre]

This will definitely work fine. Hope this Helps!

Let us know if we can help you with anything else or if you find any further issues.

Jjaih2Apr 29, 2022

Great! Thanks!

Jjaih2Apr 29, 2022

Faced the following problem.
On the local computer, mail validation works as expected. But when installing the file on the server, validation works only after clicking send.


	
	

	
	
- 
	
- 
	
- 
	
- 
	
- 
	
- 
	
- 

	
	
- 

	
	
- 

	
- 
	

	
	Jobs - Forms | Canvas

.file-caption.icon-visible .file-caption-name {
	font-family: 'Lato', sans-serif;
	color: #666;
}

	
	

		
		
			
				

					

						

						
							
								
									
										
											
										
									
									
										Name:
										
									
									
										Email:
										
									
									
										
											
												Phone:
												
											
											
												Location:
												
											
											
											
												Date Of Birth:
												
											
											
												Gender:
												
													
													Male

													
													Female
												
												
													-- Select One --
													Male
													Female
												 -->
											
											
											
												Type:
												
													-- Select One --
													Part-Time
													Full-Time
													Internship
													Freelance
												
											
											
												Experience:
												
													-- Select One --
													Less than 1 Year
													1-4 Years
													4-7 Years
													7+ Years
												
											
										
										
											Upload CV:
											
										
										
											Describe Yourself:
											
										
									
									
										
									
									
										Send Message
									

									
								
							

						

					

				
			
		

		

	
	

	
	
	

	
	

	
	

	
	

	
	
	

	
		jQuery(document).ready( function(){
			$('.dobpicker').datepicker({
				autoclose: true,
			});

			$("#jobs-application-resume").fileinput({
				required: true,
				browseClass: "btn btn-secondary",
				browseIcon: "",
				removeClass: "btn btn-danger",
				removeLabel: "",
				removeIcon: "",
				showUpload: false
			});

			tinymce.init({
				selector: '#jobs-application-message',
				menubar: false,
				setup: function(editor) {
					editor.on('change', function(e) {
						editor.save();
					});
				}
			});
		})
	
	$(document).ready(function() {	
				$.validator.addMethod( "mobileUS", function( phone_number, element ) {
					var usPhone_number = phone_number.replace( /\(|\)|\s+|-/g, "" );
					return this.optional( element ) || usPhone_number.length > 9 && /^((\+1|1|1)+([0-9]){10})$/.test( usPhone_number );
				}, "Please enter a valid phone number" );
	});
	

Could you see for yourself what the problem is?

SSemicolon WebSTAFFApr 30, 2022

Hello,

Can you please provide us with a Live URL so that we can check out the exact issue and provide you with more accurate assistance on this. Thanks for your Patience.

Meanwhile, do let us know if we can help you with anything else or if you find any further issues with Canvas.

SSemicolon WebSTAFFMay 2, 2022

Hello,

Thanks for your Patience!

We have just checked this out and the Validation along with Validation Messages appear to be working correctly for us on Desktops. This could probably be an issue with your Browser Cache, so simply clear it or hard refresh the Page and this issue should be resolved automatically.

Hope this Helps!

Let us know if we can help you with anything else or if you find any further issues.

Have the same question, or something new?

Sign in to the Canvas dashboard to reply or open your own topic. Canvas owners get direct help from the SemiColonWeb team.

Reply on the dashboard