After two day of research i found that html validator extension for google chrome causes the duplicated entries into DB. I use this this code to insert data:
$object = $modx->newObject('modDocument');
$object->fromArray($fields);
$object->save();
$inserted_id = $object->get('id');
anyone had similar problem and know how to solve it ?
modx manager also uses xpdo to insert resources without duplicated entries ... how is done ? .. that html validator on chrome doesn’t cause any problems .. maybe because of ajax ??