I have two pages sem_menu.html and sem_menu2.html with the same headers, when sem_menu2 is contained and inserted in an iframe I hide the header of it so only the header of the sem_menu is displayed.
What I want to do is create a function that if sem_menu2 is contained in an iframe having the hidden header must write me in the sem_menu header while if it is not contained in an iframe then it is opened as a normal page it must write in its own header then of sem_menu 2.
if (window.parent.frames.length > 0) {
alert(sessionStorage.sem_applicazione);
} else {
alert('no!')
}
For now I have only this, can someone help me?