Jump to content

How to only show set_relation results if not null

set_relation not null

  • Please log in to reply
No replies to this topic

#1 Woodie



  • Members
  • Pip
  • 1 posts
  • LocationChristchurch

Posted 31 October 2016 - 11:46 AM

Hi all,


I am setting a relation with an address table and displaying the result multiple address column fields as such:

$crud->set_relation('address_id','address','{address_1}<br> {address_2}<br> {address_3}<br> {town}<br> {county}<br> {postcode}');

This works fine but what I would like is to only show the results of fields that are not null so I don't get breaks with null values in the output:



Address line 1








Any help with this would be greatly appreciated


Thanks in advance

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users