%PDF- %PDF-
Direktori : /home1/lightco1/public_html/lightcolab.com/plugins/system/jqueryeasy/fields/ |
Current File : //home1/lightco1/public_html/lightcolab.com/plugins/system/jqueryeasy/fields/jqueryuiversion.php |
<?php /** * @copyright Copyright (C) 2012 - 2013 Qubesys Technologies Pvt.Ltd. All rights reserved. * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL */ // no direct access defined('_JEXEC') or die; jimport('joomla.form.formfield'); class JFormFieldJqueryuiversion extends JFormField { public $type = 'Jqueryuiversion'; /** * Method to get the field options. * * @return array The field option objects. * @since 1.6 */ protected function getLabel() { $html = ''; $html .= '<div style="clear: both;"></div>'; return $html; } /** * Method to get the field input markup. * * @return string The field input markup. * @since 1.6 */ protected function getInput() { $html = ''; // to check for jQuery UI // if ($.ui && $.ui.version) { // jQuery UI is loaded } $html .= '<script type="text/javascript">'; $html .= 'jQuery(document).ready(function($) {'; $html .= ' if ($.ui) {'; $html .= ' var version = $.ui.version;'; $html .= ' $(".jqueryuiversion span").replaceWith("<span>" + "'.JText::_('PLG_SYSTEM_JQUERYEASY_FIELD_JOOMLAJQUERYUIVERSION_LABEL').'" + version + "</span>");'; $html .= ' }'; $html .= '});'; $html .= '</script>'; $html .= '<div class="jqueryuiversion alert alert-info">'; $html .= '<span>'.JText::_('PLG_SYSTEM_JQUERYEASY_FIELD_NOJOOMLAJQUERYUIVERSION_LABEL').'</span>'; $html .= '</div>'; return $html; } } ?>