Quick ignorant HTML/FORM question

DPK

Senior member
Jan 10, 2000
473
0
0
Is it possible to put a link onto a website that, when clicked on, will open up a form from an outside site but with one of the fields already filled in? It's for people making an online donation to a hospital and I would like the "donor recognition" field already filled in so people don't make a mistake? I know, stupid question but can that be done with code in HTML?
 

DannyBoy

Diamond Member
Nov 27, 2002
8,820
2
81
www.danj.me
It can't be done in straight HTML, there's a couple of client-side languages that would allow you to do what you want though.
 

CycloWizard

Lifer
Sep 10, 2001
12,348
1
81
Yeah, no way to load a form that you don't control with information already posted. If it's a donation form, try contacting the site host and see if they'll arrange something for you - they might if it's for a good cause.
 

lansalot

Senior member
Jan 25, 2005
298
0
0
var win = window.open("www.something.com");
win.Formname.field.value = "something";

not tried it, something like that might work.
 

CycloWizard

Lifer
Sep 10, 2001
12,348
1
81
One thing you might be able to do is get their form and host it yourself. Again, you'd have to contact them for the posting method of the form for it to work, but this would allow you to do what you want very easily.

Really, the easiest thing is probably just to put clear instructions in a frame at the top of the window. In the bottom frame, have the page that you're linking to.