Ok, I have a asp function that occur everytime a page is loading! In this function I change a Session with a link corresponding to the page where the user is! And then I want to write this adress on the top frame so the user has some kind of navigator! But I need each time to refresh the top frame so the adress changes!
Ok, here's my problem! So first the asp function is triggered and then on page onload I call a javascript function that verify wich page I am and then I'm changing the page's title image. But before that I refresh the top frame and then I'm changing the image! If I don't refresh the top frame the image is changing! But If I do the refresh the image is not changing!
HERE's some code:
function changeImg(pageName)
{
top.topDown.location.reload();
switch (pageName)
{
case 'main':
imgMain = new Image();
imgMain.src = "images/accueil.jpg";
parent.topDown.document.logo.src = imgMain.src;
break
case 'altao':
imgAltao = new Image();
// alert ("someText"
// If I put that, the image change
imgAltao.src = "../images/societe.jpg";
parent.topDown.document.logo.src = imgAltao.src;
break
case 'equipe':
imgName.src = "../images/equipe.jpg";
parent.topDown.document.logo.src = imgName.src;
break
}
Thanks in advance!
Ok, here's my problem! So first the asp function is triggered and then on page onload I call a javascript function that verify wich page I am and then I'm changing the page's title image. But before that I refresh the top frame and then I'm changing the image! If I don't refresh the top frame the image is changing! But If I do the refresh the image is not changing!
HERE's some code:
function changeImg(pageName)
{
top.topDown.location.reload();
switch (pageName)
{
case 'main':
imgMain = new Image();
imgMain.src = "images/accueil.jpg";
parent.topDown.document.logo.src = imgMain.src;
break
case 'altao':
imgAltao = new Image();
// alert ("someText"
imgAltao.src = "../images/societe.jpg";
parent.topDown.document.logo.src = imgAltao.src;
break
case 'equipe':
imgName.src = "../images/equipe.jpg";
parent.topDown.document.logo.src = imgName.src;
break
}
Thanks in advance!