Image from pulldown menu

3 posts by 2 authors in: Forums > CMS Builder
Last Post: June 3, 2008   (RSS)

Re: [ethan76] Image from pulldown menu

By Dave - June 3, 2008

Ethan, welcome to the CMS Builder forum! :)

The simplest way to do that would be with a PHP if statement like this:

<?php if ($record['yourField'] == "Road Legal"): ?>
Show Image 1
<?php endif ?>

<?php if ($record['yourField'] == "Off Road"): ?>
Show Image 2
<?php endif ?>

<?php if ($record['yourField'] == "Kid's Quads"): ?>
Show Image 3
<?php endif ?>


But use your own variable and fieldname instead of $record['yourField']. Give that a try and let me know if it does what you need.
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] Image from pulldown menu

By ethan76 - June 3, 2008

Dave,

That worked a treat!

CMS builder is genius - it's cured a headache I've had for about 3 years...

Thanks

Ethan