PageRenderTime 12ms CodeModel.GetById 9ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/administrator/components/com_easysocial/themes/default/forms/types/select.php

https://gitlab.com/vnsoftdev/swc
PHP | 24 lines | 14 code | 0 blank | 10 comment | 2 complexity | 99924565ebb2ebd4cf16143226fa4035 MD5 | raw file
 1<?php
 2/**
 3* @package		EasySocial
 4* @copyright	Copyright (C) 2010 - 2014 Stack Ideas Sdn Bhd. All rights reserved.
 5* @license		GNU/GPL, see LICENSE.php
 6* EasySocial is free software. This version may have been modified pursuant
 7* to the GNU General Public License, and as distributed it includes or
 8* is derivative of works licensed under the GNU General Public License or
 9* other free or open source software licenses.
10* See COPYRIGHT.php for copyright notices and details.
11*/
12defined( '_JEXEC' ) or die( 'Unauthorized Access' );
13?>
14<div class="row">
15	<div class="col-sm-6">
16		<select name="<?php echo $field->inputName;?>" class="form-control input-sm<?php echo isset( $field->class ) ? $field->class : '';?>">
17			<?php if( isset( $field->options ) ){ ?>
18				<?php foreach( $field->options as $option ){ ?>
19				<option value="<?php echo $option->value;?>"<?php echo $params->get( $field->name , $field->default ) == $option->value ? ' selected="selected"' : '';?>><?php echo JText::_( $option->title );?></option>
20				<?php } ?>
21			<?php } ?>
22		</select>
23	</div>
24</div>