hi,

this is probably easy so hope someone can help asap.

i have an existing bit of code here:

<img src="images/<?php echo (($row_rsTimelineActive['ReservationFormSentToPP']==0)?'no.gif':'yes.gif'); ?>" >

instead of it being ==0 i want to be able to display no.gif if ReservationFormSentToPP is null and yes.gif if not null.

hope you can help.

many thanks

Try using is_null

echo is_null($row_rsTimelineActive['ReservationFormSentToPP']) ? 'no.gif' : 'yes.gif';

You can also use empty.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.