Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/richardzcode/jofe
Joomla 1.5 extension. PHP
https://github.com/richardzcode/jofe
Last synced: about 1 month ago
JSON representation
Joomla 1.5 extension. PHP
- Host: GitHub
- URL: https://github.com/richardzcode/jofe
- Owner: richardzcode
- License: gpl-2.0
- Created: 2011-09-16T01:16:17.000Z (over 13 years ago)
- Default Branch: master
- Last Pushed: 2011-09-17T00:11:04.000Z (over 13 years ago)
- Last Synced: 2024-04-14T09:14:22.443Z (9 months ago)
- Language: PHP
- Homepage:
- Size: 4.78 MB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.markdown
- Changelog: CHANGELOG.php
- License: LICENSE.php
Awesome Lists containing this project
README
# Jofe - Joomla 1.5 extension
Some common features I abstracted out when work with Joomla 1.5.
I wasn't aiming for a full, big library. Just something that helps rapid development.
Simplicity is the key.
For example. It does include an inflector library. So instead of what you see in Rails:
post.comments
post.comments.sizeIn Jofe it is like
post._obj_comment
post._count_commentNote that although it is a one-to-many relationship, comment is still referred in singular form by post.
It is not very cool by looking at it, but simply works for developers.
## Location: /libraries/jofe/
## Extensions:
### Major extensions:
* JofeComponent - Simplify the component creation.
jimport('jofe.application.component');
class BlogComponent extends JofeComponent{
protected $_default_controller = 'post';
public function prepare() {
parent::prepare();
$this->addStyleSheet('blog.css');
$this->addScript('jquery-1.4.4.min.js');
$this->addScript('blog.js');
}
}
$com = new BlogComponent();
$com->run();
* JofeController - Extends JController. Wraps RESTful actions.
* JofeView - Extends JView. Very small extention just created some default RESTful responses.
* JofeTable - Extends JTable.
* Simple ORM features
* find function
* object relationship specified in relates_to_one, and relates_to_many.
* A couple of helper functions
* Triggers
* JofeModel - Extends JModel. Handles pagination/sorting/filtering### Side extensions:
Have dependency on jQuery and need some CSS
* JofeForm - Helps create form.
* JofeGrid - Takes data returned by JofeModel and renders grid.
$grid = new JofeGrid(array(
array(
'header' => 'Title',
'width' => '50%',
'field' => 'title',
'callback' => 'post_grid_col_title',
'sortable' => true
),
array(
'header' => 'Created',
'width' => '20%',
'field' => 'created_on',
'sortable' => true
)
),
$this->griddata
);
$grid->render();## Sample component:
/components/com_blog