Please read and follow the COMMON ISSUES first!
Always add your version information in every new post! Thank you!

Form2Content Forum

Questions and answers for Form2Content, a Joomla CCK.
  1. Paul Zero
  2. F2C submission form templating
  3. Friday, 10 March 2017
  4.  Subscribe via email
form2content_pro_4.9.0
J2.5.28

Hi F2C,

I'm trying to style (using CSS) the background of one User Generated Field in frontend 'Form Edit'.

In generated code I can see the 'class' I need to style (class="f2c_field f2c_SLOGAN") but I can't get F2C form Edit to recognize my CSS when using the "class" label - BUT - If I use an element's 'id' F2C will apply CSS - BUT - In this instance I need to use the "class" tag to style the whole table row.

In the example below I can style <div class="f2c_field"><input type="text" name="t4087" id="t4087"</div> using '#t4087' in CSS - BUT can't style <tr class="f2c_field f2c_SLOGAN"> in same CSS file :

Frontend view - "index.php?option=com_form2content&view=form&layout=edit"

fieldset class="adminform" style="margin:0px; padding:0px;">
<table class="adminform" width="100%">

{all the default F2C fields are displayed - then User fields start}

<tr class="f2c_field f2c_SLOGAN">
<td width="100" align="left" class="key f2c_field_label" valign="top">
<label for="t4087">Story 'Slogan'</label>
</td>

<td valign="top" class="f2c_field_value">
<div class="f2c_field"><input type="text" name="t4087" id="t4087" value="10% Off Everything
2day!" size="style=" width:100%;""="" maxlength="25">
<span class="hasTip" title=""><img src="/media/system/images/tooltip.png" alt="Tooltip"></span>
<input type="hidden" name="hidt4087" id="hidt4087" value="740"></div>
</td>
</tr>

In css - I have tried the following but none effect F2C display (My CSS styles aren't recognized):

table .adminform tr .f2c_field f2c_SLOGAN {background-color:red;}

tr .f2c_field f2c_SLOGAN {background-color:red;}

.f2c_field f2c_SLOGAN {background-color:red;}

Any ideas how I can style 'class="f2c_field f2c_SLOGAN"' ?

Cheers Paulzero
Responses (1)
Accepted Answer Pending Moderation
Hi Paulzero,

Your CSS has a mistake. There is a space in between "f2c_field f2c_SLOGAN". So the they are TWO classes. f2c_files for all those fields and f2c_SLOGAN for that one in particular.

Regards,
Patrick
Please read the F2C documentation before asking questions! Thank you if you've done so ;)
  • Page :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.