Renaming Variables

2 posts by 2 authors in: Forums > CMS Builder
Last Post: October 10, 2013   (RSS)

By Daryl - October 10, 2013

Hi Perchpole,

Have you tried using  ternary operators?

Example

$text = (@$var['description'] != '' ? @$var['description'] : @$var['content']);

Hope this helps.

Cheers!

Daryl Maximo
PHP Programmer - interactivetools.com