Custom Field HTML Formatting does not exist

  • xianburke
  • Topic Author
  • Offline
  • New Member
  • New Member
More
14 years 4 months ago #6864 by xianburke
I have added a couple of customer fields. Inside the custom field, I can add a CSS format, but only for the filed, not for the <td> that represents it. So, all the rest of my regular fields that use <td class="field_cell"> are fine, but the custom field only has <td>. In the detail.php file, there is no way to adjust the HTML formatting for the custom fields.

The code for a normal field looks like this:

<tr>
<td class="title_cell">
<?php echo JText::_('EB_EMAIL'); ?><span class="required">*</span>
</td>
<td class="field_cell">
<input type="text" class="inputbox" name="email" value="<?php echo $this->email; ?>" size="40" />
<?php
if ($this->registrationErrorCode == 2) {
?>
<span class="invalid"><?php echo JText::_('EB_EMAIL_USED'); ?></span>
<?php
}
?>
</td>
</tr>

The code for all of the custom field looks like this:

if ($this->customField) {
echo $this->fields ;
}

There is no ability to modify the HTML on the custom fields.

Please help me with the updated code that allows me to adjust the HTML for the custom fields.

Thanks,

Christian

Please Log in or Create an account to join the conversation.

  • xianburke
  • Topic Author
  • Offline
  • New Member
  • New Member
More
14 years 3 months ago #6992 by xianburke
Replied by xianburke on topic Re: Custom Field HTML Formatting does not exist
Anyone? Still looking for a solution.

Please Log in or Create an account to join the conversation.

More
14 years 3 months ago #7003 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Re: Custom Field HTML Formatting does not exist
Hi

The custom field is rendered using custom field class. You can open the file components/com_eventbooking/helper/fields.php, look at the function at line 1385 :
Code:
function renderCustomFields() {

You will see the code and can modify it easily .

Please let me know if you have other questions .

Thanks,

Tuan

PS : I am very busy these days for making my extensions work with Joomla 1.6 and I might forgot to reply a forum post. In case you don't receive my response, feel free to contact me via Skype, YM , MSN or Gtalk . You can also submit a support ticket system.

Please Log in or Create an account to join the conversation.

  • xianburke
  • Topic Author
  • Offline
  • New Member
  • New Member
More
14 years 3 months ago #7011 by xianburke
Replied by xianburke on topic Re: Custom Field HTML Formatting does not exist
Yes, that was the place. Actually in line 126, I changed <td> to <td class="field_cell"> which gave the same formatting as the rest of the fields.

Thanks for pointing me in the right direction.

Case closed.

Christian

Please Log in or Create an account to join the conversation.

Moderators: Tuan Pham Ngoc