open and save file revised
code cleaning