jquery find last element in array not empty and remove comma | |
---|---|
Subject: | |
//find the last element that isn't empty and strip trailing comma newTarget = $("[id^='LEMtailor_Q']:not( :empty )").last().html().replace( /(,\s*$)/g, ""); $("[id^='LEMtailor_Q']:not( :empty )").last().html( newTarget ); | |
2015-12-02 14:06:47 | gstlouis |