Cannot refresh an iFrame

I do not know if this is related to the new responsive engine or not, but I have an iFrame with inputs inside it. I need to be able to clear the inputs. I am converting a page to the new responsive engine and I cannot seem to refresh the iFrame without reloading the whole page no matter what I do.

Previously, I was able to run the following Javascript to refresh the iFrame which then cleared the inputs (with the correct id in the code of course):

document.getElementById('iFrame_name_goes_here').src += '';

I just tested my live version and the copied version of the page that’s still on the old responsive engine and this code refreshes the iFrame just fine; however, an identical setup on the new responsive engine does nothing.

Anyone run into the same thing, and do you have a working solution or something you suggest that I try?

Pffffft… Okay, there’s something squirrelly going on. I changed my iFrame’s id to something new (from ‘tokenFrame’ to the very imaginative ‘tokenFrame2’) and now it’s clearing perfectly fine. Never mind me, folks.

It must be related to having another iFrame elsewhere on the page with the same id name. This one was in a reusable element, the other is just on the regular page, but I had the same id assigned to both of them. I bet it’s related to that and so giving it a unique id name was the solution. Now, that begs the question, why wasn’t this an issue with the old responsive engine? But more importantly, who cares since I’m moving off that anyway?

This topic was automatically closed after 70 days. New replies are no longer allowed.