View and layout scripts are responsible for displaying content in
the browser, typically as, but not limited to (X)HTML. Views are
generally specific to a controller action. For example, an action
method such as
actionIndex() would display its
output in a view called
on the other hand, are typically shared by the entire application
and wrap around a controller's view. A layout usually contains the
header, footer, navigation, and the content area where the
controller's view output is displayed.
This chapter builds on the blog demo from chapter one and assumes that you
have a working Solar system installed,
understand the basic configuration, and
have the blog demo from chapter one setup and working.
All URLs in this chapter use the "cleaner" URLs as outlined at the end of chapter one. If you are not using the clean URLs, remember that http://localhost/blog/read/1 is equivalent to http://localhost/index.php/blog/read/1.
All examples are based on the localhost domain. Adjust your code accordingly.
refers to the location where Solar is installed.
vimmay be shown as the text editor. Use whichever editor you are comfortable with.