how to set the background color of a floatbox dialog

Page: 1

Author Post
michaelwur
Guest
I am learning to use a floatbox dialog to render a form. The form definition is given as a hidden div. The floatbox dialog can show the content of the given form except the background color. The lower portion of the floatbox dialog is still in white.

What is the right way to set the background color of a floatbox dialog? Can any ones help me out?

Thanks in advance!
Michael Wu
Administrator
Registered: Aug 2008
Posts: 3382
If you're seeing your background color cover part of the display, but not all of it, it is simply a size issue. Your floatbox height is set to a larger value than the height of the page the form is on. You need to either shrink the box or grow the page. It can be a bit of trial and error to get the content sizes right. Generally best if you give your displayed page more height and width than required and set the floatbox up with scrolling:no. Make sure you test in different browsers, because they all layout a page slightly differently.

Unrelated to your problem, it's generally a good idea to load forms as iframes rather than from an inline div. This is so that the form will get its own keyboard handler and the tab key and spacebar will behave as user's might expect them to.

Page: 1