Skip to content

Commit

Permalink
Merge pull request #818 from tractorcow/3.0-duplicate-field-descripti…
Browse files Browse the repository at this point in the history
…on-fix

FIXED: Issue with duplicate help tips appearing on select fields in CMS
  • Loading branch information
sminnee committed Sep 25, 2012
2 parents 2b172aa + 495ffb0 commit 9500581
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions admin/javascript/LeftAndMain.FieldHelp.js
Expand Up @@ -6,15 +6,17 @@
*/
$(".cms form .field .middleColumn > [title]").entwine({
onmatch: function() {

var title = this.prop("title");
var field = this.closest(".field");

if(title && title.length) {
if(title && title.length && field.has('.help').length == 0) {
var span = $("<span></span>", {
"class": "help",
"text": title
});

this.closest(".field").append(span);
field.append(span);
this.removeProp("title");
}

Expand Down

0 comments on commit 9500581

Please sign in to comment.