简体   繁体   English

api的joomla列表

[英]joomla list from api

how do I define selected in joomla list using the api? 如何使用API​​在joomla列表中定义选定内容? If I try to use the following snippet won't work. 如果我尝试使用以下代码段将不起作用。

JHTML::_('select.genericlist', $options, 'jform[faculty]', array('class' => 'nourritures', 'option.attr' => 'data', 'selected'=>  $actual_record));

it's "list.select" not "selected": 它是“ list.select”而不是“ selected”:

please see http://www.fasterjoomla.com/joomla-dev/joomla-select-options-with-style for a complete example. 有关完整的示例,请参见http://www.fasterjoomla.com/joomla-dev/joomla-select-options-with-style

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM