modify method to postMessage to parent frame