Bug Tracker

Modify

Ticket #4745 (closed bug: invalid)

Opened 4 years ago

Last modified 14 months ago

[validate] validator breaks in IE8 with dropdowns

Reported by: BalusC Owned by:
Priority: major Milestone: 1.4
Component: plugin Version: 1.3.2
Keywords: validator IE8 dropdown Cc:
Blocking: Blocked by:

Description

Versions used: jquery.validator.js 1.5.2 (full, not min nor pack) jquery.js 1.3.2 IE 8.0.6001.18702

Code: see attachment.

Problem: jquery.validator.js breaks with following error: Line: 875 Char: 5 Error: Object required Code: 0

Attachments

test.html Download (1.3 KB) - added by BalusC 4 years ago.
test file for jquery validator bug in IE8

Change History

Changed 4 years ago by BalusC

test file for jquery validator bug in IE8

comment:1 Changed 4 years ago by BalusC

Excuse, the file is called jquery.validate.js, but that should have been obvious enough.

This problem doesn't occur in IE6 and IE7 by the way, as in any alternative browser I have here (FF, Opera, Safari, Chrome).

comment:2 Changed 4 years ago by BalusC

FYI: it works when I change the following part in line 875

$.browser.msie

by

$.browser.msie && $.browser.version < 8

If I recall correctly, some jQuery guy ever said that browser detection is a big no-no in jQuery. So I would rewrite the lines where browser detection is involved.

comment:3 follow-up: ↓ 5 Changed 4 years ago by hasantayyar

This because of "no value attribute".

Put "value" attribute to all "<option>".

comment:4 Changed 4 years ago by dmethvin

  • Status changed from new to closed
  • Resolution set to invalid

comment:5 in reply to: ↑ 3 Changed 2 years ago by zlati.pehlivanov@…

Replying to hasantayyar:

This because of "no value attribute".

Put "value" attribute to all "<option>".

no it's not I'm getting an "Stop running this script" error in ie8 and 7 not always but 90% of the time. there is some serious bug here guys please fix it the form is 100% correct, i even remove the select and the remote and the additional validator rules, BUT no, it's givving me this error wich breaks all my logic and submit's the form normaly not by ajax

$(".initialRegister").validate({
		// TO DO implement recaptca validation and add to hidden field that is validated - the server will now not to check it again
		rules: {
			
			user_password: {
				required: true,
				minlength: 8
			},
			user_password2: {
				required: true,
				minlength: 8
				
			},
			user_email: {
				required: true,
				email: true
			},
			
			user_fname: {
				
				minlength: 2
			},
			user_lname: {
				
				minlength: 2
			},
			user_bname: {
				
				minlength: 2
			},
			user_pc: {
				postalcode: true
			}
			
			
			
		},
		messages:{
			
			user_email: {
				required: "Please enter your valid email",
				email: "Entred email is not valid."
			},
			
			user_fname: {
				
				minlength: "Your First name is too short"
			},
			user_lname: {
				
				minlength: "Your Last name is too short"
			},
			user_bname: {
				
				minlength: "Your business name is too short"
			},
			user_pc: {
				postalcode: "Contains unsupported characters"
			}
			
			
		},
		submitHandler: function(form){
			
		
			var ajaxoptions = { 

			    beforeSubmit:  showRequest,  // pre-submit callback
			    success:       showResponse,  // post-submit callback
				dataType: 'json'	
			};
			$(form).ajaxSubmit(ajaxoptions);
		},
		success:function(label) {
	
			
		},
		onsubmit: true,
		onfocusout:false,
		onkeyup:false,
		onclick:false,
		focusInvalid:false,
		
		errorClass: "invalid",
		errorElement: "em",
		errorPlacement: function(error, element){
	
			var label = $("label[for='" + element.attr('name') + "']");
			
			$(label).append(error);
		},
		debug: false
	});

comment:6 Changed 2 years ago by jitter

There is a reason why this ticket was closed as invalid.

The big red box on the "New Ticket" page rather clearly states:

For all other jQuery plugins:

This is NOT the correct form! Please use the  Plugins site to report your bug to its author.

This tracker you submitted your bug on is for jQuery core bugs only. So bug reports for plugins should be filed on the plugin site or directly to the respective authors of those plugins. You can also try posting to the correct subforum in the  jQuery Forum and maybe get support from other users of the plugin.

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.