Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Copy from one page to another

Status
Not open for further replies.

mlocurci

MIS
Oct 17, 2001
210
US
I have a webpage that contains a ship to address. I want to copy that shipto address into the order path of a ecommerce webpage. Is there a way with javascript that I can create a button on my webpage that copies the datapoints into the page of the merchant. Pretend that I know the field names of the hosting page.
 
No - this would fall into the realms of cross-site scripting. It's not allowed unless both pages are hosted on the same domain.

Cheers,
Jeff

[tt]Jeff's Page [/tt][tt]@[/tt][tt] Code Couch
[/tt]
 
The answer is yes. You can. But should be solving your problem in this specific way? Probably not. There are many ways to solve this problem - including server-side solutions.

The question you asked was? I don't know.

Please think about your question and describe the problem you are experiencing; so that we may be able to help you.

Cheers,
Jeff

[tt]Jeff's Page [/tt][tt]@[/tt][tt] Code Couch
[/tt]
 
If the merchant site is set up to read form values submitted to it (either POST or GET), there wouldn't be any problem. If you don't have control over the merchant's site, you MIGHT be able to do something with frames, but I don't know for sure.

Lee
 
The merchant's form does support get. What would I use?
 
Does the merchant's site SEND form information with a GET, or RECEIVE and PROCESS form information that way? If the page has an ASP, CFM, PHP, or other server-side scripting language extension, then I'd say it can process it. I've seen some servers set up to process HTM and HTML extensions through PHP, too, but not often. Unless the merchant's form does things with server-side scripting (though client-side JS can handle a GET, too), then you're probably out of luck.

Lee
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top