Hi,
How are you?
Thank you for creating Seblod.
I'm trying to achieve something which over my knowledge.
I've created a radio field with 2 options: e.g. option 1; option 2
In a position override I'm trying to write the code to get the values of some fields if option 1 is the selected option and the values of some different fields if option 2 is the selected option.
I've found some example code in the old forum but it's not enough, here it is:
<?php
// get the checkbox values
$options = $cck->get('my_checkbox_field')->value;
// create an array of the values
$optarray = explode(",",$options);
// verify if x value is in the array, if yes display another field
if (in_array("x", $optarray)) echo $cck->renderField('another_field');
?>
I hope you understand me.
So basically I'm trying to do something like this:
if radio field is option 1 echo field1 and field2
else echo field3 and field4
Could you help please?
Thank you again
Best Regards
Rumen