为 Wordpress、Joomla 或 Drupal 等 CMS 制作可安装模板是否需要具备良好的 PHP 知识?
为 CMS(如 Wordpress、Joomla、Drupal)制作可安装模板是否需要具备良好的 PHP 知识?
Is good knowledge of PHP needed to make an installable template for CMS like Wordpress, Joomla, Drupal?
或者对 XHTML 和 CSS 有足够的了解吗?
Or is good knowledge of XHTML and CSS enough?
推荐答案
根据我的经验 - 我对 Wordpress 有很多,还有一些在 Joomla - 我会推荐至少一些 PHP 知识和理解底层代码库.对于视觉样式,只要您围绕"PHP 工作,HTML/CSS 知识就足够了,但是当被要求更改模板的基本特征或实现新功能时,您将受到极大的限制.
From my experience - I have a lot with Wordpress, and some with Joomla - I would recommend at least some PHP knowledge and understanding of the underlying code base. For visual styling, HTML/CSS knowledge is enough as long as you work "around" the PHP, but you will be extremely limited when asked to change fundamental characteristics of the template, or implement new functions.
这取决于您真正想提供什么.如果您只满足于提供样式自定义,那么您可能会使用 HTML、CSS 和一些 PHP.模板中使用的基本 PHP 函数很容易理解.
It depends on what you want to offer really. If you are content with offering stylistic customizations only, you may be fine with HTML, CSS and a bit of PHP. The basic PHP functions used in the templates are easy to understand.
但是功能自定义,例如为某些帖子、标签、类别、评论等实现自定义行为,需要具备良好的 PHP 知识.如果你想增加你的市场价值,进入 Wordpress Codex 和 Joomla 或 Drupal 肯定是个好主意.
But functional customizations, like implementing custom behaviour for certain posts, tags, categories, comments etc., require good knowledge in PHP. If you want to increase your market value, getting into the Wordpress Codex and either Joomla or Drupal is certainly a good idea.
顺便说一句,由于大量的臃肿和低代码质量,我个人已经开始不喜欢 Wordpress 及其 API.我最近寻找了一个更简约的博客平台(SO question 此处).我接受的答案是Habari,它非常灵活,即使它这里和那里有一些粗糙的边缘,版本号中的前导0"有时会显示出优雅的平台.需要对 PHP 5 有一定的了解才能了解其模板功能,但是一旦您了解它,它就会变得无比灵活.它可能不适合你,因为我知道你的目标是流行的平台来获得工作(这完全没问题.)但已经提到了它.
On a side note, I personally have come to dislike Wordpress and its API due to lots of bloat and low code quality. I looked for a more minimalistic blogging platform recently (SO question here). The answer I accepted, Habari, is a marvellously flexible and, even though it has some rough edges here and there and the leading "0" in the version number sometimes shows, elegant platform. It takes some understanding of PHP 5 to get into its templating capabilities, but once you get your head around it, it is unbeatably flexible. It may not be for you, as I know you are targeting popular platforms to get work (which is perfectly fine.) but to have mentioned it.
相关文章