duanlei8119 2014-09-18 01:08
浏览 35
已采纳

有没有一种可靠的方法将Zurb Foundation CSS框架与CakePHP一起使用?

I'm looking at a major update to an application that is currently just a mashup of raw PHP/HTML/CSS.

I want to use CakePHP MVC as the backend and Zurb Foundation as the front end. Although I can't seem to find a way to connect the two.

I am aware of lorenzo's repo but wasn't sure if there was another way. It seems like this repo is not used whole lot. It hasn't been updated in a couple years. Surely someone has used CakePHP and Foundation together?

  • 写回答

1条回答 默认 最新

  • douxie1894 2014-09-18 02:55
    关注

    Although I can't seem to find a way to connect the two.

    The point is that they're not connected in any way. php and CakePHP (and any other framework) as well produce in most cases HTML as output by default. You're totally free how you write your templates that are used to generate the output.

    One of the key principles of the MVC design pattern is to separate the view from business logic. You'll still use php there but not in the way your mashup does. Just add the CSS file of the Zurb CSS framework to your layout file and apply all the styling in your views accordingly.

    There is no plugin that magically turns all your views into bootstrap or zurb compatible HTML if thats what you're looking for. All the plugins for zurb / bootstrap will just modify some of the CakePHP core helper methods that generate HTML in a way that they'll produce the markup the CSS framework expects.

    I recommend you to do the blog tutorial and read the view and helper section of the manual.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 stata安慰剂检验作图但是真实值不出现在图上
  • ¥15 c程序不知道为什么得不到结果
  • ¥40 复杂的限制性的商函数处理
  • ¥15 程序不包含适用于入口点的静态Main方法
  • ¥15 素材场景中光线烘焙后灯光失效
  • ¥15 请教一下各位,为什么我这个没有实现模拟点击
  • ¥15 执行 virtuoso 命令后,界面没有,cadence 启动不起来
  • ¥50 comfyui下连接animatediff节点生成视频质量非常差的原因
  • ¥20 有关区间dp的问题求解
  • ¥15 多电路系统共用电源的串扰问题