refine procedure for output of files using extended headers which serve full files and an isset check for empty keys