自己制作WordPress主题需要学习哪些方面的知识?

Udemy上有更多课程,如:Professional WordPress Theme Development from ScratchLearn To Create WordPress Themes By Building 10 Projects..

也可以看书,从开发插件开始

如果没有任何wordpress开发经验,可以从写插件开始。因为主题是一个系统工程,写一个完整的主题需要大量前后端知识,而插件可大可小,好控制。从功能的角度,插件通常完成针对性的功能,这种功能其实也可以整合进主题,但以插件的形式开发更轻量。很重要的对wordpress api的熟悉,从插件开发中比较容易集中获得,如wordpress的各种filter,action的使用等等。哪怕是改别人的主题,二次开发,也离不开这些核心知识。

介绍两本书:

  1. Professional WordPress Plugin Development
  2. Professional WordPress Design and Development

知识整理的最精粹的,还是专业开发写的书,网上的文档拿来参考。

自己制作WordPress主题需要学习哪些方面的知识?插图1

制作Child Theme,小试身手

你有了一定的基础以后,可以去对当前使用的主题进行一下定制,建立一个Child Theme,用一用各种hook,给自己出题,网站哪个部分想定制,如何在child theme中实现,有针对性地积累经验。

结合书本内容,把最常用的东西过一遍。

写第一个主题,完整实现,无论你用什么资料

写一段时间child theme,对api有比较好的认识了,可以开始写自己的第一个主题。从零开始,一步步地完成设计和架构,实现需要的功能,等到你完成项目,你至少已经对主题开发有了比较深入的理解。

站在巨人的肩膀上,专业开发

一线的商用主题很多都借助框架,框架的好处除了你自己不必从零开始以外,最重要的是让你理解一个优质主题的开发标准,有了标准,你做出来的东西起点自然高,而且主题开发框架是一种重要的技能投资,以Genius Framework为例,它提供的东西:

  • Responsive Design – automatically adjusts to fit perfectly on all screen sizes and mobile devices
  • Automatic Updates – easy upgrade similar to the way that WordPress itself (and plugins) are handled
  • 6 Layout Options – selectable site wide or for individual post/page
  • Theme Options – many settings that let you fine-tune the way your site looks
  • Custom Hooks (40+) – a hook is a piece of code written into the theme that allows you to attach additional content to the theme itself
  • Custom Widgets (MyTweets, User Profile, eNews & Updates, Featured Posts, Featured Pages)
  • Lots of great turn-key designs available (child themes)
  • State of the art security
  • Import / Export Settings – the Genesis Theme and SEO settings are completelyportable, so you can back up, restore, and transfer settings from one install to another
  • User Control System – allows admin to turn on/off theme settings, layouts and SEO option availability for users on a per user basis
  • Author Box – display per page option
  • Register / Unregister Layouts
  • Dynamic Text / Image Logo option
  • Navigation menu controls
  • Drop down navigation menu
  • Post Thumbnails
  • Auto sized featured images
  • Custom Widgets
  • Search Engine Optimised
  • SEO Options (site wide and individual page/post controls)
  • Post and Page Tracking/Conversion Code box
  • Widget-Ready
  • Ready for advertising
  • Breadcrumb navigation
  • Integrated Blog
  • BuddyPress Compatibility
  • Developed for Localization

我就不一一翻译了,可以到官网看详细。等你从框架中作出一个完整的东西来,理解了各个方面的处理,安全,兼容性,响应式与移动端支持,SEO等等,你已经是专业开发了。

这一切都需要时间,但wordpress开发是一项值得的技能投资,如果你本身从事web开发,就更是。如果你是刚入行的开发,能从这个过程中学到真正的全栈开发,从前端css到后端数据库。wordpress的api有很多不是OO的,但简单高效,没有拖泥带水的,从中你或许能明白用什么编程技术本身并不影响产品质量,关键是怎么用。

原创文章 自己制作WordPress主题需要学习哪些方面的知识?,版权所有
如若转载,请注明出处:https://www.itxiaozhan.cn/20229864.html

发表评论

您的电子邮箱地址不会被公开。 必填项已用*标注