CMS for static pages

I need to create CMS where user can add some parts of static pages with some Editor.

What is the best approach to do this in yii:

  1. Should is store user editable static page parts in DB or file?

  2. Can i somehow cache existing pages?

Static page don’t have different to content article.

I think so.

you can create table for CMS pages,

with different fields insert page content in database text datatype field.

For insert/update pages you can use editMe editor,

… in view file.

it also support image upload functionality with kcfinder

follow this link

And what if I do not want to connect to DB when user sees static page?

Can I make "something" that creates static .php pages with content stored from DB, so I can use DB only when editing content in my CMS?

This sounds a little confusing.

I would say if you don’t want a hit to the database you’ll have to use caching, you can do full page caching, but you’ll still hit the database here and there

Look into APC which yii supports