Hi Jacques, As far as I have seen, it is always recommended to use === for comparison in javascript, as others always end up with mysterious errors. References: http://www.codeproject.com/Articles/580165/JavaScript-Best-Practices http://net.tutsplus.com/tutorials/javascript-ajax/24-javascript-best-practices-for-beginners/
On Thu, Jul 25, 2013 at 12:48 PM, <jler...@apache.org> wrote: > Author: jleroux > Date: Thu Jul 25 07:18:03 2013 > New Revision: 1506828 > > URL: http://svn.apache.org/r1506828 > Log: > Rhaaa another wrong C/P, better use patches really :/ > > Modified: > ofbiz/trunk/framework/images/webapp/images/selectall.js > > Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1506828&r1=1506827&r2=1506828&view=diff > > ============================================================================== > --- ofbiz/trunk/framework/images/webapp/images/selectall.js (original) > +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Thu Jul 25 > 07:18:03 2013 > @@ -352,7 +352,7 @@ function ajaxSubmitFormUpdateAreas(form, > } > updateFunction = function(data) { > if (data._ERROR_MESSAGE_LIST_ != undefined || data._ERROR_MESSAGE_ > != undefined) { > - if (jQuery('#content-messages').length == 0) { > + if (!jQuery('#content-messages').length) { > //add this div just after app-navigation > if(jQuery('#content-main-section')){ > jQuery('#content-main-section' ).before('<div > id="content-messages" onclick="hideErrorContainer()"></div>'); > @@ -367,8 +367,8 @@ function ajaxSubmitFormUpdateAreas(form, > jQuery('#content-messages' ).html(data._ERROR_MESSAGE_); > } > jQuery('#content-messages').fadeIn('fast'); > - }else { > - if (jQuery('#content-messages').length == 0) { > + } else { > + if (jQuery('#content-messages').length) { > jQuery('#content-messages').html(''); > > jQuery('#content-messages').removeClass('errorMessage').fadeIn("fast"); > } > > >