<?php
/**
 * @package    VP Advanced User
 * @author     Abhishek Das <info@virtueplanet.com>
 * @copyright  Copyright (C) 2012-2019 VirtuePlanet Services LLP. All rights reserved.
 * @license    GNU General Public License version 2 or later; see LICENSE.txt
 * @link       https://www.virtueplanet.com
 */

defined('JPATH_BASE') or die;

jimport('joomla.form.formfield');

class JFormFieldVPAUAdmin extends JFormField
{
	
	public $type = 'VPAUAdmin';
	
	protected function getInput()
	{
		$app  = JFactory::getApplication();
		$doc  = JFactory::getDocument();
		$root = JUri::root(true);
		
		$doc->addStyleSheet($root . '/media/com_vpadvanceduser/css/config.css?ver=1.7');
		$doc->addScript($root . '/media/com_vpadvanceduser/js/config.js?ver=1.7');
		
		$doc->addScriptDeclaration('
		window.VPAUUri = "' . JUri::base() . '";
		');
		
		return '<span id="' . $this->id . '"></span>';
	}
	
	public function getLabel() 
	{
		return null;
	}
}