/    Sign up×
Community /Pin to ProfileBookmark

permission errors accross servers

I’m writing a set of pages that has to run between two servers.

one is a global server that is open to the whole internet, but does not have much access to the intranet features. The other is on the Intranet, and has full access to everything

I’ve written a script that will popup a window and retrieve all the data from the intranet, now I need to find a way of returning a string to the internet page. If they are on the same server I can just do:

window.opener.document.getElementById(“Username”).value=blah

but as they are on different servers this gets an access error. Does anyone know of a way I can just pass a text value from one page to the other.

My next best option is to copy the output to the clipboard and ask the user to paste it themselves and write another script in the internet server to process it, but this is a much uglier way of getting things done.

any suggestions/comments on how I can get this to work?

thanks
-mark

to post a comment
JavaScript

4 Comments(s)

Copy linkTweet thisAlerts:
@CharlesAug 28.2003 — [font=georgia]Set a cookie using the "path" parameter. See http://devedge.netscape.com/library/manuals/2000/javascript/1.3/reference/cookies.html#1002170.[/font]
Copy linkTweet thisAlerts:
@Markallen85authorAug 28.2003 — as I understand it that would just work as a variation of the idea to copy the value to the clipboard. At some point the user would still have to tell the page when the popup had closed so that it would know when to go away and dig out the cookie. I'm hoping there's a a way for the pop-up to directly set the value, or if there's a way of telling it's parent that it just closed so that it can go away and retrieve the value from the clipboard/cookies

but thanks for the suggestion, it's another option for me to start throwing around my brain

thanks

-mark
Copy linkTweet thisAlerts:
@CharlesAug 28.2003 — [font=georgia]You will not get it to work using JavaScript. As you've discovered you are trying to violate security restrictions.[/font]
Copy linkTweet thisAlerts:
@Markallen85authorAug 28.2003 — well, thanks for clearing that up for me.


-mark
×

Success!

Help @Markallen85 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...