refactor flash HTML