...

View Full Version : How do I load an image using javascript?



AlexanderBlade
11-23-2006, 10:47 AM
Hi, I've sent a paramater to my javascript function like this:

My NavigateUrl code:

NavigateUrl='JavaScript:openPopup("largerImage.aspx?path=<%# DataBinder.Eval(Container.DataItem, \"Path\")%>")'

My JavaScript:

<script language="JavaScript">


var MyWindow=null;

function openPopup(url)

{

MyWindow=window.open(url,"MyCoolPopup","height=300, width=300");


}

</script>

This works fine but now I don't know wether to load the image from inside the javascript function or to use the pageload of "largerImage.aspx to display the image. How do I use the url of my JavaScript function to load my image?

Thanks for any help with this one.

AlexanderBlade



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum