There is a button on my website that opens a child window displaying a list of images. When the user clicks on an image, values are sent as parameters to a function in the parent window. These parameters are then added to an array variable within the parent window before closing the child window. The code currently works in Chrome and Firefox but encounters issues in IE, particularly IE 9. I would like it to work smoothly in IE 7 as well.
Parent Window Code:
var edge;
function getEdgeProfile(){
myEdge = window.open('edge.html','','top=50,left=50,width=400,height=400');
}
Child Window Code:
<head>
<script>
function selectEdge(name, price, type){
opener.edge = [name, price, type];
window.close();
}
</script>
</head>
<body>
<img src="1.png" width="100px" height="100px" onClick='selectEdge("Square Edge 2mm ARRIS", 30.5, 1)'>
<img src="2.png" width="100px" height="100px" onClick='selectEdge("4 x 4 mm SINGLE BEVEL", 38.56, 1)'>
<img src="3.png" width="100px" height="100px" onClick='selectEdge("4 x 4 mm DOUBLE BEVEL", 46.49, 1)'>
<img src="4.png" width="100px" height="100px" onClick='selectEdge("V JOINT WITH SINGLE PENCIL", 38.56, 2)'>
</body>
I would add a JSFiddle demonstration, but it opens a separate page making it difficult to showcase here. Any assistance or suggestions are greatly appreciated!