Dkuzik Posted November 19, 2022 Share Posted November 19, 2022 Wondering if someone can help? I have no idea how to program, I have been going through discussions and looking at current setup so I can try to modify. I have some custom fields in a module...2 work fine they were existing. The 3rd one I created. I can't get Select Options to work from drop down. The rest shows up. Not sure if my code is right either. Any help much appreciated. $username = array( 'fieldname' => $row['custom_field_username'], 'fieldtype' => 'text', 'description' => '(Leave empty if you want system to generate randomly) 8 - 28 Characters in length, NO special characters', 'regexpr' => "/^[a-zA-Z0-9]{8,28}/", 'required' => '', 'showorder' => 'on', 'showinvoice' => 'on', ); $passwordfield = array( 'fieldname' => $row['custom_field_password'], 'fieldtype' => 'password', 'description' => '(Leave empty if you want system to generate randomly) 8 - 28 Characters in length, NO special characters', 'regexpr' => "/^[a-zA-Z0-9]{8,28}/", 'required' => '', 'showorder' => 'on', 'showinvoice' => 'on', ); $yourdevice = array( 'fieldname' => 'Your Device', 'fieldtype' => 'dropdown', 'fieldoptions' => 'Android Box, Firestick', 'description' => 'What device are you using?', 'regexpr' => "", 'required' => 'on', 'showorder' => 'on', 'showinvoice' => 'on', ); $custom_fields = array($row['custom_field_username'] => $username, $row['custom_field_password'] => $passwordfield, 'Your Device' => $yourdevice); 0 Quote Link to comment Share on other sites More sharing options...
leemahoney3 Posted November 20, 2022 Share Posted November 20, 2022 Your select options in the screenshot are blank, is that the issue? 0 Quote Link to comment Share on other sites More sharing options...
Dkuzik Posted November 21, 2022 Author Share Posted November 21, 2022 Yes. I am trying to auto populate custom fields when i select module. So far everything shows up except select options. Of course i can manually add select options but what to auto populate it. So is my code correct for "your device"? 0 Quote Link to comment Share on other sites More sharing options...
leemahoney3 Posted November 21, 2022 Share Posted November 21, 2022 Where are you placing that code? I don't see what part of the code would auto populate the options. 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.