I have some QGIS projects that I've been using for long time, adding and removing layers, updating reference to deleted or moved files etc.
Opening with a text editor the qgs file I see that it contains numerous references to files, and this references are not showed on the Layer tree pane.
I have here different cases: references to existing file, references to missing files, references to database connections. I got aware f this when I opened my project on another machine, and QGIS reported a missing database connection to vector tables not present in the layer tree view.
Manually deleting references from the qgs file solved the problem, but I'm managing huge projects and it's near to impossible to manually check the project consistency. I've tried the "Remove empty layers" plugin, but the ones I'm trying to remove are not empty layers. Is there any way to 'purge' qgis file?

Setting--> Project Properties-->save paths-->relativeCheers N – Naresh Sep 17 '12 at 11:41