added control on AJAX call to make sure it only updates the correct entry.