local var for global.document