- Messages
- 2,293
- Reaction score
- 50
- Points
- 48
I can't say that i look around at frameworks often, but i found a very nice one that has a CMS built on top of it, which allows for very easy and quick development of a site.
I actually chose it because it was the first in a list that was free and not licensed under the gpl.
http://silverstripe.org/
Unlike some other frameworks i have used in the past(like 2 or 3), this one is very easy to use. It works on a plain old php install, and is fairly fast, so it should work fine on the free hosting(don't hold me to it)
The CMS that comes with it is fairly plain, but fairly powerful.
(bit of a tutorial to show how simple it is to work with)
Lets say we create our own pagetype, (which we can then assign to a page)
we save this in mysite/code/MyCustomPage.php
Now i'm still not to sure of the structure, as i'm still a noob, but i believe the first class handles setting up stuff like the database and how the page functions internally.
The second class is where the magic is. This is where all the goodies go. Functions in here can be directly called by the template, or by the url(mysite.com/Page/SomePageFunction)
So if we add this:
We can then use SomeStats in a template, like this:
Now there is a little bit of a learning curve, and you do need to know php, but i love this framework already.
As noted earlier, i'm still new to this framework myself so i still haven't dug into its power. Theres a mass of features i haven't touched.
Here is a testing ground i'm using for it: http://preview.stormraidergames.com/
I actually chose it because it was the first in a list that was free and not licensed under the gpl.
http://silverstripe.org/
Unlike some other frameworks i have used in the past(like 2 or 3), this one is very easy to use. It works on a plain old php install, and is fairly fast, so it should work fine on the free hosting(don't hold me to it)
The CMS that comes with it is fairly plain, but fairly powerful.
(bit of a tutorial to show how simple it is to work with)
Lets say we create our own pagetype, (which we can then assign to a page)
we save this in mysite/code/MyCustomPage.php
PHP:
<?php
/**
* Defines a page type
*/
class MyCustomPage extends Page {
static $db = array(
);
static $has_one = array(
);
}
class MyCustomPage_Controller extends Page_Controller {
}
The second class is where the magic is. This is where all the goodies go. Functions in here can be directly called by the template, or by the url(mysite.com/Page/SomePageFunction)
So if we add this:
PHP:
function SomeStats() {
return "Stats: 118 corn-dogs eaten.";
}
Code:
Last weeks info: <i>$SomeStats</i>
Now there is a little bit of a learning curve, and you do need to know php, but i love this framework already.
As noted earlier, i'm still new to this framework myself so i still haven't dug into its power. Theres a mass of features i haven't touched.
Here is a testing ground i'm using for it: http://preview.stormraidergames.com/
Last edited: