From c2783b9b54ecae8299da0dc593c3813c2bd26fe2 Mon Sep 17 00:00:00 2001 From: Petr Vobornik Date: Thu, 26 Jul 2012 11:17:28 +0200 Subject: Replace use of attr with prop for booleans Recommened way of setting boolean HTML attributes is by $.prop(boolean) method not $.attr(boolean) because it sets DOM object property not an attribute. Latter works because of jquery's backward compatibility. This patch makes things clearer. Some info about prop and attr: http://stackoverflow.com/a/5876747 https://fedorahosted.org/freeipa/ticket/2817 --- install/ui/dns.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'install/ui/dns.js') diff --git a/install/ui/dns.js b/install/ui/dns.js index 1f4ba8cc..cd8cb8e1 100644 --- a/install/ui/dns.js +++ b/install/ui/dns.js @@ -512,8 +512,8 @@ IPA.add_dns_zone_name_policy = function() { var name_from_ip_f = this.container.fields.get_field('name_from_ip'); idnsname_w.radio_clicked.attach(function() { - idnsname_w.input.attr('disabled', false); - name_from_ip_w.input.attr('disabled', true); + idnsname_w.input.prop('disabled', false); + name_from_ip_w.input.prop('disabled', true); idnsname_f.set_required(true); name_from_ip_f.set_required(false); @@ -522,8 +522,8 @@ IPA.add_dns_zone_name_policy = function() { }); name_from_ip_w.radio_clicked.attach(function() { - idnsname_w.input.attr('disabled', true); - name_from_ip_w.input.attr('disabled', false); + idnsname_w.input.prop('disabled', true); + name_from_ip_w.input.prop('disabled', false); idnsname_f.set_required(false); name_from_ip_f.set_required(true); -- cgit