Skip to content

Instantly share code, notes, and snippets.

@tedkulp
Created December 31, 2008 01:11
Show Gist options
  • Save tedkulp/41831 to your computer and use it in GitHub Desktop.
Save tedkulp/41831 to your computer and use it in GitHub Desktop.
As I've worked on CMSMS 2.0, I've run into a few recurring issues
that I didn't quite have an answer or reason for yet...
1. I wrote a lot of very generic pieces of code in order to make 2.0
easier to develop in the long run. I think I might've gone overboard
a bit. I wasn't ever sure why.
2. As a professional developer, I kept running into issues where I wanted
to use some of that code for other stuff. And it was too difficult to just
pull out the piece I needed and didn't do it.
When talking to my friend, Greg (who, incidentally, helped push me to
launch CMSMS as a project), I was telling him about some of the things
that 2.0 could do. I said something along the lines of, "Really, except
for some routing and a few other little things, 2.0 could be a full
development framework for other applications." And, in my typical
way, I thought about this for a few days... and didn't do much else.
So, I've decided to use my week off from work to put together the basics
of a PHP5 based web application framework. This framework will then
become the base of CMSMS 2.0 (it's less work than it sounds -- trust me)
as well as any other application you might want to develop. It's a generic
framework that builds on some of the key ideas we've had in CMSMS all
along -- it just makes those tools easier to setup for whatever you'd like
to develop.
Let's finish out this post in typical FAQ style:
<!--more-->
<strong>Who is this aimed towards?</strong>
Professional PHP5 developers, plain and simple. If you know what a
framework is and why you'd need one, then you're probably the correct
candidate for this project. If this just flies over your head, then
it's probably safe to skip to the next post in your news reader. :)
<strong>What's the name mean?</strong>
It's smooth. It's strong. It's a nice foundational material...
Really? It's a short name that fits well when you put it in every
class name. It'll also make for a nice logo someday.
<strong>What are the requirements?</strong>
PHP 5.2+ on any compatible web server. A database of some sorts -- MySQL
will be tested heavily. PostgreSQL and SQLite should also work fine.
Development will only really happen on a unix based system... Windows
users might have to do a little bit of investigative work to develop with
the system.
<strong>What do I get?</strong>
<ul>
<li>ADODB5 - The standard in database abstraction. Silk uses it
throughout.</li>
<li>The Silk ORM - Built on top of ADODB and uses the ActiveRecord
pattern. Cuts down lines of code and makes basic database access very
simple and OO.</li>
<li>Smarty - Uses the power of smarty throughout. Smarty templates
are used for all templates and layouts, as well as smarty plugins created
for all form elements.</li>
<li>Magic MVC - Using file naming conventions, new actions, controllers
and views can be added with very minimal work. Everything is customizable
afterwards.</li>
<li>jQuery - We've standardized on the jQuery javascript framework.
Used throughout, we've included some javascript helpers to make Ajax simple
to use.</li>
<li>Events system - Stateless event handling system based on the one
from CMSMS 1.x -- without the database. (coming soon)</li>
<li>Unit testing - Ability to have unit tests on models, views and
controllers. (coming soon)</li>
<li>Users, groups, permissions - Have a basic system for handling
these 3 things that fall into almost every web application. CMSMS 2.0 will
use the same system, so applications will be able to share login information
directly with CMSMS.</li>
<li>OpenID - Logins will support the OpenID protocol and standard
using the php-openid library.</li>
</ul>
<strong>License?</strong>
Silk is licensed using the MIT open source license. It's both GPL compatible
(for release with CMSMS) and also able to be used in commercial/proprietary
applications without question. This will allow people to use Silk for practically
anything.
<strong>How do I get involved?</strong>
Silk isn't really "there" yet. It's still in the early phases of development,
though, it's been moving pretty fast and working out above expectations. The
source code is hosting on github:
<a href="http://github.com/tedkulp/silk">http://github.com/tedkulp/silk</a>. If
you'd like to make contributions or play with the code, fork a copy and play
away. If you feel that something is patch worthy, send me a pull request and I'll
take a look.
In the near future, I will post some HOWTO's and API docs to silkframework.com.
After I feel that things are stabilized a bit, I'll write up a HOWTO on how to
write a simple application using Silk that hints the major points and gets people
on their way.
<strong>How does this affect 2.0?</strong>
Only a bit. The admin will be rewritten to use the new MVC system, events will
have to be changed a bit, and well as a few other changes. But we're still moving
forward without having to throw away a lot of code. This is still a positive step
forward with only a few small steps back.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment