Skip to content

Instantly share code, notes, and snippets.

View phproberto's full-sized avatar

Roberto Segura phproberto

View GitHub Profile
@phproberto
phproberto / multifont.php
Created June 26, 2012 02:34
Google font+variant joomla field
<?php
/**
* @copyright Copyright (C) 2012 Roberto Segura. All rights reserved.
* @license GNU General Public License version 3; see LICENSE.txt
*/
defined('JPATH_BASE') or die;
jimport('joomla.form.formfield');
@phproberto
phproberto / bshead.php
Created June 21, 2012 23:25
In extension parameters show a section header customized with bootstrap appearence. Based on K2 approach.
<?php
// no direct access
defined('_JEXEC') or die('Restricted access');
jimport('joomla.form.formfield');
class JFormFieldBshead extends JFormField {
var $type = 'bshead';
@phproberto
phproberto / googlefont.php
Created June 16, 2012 01:01
Generate a JForm field list with all the fonts available in Google Web Fonts
<?php
defined('JPATH_BASE') or die;
jimport('joomla.html.html');
jimport('joomla.form.formfield');
jimport('joomla.form.helper');
JFormHelper::loadFieldClass('list');
class JFormFieldGooglefont extends JFormFieldList {