function addField(type, id, label, required, services, translation) {
var $new_field = $('ul#quickad-templates > li[data-type=' + type + ']').clone();
// Set id, label and required.
if (typeof id == 'undefined') {
id = Math.floor((Math.random() * 100000) + 1);
}
}
It gives error
Uncaught Error: Syntax error, unrecognized expression: ul#quickad-templates > li[data-type=]