pat = new RegExp('(<'+element+'>)([\\s\\S]*?)(</'+element+'>)', 'gmi');
pat = new RegExp('<'+element+'>(.*?)<\/'+element+'>', 'gmi');