Forum OpenACS Q&A: Forms API and Inline frames

Collapse
Posted by defunct defunct on
I'm sure there's a pretty obvious way of doing this, but asfter my
dental surgery this morning my brains sloooowed right down.

If I have a page which has a single inline frame in it, and the src
for that iframe is a forms api .tcl file, then how, if validation on
the form itself fails, do I tell the form to remain within the iframe?

i.e. is there some way of specifying a 'target=_self' paramater to it?

Collapse
Posted by Dave Bauer on
Simon,

You can set attributes of the form tag using the -html option of form create.

This will add html to the <form> html tag. I am not sure if this is what you need. You can add additional html attributes to any form element the same way.

Collapse
Posted by Dave Bauer on
Looking at an HTML reference, this is exactly what you need to do.

"TARGET=FrameTarget (frame to render form result in)"