I have a dropdown list with User Names (which is dynamically created by joomla so I have no control over it) and I want to : - hide that list ( I know how to hide it) - and create a new list which will have only 2 options from the previous list-> 1) its a variable (user name) which I can retrieve from the active user 2) the second value is static (naver changes) so I can specify that manually
this is mainly set in php which I am not good at and I don't know how to make it work.
this is what joomla uses to create that list :
<?php echo $this->form->renderField('access');?>
and this is an example of the result I see when I inspect that dropdown list from chrome (names/options are random) ->
<div class="controls"><select id="jform_access" name="jform[access]" class="inputbox" size="1" style="display: none;">
<option value="42">George</option>
<option value="44">John</option>
<option value="39">Chris</option>
<option value="34">Michael</option>
<option value="36">Template</option>
<option value="24">Publisher`enter code here`</option>
<option value="23">Test User</option>
<option value="5">Guest</option>
<option value="2" selected="selected">Registered</option>