I have to split the parent URL taken in child window to get a sub string out of it. If I use 'window.opener.document.location' to get the parent url and call split method it gives me the error below
I would expect window.opener.location.href or window.opener.location.search
Joined: Nov 08, 2001
Have you debugged what the variable holds before you split it? console.log is your friend.
Amit K Jain
Joined: Nov 06, 2008
Thanks you for your reply.
Yes. It is resolved by using 'window.opener.location.href'. I could print the value in alert for 'window.opener.location' which looks as expected hence moved on to split it. I do not have the right utility to debug the JS code and unfortunately I haven't done much work on JS. Can you please point me to any utility for it, any plugins in FireFox and its user guide?