Keyword

Show all extrafields "except one".

More
12 years 2 days ago #104383 by clety
Show all extrafields "except one". was created by clety
I understand that adding a few lines to the following code (item.php K2), I can achieve the above objective .... can you help me? Pleaseeee
......
......
<ul>
<?php foreach ($this->item->extra_fields as $key=>$extraField): ?>
/*
here... add a condition ... ie, do everything that follows provided the extrafield id is different to 9, in the event that the ID is 9 must add 1 ... to be 10 and keep doing what you are doing
*/
<?php if($extraField->value): ?>
<li class="<?php echo ($key%2) ? "odd" : "even"; ?> type<?php echo ucfirst($extraField->type); ?> group<?php echo $extraField->group; ?>">
.....
........ etcétera
I look forward to your help and grateful

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

More
12 years 15 hours ago #104384 by clety
Replied by clety on topic Re: Show all extrafields "except one".
RESUELTO !!!

<?php foreach ($this->item->extra_fields as $key=>$extraField): ?>
<? if ($extraField->id== continue; ?>

<?php if($extraField->value): ?>
<li class="<?php echo ($key%2) ? "odd" : "even"; ?> type<?php echo
ucfirst($extraField->type); ?> group<?php echo $extraField->group; ?>">


(Ahora el item id=8 de extrafields "no se ve")

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


Powered by Kunena Forum