consider both iframe and non-iframe apps