[jQuery] Interface.js Exception: Access to Restricted URI denied

[jQuery] Interface.js Exception: Access to Restricted URI denied

Hi,
Was trying to make a horizontal accordion with nice ease-in effects etc. I first made the widget separately in an HTML file (which worked fine) and then tried to embed it in my main HTML file. I got a funny exception.
Error: uncaught exception: [Exception... "Access to restricted URI denied"  code: "1012" nsresult: "0x805303f4 (NS_ERROR_DOM_BAD_URI)"  location: "file:///D:/work/ClientWork/Ask%20for%20Original/Site%20Design/HTML/interface.js Line: 8"]
The code that gives the error is the last line in the snippet below. The second last line happens nicely, though.
which = '#'+which+'_details';
$('.details').animate({width: 0 }, 500, "easein");       
$(which).animate({className: "endcontent"}, 500, "easein");   
Please suggest a solution.
Thanks<br clear="all">
--
Gurpreet Singh