battasrinivasa
12-28-2005, 06:16 PM
Hi All,
I am working with a toolbar. I have a function where i need to capture the colors userd in that page and display in another html page by popping up.
for that i am using the below code. This code is working fine when i am working with my local webserver when i tested in separate html pages. but when i kept it in the toolbar and calling the js file, it says "Access is Denied".
I worked with this functionality for 4 days and tried to debug. but no use. finally i am keeping this problem in net.
I am badly looking for help.
please check my Javascript code as below :
-------------------------------------------------------------------------
function colorslist() {
var swidth,sheight,sObj,lnkobj;
swidth=screen.width;
sheight=screen.height;
var mywindow = window.open ("http://www.rampweb.com/toolbar/colorcontrast.html", "mywindow","left=0,top=0,scrollbars=yes,status=yes,menubar=yes,location=yes,toolbar=yes,resizable=yes,width="+swidth+",height="+sheight+"");
sObj=mywindow.document.getElementsByTagName("head")[0].appendChild(mywindow.document.createElement("link"));
sObj.type = "text/css";
sObj.rel="stylesheet";
sObj.href="http://www.rampweb.com/toolbar/color_list.css";
so_createContainer();
so_getStyleSheetColors();
so_getInlineColors();
so_getAttributeColors();
xxobj=so_createColorTable();
var myobj = mywindow.document.getElementById("listcolors");
myobj.innerHTML=xxobj;
}colorslist();
-------------------------------------------------------------------------
Thanks in Advance.
prasad
I am working with a toolbar. I have a function where i need to capture the colors userd in that page and display in another html page by popping up.
for that i am using the below code. This code is working fine when i am working with my local webserver when i tested in separate html pages. but when i kept it in the toolbar and calling the js file, it says "Access is Denied".
I worked with this functionality for 4 days and tried to debug. but no use. finally i am keeping this problem in net.
I am badly looking for help.
please check my Javascript code as below :
-------------------------------------------------------------------------
function colorslist() {
var swidth,sheight,sObj,lnkobj;
swidth=screen.width;
sheight=screen.height;
var mywindow = window.open ("http://www.rampweb.com/toolbar/colorcontrast.html", "mywindow","left=0,top=0,scrollbars=yes,status=yes,menubar=yes,location=yes,toolbar=yes,resizable=yes,width="+swidth+",height="+sheight+"");
sObj=mywindow.document.getElementsByTagName("head")[0].appendChild(mywindow.document.createElement("link"));
sObj.type = "text/css";
sObj.rel="stylesheet";
sObj.href="http://www.rampweb.com/toolbar/color_list.css";
so_createContainer();
so_getStyleSheetColors();
so_getInlineColors();
so_getAttributeColors();
xxobj=so_createColorTable();
var myobj = mywindow.document.getElementById("listcolors");
myobj.innerHTML=xxobj;
}colorslist();
-------------------------------------------------------------------------
Thanks in Advance.
prasad