这是构建 WordPress 主题的最佳方式
- 我应该先使用 xhtml、css 和 javascript 制作一个静态网站,然后将其转换为 WordPress 主题吗?
或者 - 我应该直接从头开始构建主题吗?
或者 - 我应该使用任何框架
或 - 以上的组合。
- Should I make a static website using xhtml, css and javascript first and then convert it to a wordpress theme.
OR - Should I directly start building the theme from scratch.
OR - Should I use any framework
OR - Combination of the above.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我推荐 3,从现有主题开始。剥离(或忽略)比从头开始实施(或忘记实施这可能会在以后打击你)更容易。诀窍是从一个接近您需要的主题开始,而不需要太多包袱。
我还会选择基于 HTML5 的准系统主题,并带有 shivs 以支持旧版浏览器。 HTML5Boilerplate.com 可能是贡献最多的 HTML5 模板项目。这是一个坚实的起点,许多 WordPress 主题都基于它。 Google HTML5 样板 WordPress 或许还有准系统,您会发现相当多的模板。这是一个 https://github.com/zencoder/html5-boilerplate-for-wordpress
I'd recommend 3, starting from a an existing theme. It's easier to strip away (or ignore) than to have to implement from scratch (or forget to implement which may hit you later on). The trick is to start from a theme that is close to what you need without too much bagage.
I would also chose a barebone theme based on HTML5 with shivs to support older browsers. HTML5Boilerplate.com is probably the most contributed HTML5 template project. It is a solid starting point and many Wordpress themes are based on it. Google HTML5 boilerplate wordpress and maybe barebone and you'll find quite a few templates. Here's one https://github.com/zencoder/html5-boilerplate-for-wordpress
我总是使用第一种方法,但它可能不是最适合你的。
一旦你构建了一些,你很可能就有一个代码库可以简单地插入到你的 html/css 中。
您还可以获得一个预制主题,其布局类似于您的新设计,并对其进行修改。这是学习如何制作主题的好方法
I always use the first method, but it may not be the best for you.
Once you have built a few you'll most likely have a code base to simply insert into your html/css.
You could also get a pre-made theme with a layout like what your new design has, and modify that. Its a great way to learn how themes are made