fixing fulltext iframe function to test for variable before running