官术网_书友最值得收藏!

Chapter 4. Theming Modules

In the last chapter, we took a look at the Drupal theme system, and created our own theme. This chapter will begin where we left off, but with a twist—this time we will create a module with a default theme. To do this, we will develop a new module.

The Philosophy Quotes module that we will create in this chapter will use Drupal's theme system and a simple database query to theme the content of a custom content type.

Here are some of the items we will cover while working on this module:

  • Creating a custom content type
  • Performing simple database operations
  • Registering a module's theme functions with the hook_theme() function
  • Adding theme hooks to a module
  • Adding CSS stylesheets to a module's default theme
  • Using theme CSS and template files to override default module theme functions

In the next chapter, we will continue with this module. There, we will augment our Philosophy Quotes module with some JavaScript.

主站蜘蛛池模板: 开阳县| 青河县| 滦南县| 雷波县| 兰西县| 秦皇岛市| 浏阳市| 山阳县| 涞源县| 勃利县| 定陶县| 牟定县| 新河县| 吉安市| 广元市| 玉屏| 南平市| 繁峙县| 金寨县| 芦溪县| 潮州市| 淅川县| 富阳市| 界首市| 舒兰市| 正镶白旗| 肥乡县| 普定县| 湖南省| 英吉沙县| 密云县| 彰化县| 昭通市| 耒阳市| 台州市| 娄烦县| 宜兰县| 丹凤县| 郸城县| 左云县| 赤壁市|