Skip to content

Instantly share code, notes, and snippets.

View aek's full-sized avatar

Axel Mendoza aek

View GitHub Profile
@aek
aek / halo_AntPathMatcher.php
Created October 18, 2010 16:42
halo_MultiActionController
<?php
class halo_AntPathMatcher implements halo_IPathMatcher {
public function match($pattern, $path){
/**
** PurSelector is an Utility class from http://www.php-pop.org
**/
return PurSelector::match($pattern, $path, true);
}
}
?>
@aek
aek / ArcheType.php
Created October 18, 2010 16:58
bootstrap of ArcheType
<?php
require_once('./WebContent/WEB-INF/lib/hc-php/hc-bootstrap.php');
require_once('./WebContent/WEB-INF/lib/halo/halo-bootstrap.php');
require_once('./src/org.archetype/common/web/utils/ClassLoader.php');
if ( defined('HC_HALO_ENGINE_LOADED') ) {
throw new Exception("Something has gone horribly wrong. Something has re-imported or re-required the main Halo engine (likely index.php) and that is NOT a good thing!");
}
<?php
hc_core_ClassLoader::load('halo_AbstractUrlHandlerMapping');
class halo_SimpleUrlHandlerMapping extends halo_AbstractUrlHandlerMapping {
protected $mappings;
protected $useDefault;
private $pathMatcher;
public function __construct(array $mappings, $default = null) {
$this->mappings = $mappings;
$this->default = $default;
@aek
aek / Jx.DatePicker.js
Created September 19, 2011 17:34
DatePicker for JxLib
/*
---
name: Jx.DatePicker
description: A Jx.DatePicker: Provide a Date Picker component
license: MIT-style license.
provides: [Jx.DatePicker]
@aek
aek / Jx.MonthPicker.js
Created September 19, 2011 17:38
Jx.MonthPicker for JxLib
/*
---
name: Jx.MonthPicker
description: A Jx.MonthPicker: Provide a Month Picker component
license: MIT-style license.
provides: [Jx.MonthPicker]
@aek
aek / Jx.Field.Date.js
Created September 19, 2011 17:41
Jx.Field.Date for JxLib
/*
---
name: Jx.Field.Date
description: A Jx.Field.Date: Provide a field to select a valid date value using a Date Picker
license: MIT-style license.
provides: [Jx.Field.Date]
@aek
aek / aek_datepicker.css
Created September 19, 2011 17:57
CSS classes for calendar widgets in JxLib
/*************************************************************************************/
.jxDatePicker {
position: absolute;
width: 165px;
height: 140px;
left: 0px;
border: 1px solid #000;
padding: 2px;
background-image: url(images/a_pixel.png);
}
@aek
aek / Jx.Field.ComboBox.js
Created November 9, 2011 18:37
Jx.Field Combos implementations
/*
---
name: Jx.Field.ComboBox
description: A Jx.Field.ComboBox: is a Combo that show a Jx.ListView
items from a supplied store to select for the combo.
Supports pagination based on the class Jx.Toolbar.Paging a modified
from an example found on googlecode jxlib wiki.
@aek
aek / Jx.Field.Spinner.css
Created November 9, 2011 18:44
A Jx.Field.Spinner: Provide a Text Field with two buttons that fire events
.jxInputSpinners {
position: absolute;
width: 16px;
height: 16px;
right: 0px;
top: 0px;
margin: 0px 8px 4px 4px;
font-size: 0px;
line-height: 0px;
}
@aek
aek / Locale.Spanish.js
Created November 18, 2011 21:01
jxlib spanish locale
/*
---
name: Locale.Spanish.ES
description: Default translations of text strings used in JX for Spanish (Spain) (es-ES)
license: MIT-style license.
requires: