Synchronize html and db