Forums

form background image

raivis 01 Sep, 2010
Hi,

I have tried various methods to get a background image "under" the form itself but could not manage it.. Form is displayed in the middle of an article.

Should it work if I use the following code in Form HTML?:
<style type='text/css'>
div.myform {
    background-image: url(../images/stories/GOODSTUFF/pastkaste.jpg); 
}
</style>


And if "div.myform" should be replaced with "div.epastu_nodosana" where in my case "epastu_nodosana" is the form name?

Thanks,
Raivis
GreyHead 01 Sep, 2010
Hi Raivis,

You need to use a good diagnostic tool like FireBug in FireFox to check stuff like this.

ChronoForms changes the id and name of your form. In CSS it's easier to use the id. The CSS will then need to look like:
div#ChronoContact_epastu_nodosana {
    background-image: url(../images/stories/GOODSTUFF/pastkaste.jpg);
}
You can add the CSS directly into the Form CSS box.

Bob
raivis 01 Sep, 2010
Hi Bob,

FireBug shows following:

form id="ChronoContact_epasta_nodosana"
name="ChronoContact_epasta_nodosana"

If I try to insert the code
div#ChronoContact_epasta_nodosana {
background-image: url(../images/stories/GOODSTUFF/pastkaste.jpg);
}
right into Form Code CSS box, then unfortunately nothing happens (background image does not appear)

But if I for example insert a code
form {
background-image: url(../images/stories/GOODSTUFF/pastkaste.jpg);
}
into Form Code CSS box, then background image appears under all the forms I have.

So I guess there is an issue with identifying the specific form id or form name that would make the background image appear under the form I need.

If FireBug shows that these are
form id="ChronoContact_epasta_nodosana"
name="ChronoContact_epasta_nodosana"
so, any suggestions for the right code to use?

Thanks a lot,
Raivis
GreyHead 01 Sep, 2010
Hi Raivis,

You are correct, I should have written just #ChronoContact_epasta_nodosana or form#ChronoContact_epasta_nodosana

Bob
raivis 01 Sep, 2010
Yessss!!!!

Now it works!
Thanks Bob!

Brgds,
Raivis
This topic is locked and no more replies can be posted.