Forums

custom tables
[resolved] Using IF statements on cells (4 posts)

  1. crookesa
    Member
    Posted 7 months ago #

    Is it possible to use IF statements on each cell.

    1. I want to make a cell text RED if it's below a certain value?
    2. Also only show the € sign if the cell is not NULL

    Cheers if you can help

    http://wordpress.org/extend/plugins/custom-tables/

  2. crookesa
    Member
    Posted 7 months ago #

    Sorted it!!!

  3. makingtrails
    Member
    Posted 6 months ago #

    Care to share the solution? :)

  4. crookesa
    Member
    Posted 1 month ago #

    In the custom tables settins in admin panel. Go into the table you have created and click on view setup then table setup.

    This is where you define the layout of your table. I added the if statement here.

    Solutions to above.

    1.
    <td>[if field="{total_due}" check="!="]<font color="red">[/if][if field="{total_due}" check=">" var="0"]€[/if]{total_due}[if field="{total_due}" check="!=" var="0"]</font>[/if]</td>

    2.
    <td>[if field="{total_paid}" check=">" var="0"]€[/if]{total_paid}</td>

    Hope this makes sense and helps

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.